< Summary

Information
Class: ImpromptuInterface.Build.BuildProxy
Assembly: ImpromptuInterface
File(s): /home/runner/work/impromptu-interface/impromptu-interface/ImpromptuInterface/src/EmitProxy/BuildProxy.cs
Line coverage
100%
Covered lines: 1
Uncovered lines: 0
Coverable lines: 1
Total lines: 59
Line coverage: 100%
Branch coverage
N/A
Covered branches: 0
Total branches: 0
Branch coverage: N/A
Method coverage

Feature is only available for sponsors

Upgrade to PRO version

Metrics

MethodBranch coverage Crap Score Cyclomatic complexity Line coverage
CollectableProxyMaker()100%11100%

File(s)

/home/runner/work/impromptu-interface/impromptu-interface/ImpromptuInterface/src/EmitProxy/BuildProxy.cs

#LineLine coverage
 1//
 2//  Copyright 2010  Ekon Benefits
 3//
 4//    Licensed under the Apache License, Version 2.0 (the "License");
 5//    you may not use this file except in compliance with the License.
 6//    You may obtain a copy of the License at
 7//
 8//        http://www.apache.org/licenses/LICENSE-2.0
 9//
 10//    Unless required by applicable law or agreed to in writing, software
 11//    distributed under the License is distributed on an "AS IS" BASIS,
 12//    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 13//    See the License for the specific language governing permissions and
 14//    limitations under the License.
 15
 16using System.IO;
 17
 18namespace ImpromptuInterface.Build
 19{
 20    using System;
 21    using System.Reflection;
 22    using System.Reflection.Emit;
 23
 24
 25#if NETFRAMEWORK
 26    internal static class CompatHelper
 27    {
 28        public static Type GetTypeInfo(this Type type) => type;
 29
 30        public static Type CreateTypeInfo(this TypeBuilder builder) => builder.CreateType();
 31
 32        public static AssemblyBuilder DefineDynamicAssembly(AssemblyName name, AssemblyBuilderAccess access) => AppDomai
 33    }
 34
 35#else
 36    internal static class CompatHelper
 37    {
 38        public static AssemblyBuilder DefineDynamicAssembly(AssemblyName name, AssemblyBuilderAccess access) => Assembly
 39
 40    }
 41
 42#endif
 43
 44    ///<summary>
 45    /// Does most of the work buiding and caching proxies
 46    ///</summary>
 47    public static class BuildProxy
 48    {
 49        public static ActLikeMaker DefaultProxyMaker { get; } = new ActLikeMaker();
 50
 151        public static ActLikeMaker CollectableProxyMaker() => new ActLikeMaker(AssemblyBuilderAccess.RunAndCollect);
 52
 53#if NETFRAMEWORK
 54        public static SaveableActLikeMaker SaveableProxyMaker(string assemblyName = null) => new SaveableActLikeMaker(As
 55#endif
 56    }
 57
 58
 59}

Methods/Properties

CollectableProxyMaker()