public static IGroup CreateGroup(IInternalSyncDataStore internalDataStore, string groupsHref, string name, string description) { var group = internalDataStore.Instantiate<IGroup>() .SetName(name) .SetDescription(description) .SetStatus(GroupStatus.Enabled); return internalDataStore.Create(groupsHref, group); }
public static IGroup CreateGroup(IInternalSyncDataStore internalDataStore, string groupsHref, string name, string description) { var group = internalDataStore.Instantiate <IGroup>() .SetName(name) .SetDescription(description) .SetStatus(GroupStatus.Enabled); return(internalDataStore.Create(groupsHref, group)); }
/// <summary> /// Synchronously adds an Account Store to this resource. /// </summary> /// <typeparam name="TMapping">The Account Store Mapping type.</typeparam> /// <param name="container">The Account Store container.</param> /// <param name="internalDataStore">The internal data store.</param> /// <param name="accountStore">The Account Store to add.</param> /// <returns>The new <see cref="IAccountStoreMapping"/>.</returns> public static TMapping AddAccountStore <TMapping>( IAccountStoreContainer <TMapping> container, IInternalSyncDataStore internalDataStore, IAccountStore accountStore) where TMapping : class, IAccountStoreMapping <TMapping> { var accountStoreMapping = internalDataStore .Instantiate <IAccountStoreMapping <TMapping> >() .SetAccountStore(accountStore) .SetListIndex(int.MaxValue); SetContainer(accountStoreMapping, container); return(CreateAccountStoreMapping(container, internalDataStore, accountStoreMapping)); }