/// <summary>
 /// Initializes client properties.
 /// </summary>
 private void Initialize()
 {
     Organization          = new OrganizationOperations(this);
     User                  = new UserOperations(this);
     BaseUri               = new System.Uri("http://localhost");
     SerializationSettings = new JsonSerializerSettings
     {
         Formatting            = Newtonsoft.Json.Formatting.Indented,
         DateFormatHandling    = Newtonsoft.Json.DateFormatHandling.IsoDateFormat,
         DateTimeZoneHandling  = Newtonsoft.Json.DateTimeZoneHandling.Utc,
         NullValueHandling     = Newtonsoft.Json.NullValueHandling.Ignore,
         ReferenceLoopHandling = Newtonsoft.Json.ReferenceLoopHandling.Serialize,
         ContractResolver      = new ReadOnlyJsonContractResolver(),
         Converters            = new  List <JsonConverter>
         {
             new Iso8601TimeSpanConverter()
         }
     };
     DeserializationSettings = new JsonSerializerSettings
     {
         DateFormatHandling    = Newtonsoft.Json.DateFormatHandling.IsoDateFormat,
         DateTimeZoneHandling  = Newtonsoft.Json.DateTimeZoneHandling.Utc,
         NullValueHandling     = Newtonsoft.Json.NullValueHandling.Ignore,
         ReferenceLoopHandling = Newtonsoft.Json.ReferenceLoopHandling.Serialize,
         ContractResolver      = new ReadOnlyJsonContractResolver(),
         Converters            = new List <JsonConverter>
         {
             new Iso8601TimeSpanConverter()
         }
     };
     CustomInitialize();
 }
 public ModuleController()
 {
     // Replace the URI with the one that points to your local instance.
     var client = new GilboyDemoUiApi(new Uri("http://localhost:63050/"));
     _userService = new UserOperations(client);
     _moduleService = new ModuleOperations(client);
 }
Esempio n. 3
0
 /// <summary>
 /// Retrieves a redirection URL containing an authentication token for signing
 /// a given user into the developer portal.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='resourceGroupName'>
 /// The name of the resource group.
 /// </param>
 /// <param name='serviceName'>
 /// The name of the API Management service.
 /// </param>
 /// <param name='userId'>
 /// User identifier. Must be unique in the current API Management service
 /// instance.
 /// </param>
 /// <param name='cancellationToken'>
 /// The cancellation token.
 /// </param>
 public static async Task <GenerateSsoUrlResult> GenerateSsoUrlAsync(this IUserOperations operations, string resourceGroupName, string serviceName, string userId, CancellationToken cancellationToken = default(CancellationToken))
 {
     using (var _result = await operations.GenerateSsoUrlWithHttpMessagesAsync(resourceGroupName, serviceName, userId, null, cancellationToken).ConfigureAwait(false))
     {
         return(_result.Body);
     }
 }
Esempio n. 4
0
 /// <summary>
 /// Gets the Shared Access Authorization Token for the User.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='resourceGroupName'>
 /// The name of the resource group.
 /// </param>
 /// <param name='serviceName'>
 /// The name of the API Management service.
 /// </param>
 /// <param name='userId'>
 /// User identifier. Must be unique in the current API Management service
 /// instance.
 /// </param>
 /// <param name='parameters'>
 /// Create Authorization Token parameters.
 /// </param>
 /// <param name='cancellationToken'>
 /// The cancellation token.
 /// </param>
 public static async Task <UserTokenResult> GetSharedAccessTokenAsync(this IUserOperations operations, string resourceGroupName, string serviceName, string userId, UserTokenParameters parameters, CancellationToken cancellationToken = default(CancellationToken))
 {
     using (var _result = await operations.GetSharedAccessTokenWithHttpMessagesAsync(resourceGroupName, serviceName, userId, parameters, null, cancellationToken).ConfigureAwait(false))
     {
         return(_result.Body);
     }
 }
Esempio n. 5
0
 /// <summary>
 /// Lists a collection of registered users in the specified service instance.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='nextPageLink'>
 /// The NextLink from the previous successful call to List operation.
 /// </param>
 /// <param name='cancellationToken'>
 /// The cancellation token.
 /// </param>
 public static async Task <IPage <UserContract> > ListByServiceNextAsync(this IUserOperations operations, string nextPageLink, CancellationToken cancellationToken = default(CancellationToken))
 {
     using (var _result = await operations.ListByServiceNextWithHttpMessagesAsync(nextPageLink, null, cancellationToken).ConfigureAwait(false))
     {
         return(_result.Body);
     }
 }
Esempio n. 6
0
 public UserService(IUserOperations userOperations, IAuthenticationContext authenticationContext, ISettingProvider settingProvider, IEnvironmentPrebuilder environmentPrebuilder)
 {
     _userOperations        = userOperations;
     _authenticationContext = authenticationContext;
     _settingProvider       = settingProvider;
     _environmentPrebuilder = environmentPrebuilder;
 }
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='id'>
 /// </param>
 /// <param name='cancellationToken'>
 /// The cancellation token.
 /// </param>
 public static async Task <User> GetAsync(this IUserOperations operations, string id, CancellationToken cancellationToken = default(CancellationToken))
 {
     using (var _result = await operations.GetWithHttpMessagesAsync(id, null, cancellationToken).ConfigureAwait(false))
     {
         return(_result.Body);
     }
 }
Esempio n. 8
0
 /// <summary>
 /// Updates the details of the user specified by its identifier.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='resourceGroupName'>
 /// The name of the resource group.
 /// </param>
 /// <param name='serviceName'>
 /// The name of the API Management service.
 /// </param>
 /// <param name='userId'>
 /// User identifier. Must be unique in the current API Management service
 /// instance.
 /// </param>
 /// <param name='parameters'>
 /// Update parameters.
 /// </param>
 /// <param name='ifMatch'>
 /// ETag of the Entity. ETag should match the current entity state from the
 /// header response of the GET request or it should be * for unconditional
 /// update.
 /// </param>
 /// <param name='cancellationToken'>
 /// The cancellation token.
 /// </param>
 public static async Task <UserContract> UpdateAsync(this IUserOperations operations, string resourceGroupName, string serviceName, string userId, UserUpdateParameters parameters, string ifMatch, CancellationToken cancellationToken = default(CancellationToken))
 {
     using (var _result = await operations.UpdateWithHttpMessagesAsync(resourceGroupName, serviceName, userId, parameters, ifMatch, null, cancellationToken).ConfigureAwait(false))
     {
         return(_result.Body);
     }
 }
Esempio n. 9
0
 /// <summary>
 /// Returns calling user identity information.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='resourceGroupName'>
 /// The name of the resource group.
 /// </param>
 /// <param name='serviceName'>
 /// The name of the API Management service.
 /// </param>
 /// <param name='cancellationToken'>
 /// The cancellation token.
 /// </param>
 public static async Task <CurrentUserIdentity> GetIdentityAsync(this IUserOperations operations, string resourceGroupName, string serviceName, CancellationToken cancellationToken = default(CancellationToken))
 {
     using (var _result = await operations.GetIdentityWithHttpMessagesAsync(resourceGroupName, serviceName, null, cancellationToken).ConfigureAwait(false))
     {
         return(_result.Body);
     }
 }
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='body'>
 /// </param>
 /// <param name='cancellationToken'>
 /// The cancellation token.
 /// </param>
 public static async Task <User> CreateAsync(this IUserOperations operations, UserCreateModel body = default(UserCreateModel), CancellationToken cancellationToken = default(CancellationToken))
 {
     using (var _result = await operations.CreateWithHttpMessagesAsync(body, null, cancellationToken).ConfigureAwait(false))
     {
         return(_result.Body);
     }
 }
Esempio n. 11
0
 /// <summary>
 /// Initializes a new instance of the <see cref="TokenController"/> class.
 /// </summary>
 /// <param name="config">The global configuration</param>
 /// <param name="userOperations">The user operations</param>
 public TokenController(
     IConfiguration config,
     IUserOperations userOperations)
 {
     _config         = config;
     _userOperations = userOperations;
 }
Esempio n. 12
0
 /// <summary>
 /// Initializes a new instance of the Meetuphh class.
 /// </summary>
 /// <param name='rootHandler'>
 /// Optional. The http client handler used to handle http transport.
 /// </param>
 /// <param name='handlers'>
 /// Optional. The set of delegating handlers to insert in the http
 /// client pipeline.
 /// </param>
 public Meetuphh(HttpClientHandler rootHandler, params DelegatingHandler[] handlers)
     : base(rootHandler, handlers)
 {
     this._mail    = new Mail(this);
     this._user    = new UserOperations(this);
     this._baseUri = new Uri("https://microsoft-apiapp21ee0a3b45e043e58aa5068ad2488263.azurewebsites.net");
 }
Esempio n. 13
0
 /// <summary>
 /// Gets the entity state (Etag) version of the user specified by its
 /// identifier.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='resourceGroupName'>
 /// The name of the resource group.
 /// </param>
 /// <param name='serviceName'>
 /// The name of the API Management service.
 /// </param>
 /// <param name='userId'>
 /// User identifier. Must be unique in the current API Management service
 /// instance.
 /// </param>
 /// <param name='cancellationToken'>
 /// The cancellation token.
 /// </param>
 public static async Task <UserGetEntityTagHeaders> GetEntityTagAsync(this IUserOperations operations, string resourceGroupName, string serviceName, string userId, CancellationToken cancellationToken = default(CancellationToken))
 {
     using (var _result = await operations.GetEntityTagWithHttpMessagesAsync(resourceGroupName, serviceName, userId, null, cancellationToken).ConfigureAwait(false))
     {
         return(_result.Headers);
     }
 }
Esempio n. 14
0
 /// <summary>
 /// Lists a collection of registered users in the specified service instance.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='resourceGroupName'>
 /// The name of the resource group.
 /// </param>
 /// <param name='serviceName'>
 /// The name of the API Management service.
 /// </param>
 /// <param name='odataQuery'>
 /// OData parameters to apply to the operation.
 /// </param>
 /// <param name='expandGroups'>
 /// Detailed Group in response.
 /// </param>
 /// <param name='cancellationToken'>
 /// The cancellation token.
 /// </param>
 public static async Task <IPage <UserContract> > ListByServiceAsync(this IUserOperations operations, string resourceGroupName, string serviceName, ODataQuery <UserContract> odataQuery = default(ODataQuery <UserContract>), bool?expandGroups = default(bool?), CancellationToken cancellationToken = default(CancellationToken))
 {
     using (var _result = await operations.ListByServiceWithHttpMessagesAsync(resourceGroupName, serviceName, odataQuery, expandGroups, null, cancellationToken).ConfigureAwait(false))
     {
         return(_result.Body);
     }
 }
Esempio n. 15
0
 /// <summary>
 /// Initializes a new instance of the Meetuphh class.
 /// </summary>
 public Meetuphh()
     : base()
 {
     this._mail    = new Mail(this);
     this._user    = new UserOperations(this);
     this._baseUri = new Uri("https://microsoft-apiapp21ee0a3b45e043e58aa5068ad2488263.azurewebsites.net");
 }
Esempio n. 16
0
 /// <param name='operations'>
 /// Reference to the AzureWebApp.IUserOperations.
 /// </param>
 public static IList <User> GetAllUsers(this IUserOperations operations)
 {
     return(Task.Factory.StartNew((object s) =>
     {
         return ((IUserOperations)s).GetAllUsersAsync();
     }
                                  , operations, CancellationToken.None, TaskCreationOptions.None, TaskScheduler.Default).Unwrap().GetAwaiter().GetResult());
 }
Esempio n. 17
0
 public DbDataProvider(IUserOperations user, IInstanceOperations instance, IDatabaseInitializer initializer)
 {
     Logger.Setup();
     _initializer = initializer;
     _initializer.Initialize();
     this.User     = user;
     this.Instance = instance;
 }
 private void InitSubApis()
 {
     _articleOperations      = new ArticleTemplate(RestTemplate, IsAuthorized);
     _bookmarkOperations     = new BookmarkTemplate(RestTemplate, IsAuthorized);
     _contributionOperations = new ContributionTemplate(RestTemplate, IsAuthorized);
     _rootOperations         = new RootTemplate(RestTemplate, IsAuthorized);
     _userOperations         = new UserTemplate(RestTemplate, IsAuthorized);
 }
Esempio n. 19
0
 /// <summary>
 /// Gets user information from the directory.
 /// </summary>
 /// <param name='operations'>
 /// Reference to the Microsoft.Azure.Graph.RBAC.IUserOperations.
 /// </param>
 /// <param name='signInName'>
 /// Required. filter based on sign in name
 /// </param>
 /// <returns>
 /// Server response for Get tenant users API call
 /// </returns>
 public static UserListResult GetBySignInName(this IUserOperations operations, string signInName)
 {
     return(Task.Factory.StartNew((object s) =>
     {
         return ((IUserOperations)s).GetBySignInNameAsync(signInName);
     }
                                  , operations, CancellationToken.None, TaskCreationOptions.None, TaskScheduler.Default).Unwrap().GetAwaiter().GetResult());
 }
Esempio n. 20
0
 /// <summary>
 /// Gets list of users for the current tenant.
 /// </summary>
 /// <param name='operations'>
 /// Reference to the Microsoft.Azure.Graph.RBAC.IUserOperations.
 /// </param>
 /// <param name='mail'>
 /// Optional. Email to filter results.
 /// </param>
 /// <param name='displayNameStartsWith'>
 /// Optional. Display name to filter results.
 /// </param>
 /// <returns>
 /// Server response for Get tenant users API call
 /// </returns>
 public static UserListResult List(this IUserOperations operations, string mail, string displayNameStartsWith)
 {
     return(Task.Factory.StartNew((object s) =>
     {
         return ((IUserOperations)s).ListAsync(mail, displayNameStartsWith);
     }
                                  , operations, CancellationToken.None, TaskCreationOptions.None, TaskScheduler.Default).Unwrap().GetAwaiter().GetResult());
 }
Esempio n. 21
0
 /// <param name='operations'>
 /// Reference to the AzureWebApp.IUserOperations.
 /// </param>
 /// <param name='user'>
 /// Required.
 /// </param>
 public static object UpdateUserByUser(this IUserOperations operations, User user)
 {
     return(Task.Factory.StartNew((object s) =>
     {
         return ((IUserOperations)s).UpdateUserByUserAsync(user);
     }
                                  , operations, CancellationToken.None, TaskCreationOptions.None, TaskScheduler.Default).Unwrap().GetAwaiter().GetResult());
 }
Esempio n. 22
0
 /// <summary>
 /// Create a new user.  (see
 /// http://msdn.microsoft.com/en-us/library/azure/dn130117.aspx for
 /// more information)
 /// </summary>
 /// <param name='operations'>
 /// Reference to the Microsoft.Azure.Graph.RBAC.IUserOperations.
 /// </param>
 /// <param name='parameters'>
 /// Required. Parameters to create a user.
 /// </param>
 /// <returns>
 /// Server response for Get user information API call
 /// </returns>
 public static UserGetResult Create(this IUserOperations operations, UserCreateParameters parameters)
 {
     return(Task.Factory.StartNew((object s) =>
     {
         return ((IUserOperations)s).CreateAsync(parameters);
     }
                                  , operations, CancellationToken.None, TaskCreationOptions.None, TaskScheduler.Default).Unwrap().GetAwaiter().GetResult());
 }
Esempio n. 23
0
 /// <summary>
 /// Gets list of users for the current tenant.
 /// </summary>
 /// <param name='operations'>
 /// Reference to the Microsoft.Azure.Graph.RBAC.IUserOperations.
 /// </param>
 /// <param name='nextLink'>
 /// Required. NextLink from the previous successful call to List
 /// operation.
 /// </param>
 /// <returns>
 /// Server response for Get tenant users API call
 /// </returns>
 public static UserListResult ListNext(this IUserOperations operations, string nextLink)
 {
     return(Task.Factory.StartNew((object s) =>
     {
         return ((IUserOperations)s).ListNextAsync(nextLink);
     }
                                  , operations, CancellationToken.None, TaskCreationOptions.None, TaskScheduler.Default).Unwrap().GetAwaiter().GetResult());
 }
Esempio n. 24
0
 /// <summary>
 /// Delete a user.  (see
 /// http://msdn.microsoft.com/en-us/library/azure/dn151676.aspx for
 /// more information)
 /// </summary>
 /// <param name='operations'>
 /// Reference to the Microsoft.Azure.Graph.RBAC.IUserOperations.
 /// </param>
 /// <param name='user'>
 /// Required. user object id or user principal name
 /// </param>
 /// <returns>
 /// A standard service response including an HTTP status code and
 /// request ID.
 /// </returns>
 public static AzureOperationResponse Delete(this IUserOperations operations, string user)
 {
     return(Task.Factory.StartNew((object s) =>
     {
         return ((IUserOperations)s).DeleteAsync(user);
     }
                                  , operations, CancellationToken.None, TaskCreationOptions.None, TaskScheduler.Default).Unwrap().GetAwaiter().GetResult());
 }
Esempio n. 25
0
 public WorkTimeService(IContractOperations contractOperations, IHolidayOperations holidayOperations, IUserOperations userOperations, IWorkTimeOperations workTimeOperations, IDepartmentOperations departmentOperations, IUrlHelper urlHelper)
 {
     _contractOperations   = contractOperations;
     _holidayOperations    = holidayOperations;
     _userOperations       = userOperations;
     _workTimeOperations   = workTimeOperations;
     _departmentOperations = departmentOperations;
     _urlHelper            = urlHelper;
 }
 public MineSweeperOperations(ICreateGrid createGrid, ICheckSquare checkSquare, IDigSquare digSquare, IFlagSquare flagSquare,
                              IUserOperations userOperations)
 {
     _createGrid     = createGrid;
     _checkSquare    = checkSquare;
     _digSquare      = digSquare;
     _flagSquare     = flagSquare;
     _userOperations = userOperations;
     _grid           = FillGrid();
 }
Esempio n. 27
0
 private void InitSubApis()
 {
     _userOperations      = new UserTemplate(RestTemplate, IsAuthorized);
     _cardOperations      = new CardTemplate(RestTemplate, IsAuthorized);
     _microOperations     = new MicroTemplate(RestTemplate, IsAuthorized);
     _followerOperations  = new FollowerTemplate(RestTemplate, IsAuthorized);
     _followingOperations = new FollowingTemplate(RestTemplate, IsAuthorized);
     _activityOperations  = new ActivityTemplate(RestTemplate, IsAuthorized);
     _highfiveOperations  = new HighfiveTemplate(RestTemplate, IsAuthorized);
 }
 private void InitSubApis()
 {
     this.blockOperations         = new BlockTemplate(this.RestTemplate);
     this.directMessageOperations = new DirectMessageTemplate(this.RestTemplate);
     this.friendOperations        = new FriendTemplate(this.RestTemplate);
     this.geoOperations           = new GeoTemplate(this.RestTemplate);
     this.listOperations          = new ListTemplate(this.RestTemplate);
     this.searchOperations        = new SearchTemplate(this.RestTemplate);
     this.timelineOperations      = new TimelineTemplate(this.RestTemplate);
     this.userOperations          = new UserTemplate(this.RestTemplate);
 }
Esempio n. 29
0
 /// <summary>
 /// Initializes a new instance of the GraphRbacManagementClient class.
 /// </summary>
 /// <param name='httpClient'>
 /// The Http client
 /// </param>
 public GraphRbacManagementClient(HttpClient httpClient)
     : base(httpClient)
 {
     this._application      = new ApplicationOperations(this);
     this._group            = new GroupOperations(this);
     this._objects          = new ObjectOperations(this);
     this._servicePrincipal = new ServicePrincipalOperations(this);
     this._user             = new UserOperations(this);
     this._apiVersion       = "1.42-previewInternal";
     this._longRunningOperationInitialTimeout = -1;
     this._longRunningOperationRetryTimeout   = -1;
     this.HttpClient.Timeout = TimeSpan.FromSeconds(300);
 }
Esempio n. 30
0
 private void InitSubApis()
 {
     this.userOperations      = new UserTemplate(this.applicationNamespace, this.RestTemplate, this.IsAuthorized);
     this.placesOperations    = new PlacesTemplate(this.applicationNamespace, this.RestTemplate, this.IsAuthorized);
     this.friendOperations    = new FriendTemplate(this.applicationNamespace, this.RestTemplate, this.IsAuthorized);
     this.feedOperations      = new FeedTemplate(this.applicationNamespace, this.RestTemplate, this.IsAuthorized);
     this.groupOperations     = new GroupTemplate(this.applicationNamespace, this.RestTemplate, this.IsAuthorized);
     this.commentOperations   = new CommentTemplate(this.applicationNamespace, this.RestTemplate, this.IsAuthorized);
     this.likeOperations      = new LikeTemplate(this.applicationNamespace, this.RestTemplate, this.IsAuthorized);
     this.eventOperations     = new EventTemplate(this.applicationNamespace, this.RestTemplate, this.IsAuthorized);
     this.mediaOperations     = new MediaTemplate(this.applicationNamespace, this.RestTemplate, this.IsAuthorized);
     this.pageOperations      = new PageTemplate(this.applicationNamespace, this.RestTemplate, this.IsAuthorized);
     this.fqlOperations       = new FqlTemplate(this.applicationNamespace, this.RestTemplate, this.IsAuthorized);
     this.questionOperations  = new QuestionTemplate(this.applicationNamespace, this.RestTemplate, this.IsAuthorized);
     this.openGraphOperations = new OpenGraphTemplate(this.applicationNamespace, this.RestTemplate, this.IsAuthorized);
 }
Esempio n. 31
0
        /// <summary>
        /// Retrieve partner user Id for user having globalUserId
        /// </summary>
        /// <param name="globalUserId">Global identifier for a user</param>
        /// <param name="partner">Represents partners with which the Commerce platform interacts.</param>
        /// <param name="userOperations">The object to use to perform user operations.</param>
        /// <param name="context">The context of the worker action being executed.</param>
        /// <returns>Partner User Id.</returns>
        public static string RetrieveUserId(Guid globalUserId, Partner partner, IUserOperations userOperations,
                                            CommerceContext context)
        {
            var    user         = RetrieveUserRecord(globalUserId, userOperations, context);
            string parterUserId = null;

            if (user != null)
            {
                parterUserId = user.PartnerUserInfoList.Where(pu => pu.PartnerId == partner).Select(pu => pu.PartnerUserId).FirstOrDefault();
            }

            if (parterUserId == null)
            {
                throw new Exception($"Unable to find PartnerUserId for GlobalUserId:{globalUserId}, Partner:{partner}");
            }

            return(parterUserId);
        }
		private void InitSubApis()
		{
			this.userOperations      = new UserTemplate     (this.applicationNamespace, this.RestTemplate, this.IsAuthorized);
			this.placesOperations    = new PlacesTemplate   (this.applicationNamespace, this.RestTemplate, this.IsAuthorized);
			this.friendOperations    = new FriendTemplate   (this.applicationNamespace, this.RestTemplate, this.IsAuthorized);
			this.feedOperations      = new FeedTemplate     (this.applicationNamespace, this.RestTemplate, this.IsAuthorized);
			this.groupOperations     = new GroupTemplate    (this.applicationNamespace, this.RestTemplate, this.IsAuthorized);
			this.commentOperations   = new CommentTemplate  (this.applicationNamespace, this.RestTemplate, this.IsAuthorized);
			this.likeOperations      = new LikeTemplate     (this.applicationNamespace, this.RestTemplate, this.IsAuthorized);
			this.eventOperations     = new EventTemplate    (this.applicationNamespace, this.RestTemplate, this.IsAuthorized);
			this.mediaOperations     = new MediaTemplate    (this.applicationNamespace, this.RestTemplate, this.IsAuthorized);
			this.pageOperations      = new PageTemplate     (this.applicationNamespace, this.RestTemplate, this.IsAuthorized);
			this.fqlOperations       = new FqlTemplate      (this.applicationNamespace, this.RestTemplate, this.IsAuthorized);
			this.questionOperations  = new QuestionTemplate (this.applicationNamespace, this.RestTemplate, this.IsAuthorized);
			this.openGraphOperations = new OpenGraphTemplate(this.applicationNamespace, this.RestTemplate, this.IsAuthorized);
		}
 private void InitSubApis()
 {
     if (!isIntialized())
     {
         companyMetaDataOperations = new CompanyMetaDataTemplate(this.RestTemplate);
         this.companyId = this.companyMetaDataOperations.CompanyMetaData().ExternalRealmId;
         accountOperations = new AccountTemplate(this.RestTemplate, IsAuthorized, this.companyId);
         customerOperations = new CustomerTemplate(this.RestTemplate, IsAuthorized, this.companyId);
         invoiceOperations = new InvoiceTemplate(this.RestTemplate, IsAuthorized, this.companyId);
         itemOperations = new ItemTemplate(this.RestTemplate, IsAuthorized, this.companyId);
         paymentMethodOperations = new PaymentMethodTemplate(this.RestTemplate, IsAuthorized, this.companyId);
         paymentOperations = new PaymentTemplate(this.RestTemplate, IsAuthorized, this.companyId);
         userOperations = new UserTemplate(this.RestTemplate, IsAuthorized);
     }
 }
 private void InitSubApis()
 {
     this.blockOperations = new BlockTemplate(this.RestTemplate, this.IsAuthorized);
     this.directMessageOperations = new DirectMessageTemplate(this.RestTemplate, this.IsAuthorized);
     this.friendOperations = new FriendTemplate(this.RestTemplate, this.IsAuthorized);
     this.geoOperations = new GeoTemplate(this.RestTemplate, this.IsAuthorized);
     this.listOperations = new ListTemplate(this.RestTemplate, this.IsAuthorized);
     this.searchOperations = new SearchTemplate(this.RestTemplate, this.IsAuthorized);
     this.timelineOperations = new TimelineTemplate(this.RestTemplate, this.IsAuthorized);
     this.userOperations = new UserTemplate(this.RestTemplate, this.IsAuthorized);
 }
Esempio n. 35
0
 public UserManagementController(IUserOperations operations, IActivityOperations activityOperations)
 {
     _operations = operations;
     _activityOperations = activityOperations;
 }
Esempio n. 36
0
 public UsersController(IUserOperations operations)
 {
     _operations = operations;
 }
Esempio n. 37
0
        private void InitSubApis()
        {
            _userOperations = new UserTemplate(RestTemplate, IsAuthorized);
			_cardOperations = new CardTemplate(RestTemplate, IsAuthorized);
			_microOperations = new MicroTemplate(RestTemplate, IsAuthorized);
			_followerOperations = new FollowerTemplate(RestTemplate, IsAuthorized);
			_followingOperations = new FollowingTemplate(RestTemplate, IsAuthorized);
			_activityOperations = new ActivityTemplate(RestTemplate, IsAuthorized);
			_highfiveOperations = new HighfiveTemplate(RestTemplate, IsAuthorized);
        }
Esempio n. 38
0
 //
 // GET: /UserMvc/
 public MvcController()
 {
     // Only for sample, it can be injected into the constructor
     repository_ = Data.UserOperations.OperationFactory;
 }
        private void InitSubApis()
        {
			_articleOperations = new ArticleTemplate(RestTemplate, IsAuthorized);
			_bookmarkOperations = new BookmarkTemplate(RestTemplate, IsAuthorized);
			_contributionOperations = new ContributionTemplate(RestTemplate, IsAuthorized);
			_rootOperations = new RootTemplate(RestTemplate, IsAuthorized);
			_userOperations = new UserTemplate(RestTemplate, IsAuthorized);
        }