protected override bool InternalTryGetValue(ABPropertyDefinition property, out object value) { if (property == ABObjectSchema.Alias) { value = this.GetAlias(); return(true); } if (property == ABObjectSchema.DisplayName) { value = this.GetDisplayName(); return(true); } if (property == ABObjectSchema.LegacyExchangeDN) { value = this.GetLegacyExchangeDN(); return(true); } if (property == ABObjectSchema.CanEmail) { value = this.GetCanEmail(); return(true); } if (property == ABObjectSchema.Id) { value = this.GetId(); return(true); } if (property == ABObjectSchema.EmailAddress) { value = this.GetEmailAddress(); return(true); } return(base.InternalTryGetValue(property, out value)); }
// Token: 0x06000007 RID: 7 RVA: 0x000021FC File Offset: 0x000003FC public bool TryGetValue <T>(ABPropertyDefinition property, out T value) { object obj; if (!this.TryGetValue(property, out obj)) { value = default(T); return(false); } value = (T)((object)obj); return(true); }
// Token: 0x17000003 RID: 3 public virtual object this[ABPropertyDefinition property] { get { object result; if (!this.TryGetValue(property, out result)) { throw new KeyNotFoundException(property.Name); } return(result); } }
protected override bool InternalTryGetValue(ABPropertyDefinition property, out object value) { if (property == ABGroupSchema.OwnerId) { value = this.GetOwnerId(); return(true); } if (property == ABGroupSchema.MembersCount) { value = this.GetMembersCount(); return(true); } if (property == ABGroupSchema.HiddenMembership) { value = this.GetHiddenMembership(); return(true); } return(base.InternalTryGetValue(property, out value)); }
// Token: 0x06000008 RID: 8 RVA: 0x0000222C File Offset: 0x0000042C object[] IReadOnlyPropertyBag.GetProperties(ICollection <PropertyDefinition> propertyDefinitionCollection) { if (propertyDefinitionCollection == null) { throw new ArgumentNullException("propertyDefinitionCollection"); } object[] array = new object[propertyDefinitionCollection.Count]; int num = 0; foreach (PropertyDefinition propertyDefinition in propertyDefinitionCollection) { ABPropertyDefinition abpropertyDefinition = (ABPropertyDefinition)propertyDefinition; if (abpropertyDefinition == null) { throw new ArgumentException("Property definition collection contains null entries.", "propertyDefinitionCollection"); } array[num++] = this[abpropertyDefinition]; } return(array); }
// Token: 0x06000006 RID: 6 RVA: 0x0000214C File Offset: 0x0000034C public bool TryGetValue(ABPropertyDefinition property, out object value) { if (property == null) { throw new ArgumentNullException("property"); } if (!this.propertyDefinitionCollection.Contains(property)) { throw new KeyNotFoundException(property.Name); } bool result = this.InternalTryGetValue(property, out value); if (value != null && !property.Type.IsInstanceOfType(value)) { throw new InvalidOperationException(string.Format(CultureInfo.InvariantCulture, "Provider '{0}' returned type '{1}' rather than '{2}' for property '{3}'", new object[] { this.ownerSession.ProviderName, (value == null) ? "null reference" : value.GetType().Name, property.Type.Name, property.Name })); } return(result); }
// Token: 0x06000009 RID: 9 RVA: 0x000022B0 File Offset: 0x000004B0 protected virtual bool InternalTryGetValue(ABPropertyDefinition property, out object value) { value = null; return(false); }
protected override bool InternalTryGetValue(ABPropertyDefinition property, out object value) { if (property == ABContactSchema.BusinessPhoneNumber) { value = this.GetBusinessPhoneNumber(); return(true); } if (property == ABContactSchema.CompanyName) { value = this.GetCompanyName(); return(true); } if (property == ABContactSchema.DepartmentName) { value = this.GetDepartmentName(); return(true); } if (property == ABContactSchema.BusinessFaxNumber) { value = this.GetBusinessFaxNumber(); return(true); } if (property == ABContactSchema.GivenName) { value = this.GetGivenName(); return(true); } if (property == ABContactSchema.HomePhoneNumber) { value = this.GetHomePhoneNumber(); return(true); } if (property == ABContactSchema.Initials) { value = this.GetInitials(); return(true); } if (property == ABContactSchema.MobilePhoneNumber) { value = this.GetMobilePhoneNumber(); return(true); } if (property == ABContactSchema.OfficeLocation) { value = this.GetOfficeLocation(); return(true); } if (property == ABContactSchema.Surname) { value = this.GetSurname(); return(true); } if (property == ABContactSchema.Title) { value = this.GetTitle(); return(true); } if (property == ABContactSchema.WorkAddressCity) { value = this.GetWorkAddressCity(); return(true); } if (property == ABContactSchema.WorkAddressCountry) { value = this.GetWorkAddressCountry(); return(true); } if (property == ABContactSchema.WorkAddressPostalCode) { value = this.GetWorkAddressPostalCode(); return(true); } if (property == ABContactSchema.WorkAddressPostOfficeBox) { value = this.GetWorkAddressPostOfficeBox(); return(true); } if (property == ABContactSchema.WorkAddressState) { value = this.GetWorkAddressState(); return(true); } if (property == ABContactSchema.WorkAddressStreet) { value = this.GetWorkAddressStreet(); return(true); } if (property == ABContactSchema.WebPage) { value = this.GetWebPage(); return(true); } if (property == ABContactSchema.Picture) { value = this.GetPicture(); return(true); } return(base.InternalTryGetValue(property, out value)); }