/// ----------------------------------------------------------------------------- /// <summary> /// Serializes all Folder Permissions /// </summary> /// <param name="objportal">Portal to serialize</param> /// <param name="folderPath">The folder containing the files</param> /// <remarks> /// The serialization uses the xml attributes defined in FolderInfo class. /// </remarks> /// <history> /// [cnurse] 11/08/2004 Created /// </history> /// ----------------------------------------------------------------------------- private void SerializeFolderPermissions(XmlWriter writer, PortalInfo objportal, string folderPath) { FolderPermissionCollection permissions = FolderPermissionController.GetFolderPermissionsCollectionByFolder(objportal.PortalID, folderPath); writer.WriteStartElement("folderpermissions"); foreach (FolderPermissionInfo permission in permissions) { writer.WriteStartElement("permission"); writer.WriteElementString("permissioncode", permission.PermissionCode); writer.WriteElementString("permissionkey", permission.PermissionKey); writer.WriteElementString("rolename", permission.RoleName); writer.WriteElementString("allowaccess", permission.AllowAccess.ToString().ToLowerInvariant()); writer.WriteEndElement(); } writer.WriteEndElement(); }
/// ----------------------------------------------------------------------------- /// <summary> /// Gets the TabPermissions from the Data Store /// </summary> /// ----------------------------------------------------------------------------- protected virtual void GetFolderPermissions() { FolderPermissions = new FolderPermissionCollection(FolderPermissionController.GetFolderPermissionsCollectionByFolder(PortalId, FolderPath)); _permissionsList = null; }