public void SecureHandles(ref KNOWNFOLDER_DEFINITION_RAW d)
 {
     SecureHandle(this.hName, ref d.pszName);
     SecureHandle(this.hDescription, ref d.pszDescription);
     SecureHandle(this.hRelativePath, ref d.pszRelativePath);
     SecureHandle(this.hParsingName, ref d.pszParsingName);
     SecureHandle(this.hToolTip, ref d.pszToolTip);
     SecureHandle(this.hLocalizedName, ref d.pszLocalizedName);
     SecureHandle(this.hIcon, ref d.pszIcon);
     SecureHandle(this.hSecurity, ref d.pszSecurity);
 }
        private KNOWNFOLDER_DEFINITION(ref KNOWNFOLDER_DEFINITION_RAW d, KnownFolderDefinitionHandles h)
        {
            this.category     = d.category;
            this.fidParent    = d.fidParent;
            this.dwAttributes = d.dwAttributes;
            this.kfdFlags     = d.kfdFlags;
            this.ftidType     = d.ftidType;

            this.name          = UnmarshalString(h.hName, "hName");
            this.description   = UnmarshalString(h.hDescription, "hDescription");
            this.relativePath  = UnmarshalString(h.hRelativePath, "hRelativePath");
            this.parsingName   = UnmarshalString(h.hParsingName, "hParsingName");
            this.toolTip       = UnmarshalString(h.hToolTip, "hToolTip");
            this.localizedName = UnmarshalString(h.hLocalizedName, "hLocalizedName");
            this.icon          = UnmarshalString(h.hIcon, "hIcon");
            this.security      = UnmarshalString(h.hSecurity, "hSecurity");
        }
        private KNOWNFOLDER_DEFINITION(ref KNOWNFOLDER_DEFINITION_RAW d, KnownFolderDefinitionHandles h)
        {
            this.category = d.category;
            this.fidParent = d.fidParent;
            this.dwAttributes = d.dwAttributes;
            this.kfdFlags = d.kfdFlags;
            this.ftidType = d.ftidType;

            this.name = UnmarshalString(h.hName, "hName");
            this.description = UnmarshalString(h.hDescription, "hDescription");
            this.relativePath = UnmarshalString(h.hRelativePath, "hRelativePath");
            this.parsingName = UnmarshalString(h.hParsingName, "hParsingName");
            this.toolTip = UnmarshalString(h.hToolTip, "hToolTip");
            this.localizedName = UnmarshalString(h.hLocalizedName, "hLocalizedName");
            this.icon = UnmarshalString(h.hIcon, "hIcon");
            this.security = UnmarshalString(h.hSecurity, "hSecurity");
        }
 public void SecureHandles(ref KNOWNFOLDER_DEFINITION_RAW d)
 {
     SecureHandle(this.hName, ref d.pszName);
     SecureHandle(this.hDescription, ref d.pszDescription);
     SecureHandle(this.hRelativePath, ref d.pszRelativePath);
     SecureHandle(this.hParsingName, ref d.pszParsingName);
     SecureHandle(this.hToolTip, ref d.pszToolTip);
     SecureHandle(this.hLocalizedName, ref d.pszLocalizedName);
     SecureHandle(this.hIcon, ref d.pszIcon);
     SecureHandle(this.hSecurity, ref d.pszSecurity);
 }