private static bool MockedGetSettlementAll(ref MBReadOnlyList <Settlement> __result) { var settlement = (Settlement)FormatterServices.GetUninitializedObject(typeof(Settlement)); var village = (Village)FormatterServices.GetSafeUninitializedObject(typeof(Village)); SymbolExtensions2.GetPropertyInfo((Settlement s) => s.Id).SetValue(settlement, new MBGUID(1)); SymbolExtensions2.GetPropertyInfo((Settlement s) => s.IsInitialized).SetValue(settlement, true); SymbolExtensions2.GetFieldInfo((Settlement s) => s.Village).SetValue(settlement, village); __result = new MBReadOnlyList <Settlement>(new List <Settlement> { settlement }); return(false); }
public static FieldInfo?GetFieldInfo(LambdaExpression expression) => SymbolExtensions3.GetFieldInfo(expression);
public static FieldInfo?GetFieldInfo <T, TResult>(Expression <Func <T, TResult> > expression) => SymbolExtensions3.GetFieldInfo <T, TResult>(expression);