示例#1
0
        internal static PatchInfo GetPatchInfo(MethodBase method)
        {
            var bytes = GetState().GetValueSafe(method);

            if (bytes == null)
            {
                return(null);
            }
            return(PatchInfoSerialization.Deserialize(bytes));
        }
示例#2
0
 internal static PatchInfo GetPatchInfo(MethodBase method)
 {
     byte[] bytes;
     lock (state) bytes = state.GetValueSafe(method);
     if (bytes is null)
     {
         return(null);
     }
     return(PatchInfoSerialization.Deserialize(bytes));
 }
示例#3
0
 internal static PatchInfo GetPatchInfo(MethodBase method)
 {
     return(WithState(() =>
     {
         var bytes = state.GetValueSafe(method);
         if (bytes is null)
         {
             return null;
         }
         return PatchInfoSerialization.Deserialize(bytes);
     }));
 }