public void Build(Microsoft.Management.Odata.Schema.Schema logicalSchema, Microsoft.Management.Odata.Schema.Schema userSchema, UserContext userContext, string membershipId) { ResourceSet resourceSet = null; if (logicalSchema.ResourceSets.TryGetValue("CommandInvocations", out resourceSet)) { string str = "PowerShell.CommandInvocation"; userSchema.AddEntity(str, true, logicalSchema); userSchema.EntityMetadataDictionary.Add(str, logicalSchema.EntityMetadataDictionary[str]); userSchema.PopulateAllRelevantResourceTypes(logicalSchema); } }
internal void Build(Microsoft.Management.Odata.Schema.Schema logicalSchema, Microsoft.Management.Odata.Schema.Schema userSchema, Runspace runspace) { HashSet<string> strs = null; Dictionary<string, CommandInfo> strs1 = null; PSSchemaBuilder.GetCommands(runspace, out strs, out strs1); List<PSSchemaBuilder.EntityDataForSchemaBuilding> entityDataForSchemaBuildings = this.CreateEntityDataForSchemaBuilding(logicalSchema, strs); this.AddEntitiesToSchema(logicalSchema, userSchema, entityDataForSchemaBuildings, strs1); userSchema.PopulateAllRelevantResourceTypes(logicalSchema); }