MCPcopy Create free account
hub / github.com/FlaxEngine/FlaxEngine / GetField

Method GetField

Source/Editor/Scripting/ScriptType.cs:1339–1349  ·  view source on GitHub ↗

When overridden in a derived class, searches for the field defined for the current type using the specified binding constraints. The string containing the name of the members to get. A bitmask comprised of one or more that specify how the search is conducted.-or- Zero (<see cre

(string name, BindingFlags bindingAttr = BindingFlags.Instance | BindingFlags.Static | BindingFlags.Public)

Source from the content-addressed store, hash-verified

1337 /// <param name="bindingAttr">A bitmask comprised of one or more <see cref="T:System.Reflection.BindingFlags" /> that specify how the search is conducted.-or- Zero (<see cref="F:System.Reflection.BindingFlags.Default" />), to return an empty item.</param>
1338 /// <returns>The member object representing the field defined for the current type that matches the specified name. Returns <see cref="ScriptMemberInfo.Null"/> if failed.</returns>
1339 public ScriptMemberInfo GetField(string name, BindingFlags bindingAttr = BindingFlags.Instance | BindingFlags.Static | BindingFlags.Public)
1340 {
1341 if (_managed != null)
1342 {
1343 var managedMember = _managed.GetField(name, bindingAttr);
1344 return new ScriptMemberInfo(managedMember);
1345 }
1346 if (_custom != null)
1347 return _custom.GetMembers(name, MemberTypes.Field, bindingAttr).FirstOrDefault();
1348 return ScriptMemberInfo.Null;
1349 }
1350
1351 /// <summary>
1352 /// When overridden in a derived class, searches for the property defined for the current type using the specified binding constraints.

Callers 10

OnAssemblyLoadedFunction · 0.45
GetAnchorEqualityMethod · 0.45
GetVisibleIfSourcesMethod · 0.45
InitializeMethod · 0.45
OnSelectedItemChangedMethod · 0.45
RefreshMethod · 0.45
ScriptMemberInfoClass · 0.45
InitializeMethod · 0.45
InitializeMethod · 0.45

Calls 1

GetMembersMethod · 0.45

Tested by

no test coverage detected