private object[] GetTaskOperations(AzManAuthorizationProviderData data, IAzApplication azApp, string[] tasks) { string[] scopes = new string[] { data.Scope }; StringCollection operations = new StringCollection(); foreach (String task in tasks) { IAzScope scope = null; if ((scopes != null) && (scopes[0].Length > 0)) { scope = azApp.OpenScope(scopes[0], null); } IAzTask azTask = null; if (scope != null) { azTask = scope.OpenTask(task, null); } else { azTask = azApp.OpenTask(task, null); } Array ops = azTask.Operations as Array; Debug.Assert(ops != null); foreach (String op in ops) { operations.Add(op); } } if (operations.Count == 0) { throw new ConfigurationException(SR.NoOperations); } object[] operationIds = new object[operations.Count]; for (int index = 0; index < operations.Count; index++) { operationIds[index] = azApp.OpenOperation(operations[index], null).OperationID; } return(operationIds); }
private object[] GetTaskOperations(IAzApplication azApp, string[] tasks) { string[] scopes = new string[] { this.scopeName }; StringCollection operations = new StringCollection(); foreach (String task in tasks) { IAzScope scope = null; if ((scopes != null) && (scopes[0].Length > 0)) { scope = azApp.OpenScope(scopes[0], null); } IAzTask azTask = null; if (scope != null) { azTask = scope.OpenTask(task, null); } else { azTask = azApp.OpenTask(task, null); } Array ops = azTask.Operations as Array; foreach (String op in ops) { operations.Add(op); } } if (operations.Count == 0) { throw new ConfigurationErrorsException(Properties.Resources.NoOperations); } object[] operationIds = new object[operations.Count]; for (int index = 0; index < operations.Count; index++) { operationIds[index] = azApp.OpenOperation(operations[index], null).OperationID; } return(operationIds); }
private object[] GetTaskOperations(IAzApplication azApp, string[] tasks) { string[] scopes = new string[] { this.scopeName }; StringCollection operations = new StringCollection(); foreach (String task in tasks) { IAzScope scope = null; if ((scopes != null) && (scopes[0].Length > 0)) { scope = azApp.OpenScope(scopes[0], null); } IAzTask azTask = null; if (scope != null) { azTask = scope.OpenTask(task, null); } else { azTask = azApp.OpenTask(task, null); } Array ops = azTask.Operations as Array; foreach (String op in ops) { operations.Add(op); } } if (operations.Count == 0) { throw new ConfigurationErrorsException(Properties.Resources.NoOperations); } object[] operationIds = new object[operations.Count]; for (int index = 0; index < operations.Count; index++) { operationIds[index] = azApp.OpenOperation(operations[index], null).OperationID; } return operationIds; }
private object[] GetTaskOperations(AzManAuthorizationProviderData data, IAzApplication azApp, string[] tasks) { string[] scopes = new string[] {data.Scope}; StringCollection operations = new StringCollection(); foreach (String task in tasks) { IAzScope scope = null; if ((scopes != null) && (scopes[0].Length > 0)) { scope = azApp.OpenScope(scopes[0], null); } IAzTask azTask = null; if (scope != null) { azTask = scope.OpenTask(task, null); } else { azTask = azApp.OpenTask(task, null); } Array ops = azTask.Operations as Array; Debug.Assert(ops != null); foreach (String op in ops) { operations.Add(op); } } if (operations.Count == 0) { throw new ConfigurationException(SR.NoOperations); } object[] operationIds = new object[operations.Count]; for (int index = 0; index < operations.Count; index++) { operationIds[index] = azApp.OpenOperation(operations[index], null).OperationID; } return operationIds; }