public void SetAccessControl(RegistrySecurity registrySecurity) { EnsureWriteable(); ArgumentNullException.ThrowIfNull(registrySecurity); registrySecurity.Persist(Handle, Name); }
public static void SetAccessControl(this RegistryKey key, RegistrySecurity registrySecurity) { if (registrySecurity == null) { throw new ArgumentNullException("registrySecurity"); } registrySecurity.Persist(key.Handle, key.Name); }
public void SetAccessControl(RegistrySecurity registrySecurity) { EnsureWriteable(); if (registrySecurity == null) { throw new ArgumentNullException(nameof(registrySecurity)); } registrySecurity.Persist(Handle, Name); }