/// <summary> /// Gets the property/field named <paramref name="name"/> /// </summary> /// <param name="name">Name of property/field</param> /// <param name="isField"><c>true</c> if it's a field, <c>false</c> if it's a property</param> /// <returns>A <see cref="CANamedArgument"/> instance or <c>null</c> if not found</returns> public CANamedArgument GetNamedArgument(UTF8String name, bool isField) { foreach (var namedArg in namedArguments.GetSafeEnumerable()) { if (namedArg.IsField == isField && UTF8String.Equals(namedArg.Name, name)) { return(namedArg); } } return(null); }
static bool Equals(IAssembly a, IAssembly b) { if (a == b) { return(true); } if (a == null || b == null) { return(false); } return(Utils.Equals(a.Version, b.Version) && PublicKeyBase.TokenEquals(a.PublicKeyOrToken, b.PublicKeyOrToken) && UTF8String.Equals(a.Name, b.Name) && UTF8String.CaseInsensitiveEquals(a.Culture, b.Culture)); }
public bool Equals(ClassName other) { // Don't check IsValueType return(UTF8String.Equals(Namespace, other.Namespace) && UTF8String.Equals(Name, other.Name)); }
public bool Equals(ClassName other) => // Don't check IsValueType UTF8String.Equals(Namespace, other.Namespace) && UTF8String.Equals(Name, other.Name);
public bool Equals(Info other) { return(stricmp(Scope, other.Scope) && UTF8String.Equals(Identifier, other.Identifier)); }
public bool Equals(Info other) => stricmp(Scope, other.Scope) && UTF8String.Equals(Identifier, other.Identifier);