public static void InitClientDefinition() { var clientDefinition = new ClientGeneratorDefinition(); SetCommonDefaults(clientDefinition); WorkingDefinition = clientDefinition; }
public static void DeserializeDefinition(string path) { XmlSerializer deserializer = new XmlSerializer(typeof(SerializeWrapper), new Type[] { typeof(ClientGeneratorDefinition), typeof(ServerGeneratorDefinition) }); TextReader reader = new StreamReader(path); object obj = deserializer.Deserialize(reader); WorkingDefinition = ((SerializeWrapper)obj).Definition; reader.Close(); }
public static void InitServerDefinition() { var serverDefinition = new ServerGeneratorDefinition(); SetCommonDefaults(serverDefinition); serverDefinition.CredentialsOfCurrentUser = true; serverDefinition.CreateNewWebApplications = 0; WorkingDefinition = serverDefinition; }
private static void SetCommonDefaults(GeneratorDefinitionBase definition) { definition.NumberOfSecurityGroupsToCreate = 0; definition.NumberOfUsersToCreate = 0; definition.NumberOfSitesToCreate = 300; definition.MaxNumberOfColumnsPerList = 0; definition.MaxNumberOfContentTypesPerSiteCollection = 0; definition.MaxNumberOfFoldersToGenerate = 0; definition.MaxNumberofItemsToGenerate = 25; definition.MaxNumberOfLevelsForSites = 3; definition.MaxNumberOfListsAndLibrariesPerSite = 10; definition.MaxNumberOfViewsPerList = 0; definition.CreateNewSiteCollections = 1; definition.SiteTemplate = "Team Site"; definition.LibTypeList = true; definition.LibTypeDocument = true; definition.LibTypeCalendar = true; definition.LibTypeTasks = true; definition.CreateSomeFoldersInDocumentLibraries = true; definition.MaxNumberOfFoldersToGenerate = 10; definition.MaxNumberOfNestedFolderLevelPerLibrary = 3; definition.CreateColumns = true; definition.MaxNumberOfColumnsPerList = 3; definition.PrefilListAndLibrariesWithItems = true; definition.MaxNumberofItemsToGenerate = 30; definition.IncludeDocTypeDOCX = true; definition.IncludeDocTypePDF = true; definition.IncludeDocTypeImages = true; definition.IncludeDocTypeXLSX = true; definition.MinDocumentSizeKB = 100; definition.MaxDocumentSizeMB = 1; definition.ContentTypesCanInheritFromOtherContentType = true; definition.CreateContentTypes = true; definition.MaxNumberOfContentTypesPerSiteCollection = 10; definition.PermissionsPercentOfSites = 60; definition.PermissionsPercentOfLists = 30; definition.PermissionsPerObject = 10; definition.PermissionsPercentForUsers = 20; definition.PermissionsPercentForSPGroups = 40; definition.PermissionsPercentOfListItems = 5; definition.MaxNumberofDocumentLibraryItemsToGenerate = 25; definition.PermissionsPercentOfFolders = 25; }
public SPDGServerDataHelper(GeneratorDefinitionBase definition) { _generatorDefinition = definition; }