private static void AddUserExternalIds(MASchemaType type, IManagementAgentParameters config) { AdapterSubfield value = new AdapterSubfield { AttributeType = AttributeType.String, FieldName = "value", IsMultivalued = false, Operation = AttributeOperation.ImportExport, PropertyName = "Value", AttributeNamePart = null }; AdapterCustomTypeList <ExternalID> customType = new AdapterCustomTypeList <ExternalID> { Api = "user", AttributeName = "externalIds", Fields = new List <AdapterSubfield>() { value }, FieldName = "externalIds", PropertyName = "ExternalIds", KnownTypes = config.ExternalIDsAttributeFixedTypes?.ToList(), SupportsPatch = false }; type.AttributeAdapters.Add(customType); }
private static void AddUserPhonesAttributes(MASchemaType type, IManagementAgentParameters config) { AdapterSubfield phonesValue = new AdapterSubfield { AttributeType = AttributeType.String, FieldName = "value", IsMultivalued = false, Operation = AttributeOperation.ImportExport, PropertyName = "Value", AttributeNamePart = null }; AdapterCustomTypeList <Phone> phonesType = new AdapterCustomTypeList <Phone> { Api = "user", AttributeName = "phones", Fields = new List <AdapterSubfield>() { phonesValue }, FieldName = "phones", PropertyName = "Phones", IsPrimaryCandidateType = true, KnownTypes = config.PhonesAttributeFixedTypes?.ToList(), SupportsPatch = false }; type.AttributeAdapters.Add(phonesType); }
private static void AddUserIms(MASchemaType type, IManagementAgentParameters config) { AdapterSubfield im = new AdapterSubfield { AttributeType = AttributeType.String, FieldName = "im", IsMultivalued = false, Operation = AttributeOperation.ImportExport, PropertyName = "IMAddress", AttributeNamePart = "address" }; AdapterSubfield protocol = new AdapterSubfield { AttributeType = AttributeType.String, FieldName = "protocol", IsMultivalued = false, Operation = AttributeOperation.ImportExport, PropertyName = "Protocol", AttributeNamePart = "protocol" }; AdapterCustomTypeList <IM> customType = new AdapterCustomTypeList <IM> { Api = "user", AttributeName = "ims", Fields = new List <AdapterSubfield>() { im, protocol }, FieldName = "ims", PropertyName = "Ims", IsPrimaryCandidateType = true, KnownTypes = config.IMsAttributeFixedTypes?.ToList(), SupportsPatch = false }; type.AttributeAdapters.Add(customType); }
private static void AddUserWebSites(MASchemaType type, IManagementAgentParameters config) { AdapterSubfield webSiteValue = new AdapterSubfield { AttributeType = AttributeType.String, FieldName = "value", IsMultivalued = false, Operation = AttributeOperation.ImportExport, PropertyName = "Value", AttributeNamePart = null }; AdapterSubfield webSitePrimary = new AdapterSubfield { AttributeType = AttributeType.Boolean, FieldName = "primary", IsMultivalued = false, PropertyName = "Primary", Operation = AttributeOperation.ImportExport, AttributeNamePart = "primary" }; AdapterCustomTypeList <ManagedObjects.Website> webSiteType = new AdapterCustomTypeList <Website> { Api = "user", AttributeName = "websites", Fields = new List <AdapterSubfield>() { webSitePrimary, webSiteValue }, FieldName = "websites", PropertyName = "Websites", IsPrimaryCandidateType = true, KnownTypes = config.WebsitesAttributeFixedTypes?.ToList(), SupportsPatch = false }; type.AttributeAdapters.Add(webSiteType); }
private static void AddUserAddresses(MASchemaType type, IManagementAgentParameters config) { AdapterSubfield sourceIsStructured = new AdapterSubfield { AttributeType = AttributeType.Boolean, FieldName = "sourceIsStructured", IsMultivalued = false, Operation = AttributeOperation.ImportExport, PropertyName = "SourceIsStructured", AttributeNamePart = "sourceIsStructured" }; AdapterSubfield formatted = new AdapterSubfield { AttributeType = AttributeType.String, FieldName = "formatted", IsMultivalued = false, PropertyName = "Formatted", Operation = AttributeOperation.ImportExport, AttributeNamePart = "formatted" }; AdapterSubfield poBox = new AdapterSubfield { AttributeType = AttributeType.String, FieldName = "poBox", IsMultivalued = false, PropertyName = "POBox", Operation = AttributeOperation.ImportExport, AttributeNamePart = "poBox" }; AdapterSubfield extendedAddress = new AdapterSubfield { AttributeType = AttributeType.String, FieldName = "extendedAddress", IsMultivalued = false, PropertyName = "ExtendedAddress", Operation = AttributeOperation.ImportExport, AttributeNamePart = "extendedAddress" }; AdapterSubfield streetAddress = new AdapterSubfield { AttributeType = AttributeType.String, FieldName = "streetAddress", IsMultivalued = false, PropertyName = "StreetAddress", Operation = AttributeOperation.ImportExport, AttributeNamePart = "streetAddress" }; AdapterSubfield locality = new AdapterSubfield { AttributeType = AttributeType.String, FieldName = "locality", IsMultivalued = false, PropertyName = "Locality", Operation = AttributeOperation.ImportExport, AttributeNamePart = "locality" }; AdapterSubfield region = new AdapterSubfield { AttributeType = AttributeType.String, FieldName = "region", IsMultivalued = false, PropertyName = "Region", Operation = AttributeOperation.ImportExport, AttributeNamePart = "region" }; AdapterSubfield postalCode = new AdapterSubfield { AttributeType = AttributeType.String, FieldName = "postalCode", IsMultivalued = false, PropertyName = "PostalCode", Operation = AttributeOperation.ImportExport, AttributeNamePart = "postalCode" }; AdapterSubfield country = new AdapterSubfield { AttributeType = AttributeType.String, FieldName = "country", IsMultivalued = false, PropertyName = "Country", Operation = AttributeOperation.ImportExport, AttributeNamePart = "country" }; AdapterSubfield countryCode = new AdapterSubfield { AttributeType = AttributeType.String, FieldName = "countryCode", IsMultivalued = false, PropertyName = "CountryCode", Operation = AttributeOperation.ImportExport, AttributeNamePart = "countryCode" }; AdapterCustomTypeList <Address> customType = new AdapterCustomTypeList <Address> { Api = "user", AttributeName = "addresses", Fields = new List <AdapterSubfield>() { sourceIsStructured, formatted, poBox, extendedAddress, streetAddress, locality, region, postalCode, country, countryCode }, FieldName = "addresses", PropertyName = "Addresses", IsPrimaryCandidateType = true, KnownTypes = config.AddressesAttributeFixedTypes?.ToList(), SupportsPatch = false }; type.AttributeAdapters.Add(customType); }
private static void AddUserOrganizationsAttributes(MASchemaType type, IManagementAgentParameters config) { AdapterSubfield name = new AdapterSubfield { AttributeType = AttributeType.String, FieldName = "name", IsMultivalued = false, Operation = AttributeOperation.ImportExport, PropertyName = "Name", AttributeNamePart = "name" }; AdapterSubfield title = new AdapterSubfield { AttributeType = AttributeType.String, FieldName = "title", IsMultivalued = false, PropertyName = "Title", Operation = AttributeOperation.ImportExport, AttributeNamePart = "title" }; AdapterSubfield department = new AdapterSubfield { AttributeType = AttributeType.String, FieldName = "department", IsMultivalued = false, PropertyName = "Department", Operation = AttributeOperation.ImportExport, AttributeNamePart = "department" }; AdapterSubfield symbol = new AdapterSubfield { AttributeType = AttributeType.String, FieldName = "symbol", IsMultivalued = false, PropertyName = "Symbol", Operation = AttributeOperation.ImportExport, AttributeNamePart = "symbol" }; AdapterSubfield location = new AdapterSubfield { AttributeType = AttributeType.String, FieldName = "location", IsMultivalued = false, PropertyName = "Location", Operation = AttributeOperation.ImportExport, AttributeNamePart = "location" }; AdapterSubfield description = new AdapterSubfield { AttributeType = AttributeType.String, FieldName = "description", IsMultivalued = false, PropertyName = "Description", Operation = AttributeOperation.ImportExport, AttributeNamePart = "description" }; AdapterSubfield domain = new AdapterSubfield { AttributeType = AttributeType.String, FieldName = "domain", IsMultivalued = false, PropertyName = "Domain", Operation = AttributeOperation.ImportExport, AttributeNamePart = "domain" }; AdapterSubfield costCenter = new AdapterSubfield { AttributeType = AttributeType.String, FieldName = "costCenter", IsMultivalued = false, PropertyName = "CostCenter", Operation = AttributeOperation.ImportExport, AttributeNamePart = "costCenter" }; AdapterCustomTypeList <ManagedObjects.Organization> customType = new AdapterCustomTypeList <ManagedObjects.Organization> { Api = "user", AttributeName = "organizations", Fields = new List <AdapterSubfield>() { name, title, department, symbol, location, description, domain, costCenter }, FieldName = "organizations", PropertyName = "Organizations", IsPrimaryCandidateType = true, KnownTypes = config.OrganizationsAttributeFixedTypes?.ToList(), SupportsPatch = false }; type.AttributeAdapters.Add(customType); }