Class NfsAccessRule
java.lang.Object
com.azure.resourcemanager.storagecache.models.NfsAccessRule
Rule to place restrictions on portions of the cache namespace being presented to clients.
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionaccess()
Get the access property: Access allowed by this rule.Get the anonymousGid property: GID value that replaces 0 when rootSquash is true.Get the anonymousUid property: UID value that replaces 0 when rootSquash is true.filter()
Get the filter property: Filter applied to the scope for this rule.Get the rootSquash property: Map root accesses to anonymousUID and anonymousGID.scope()
Get the scope property: Scope for this rule.Get the submountAccess property: For the default policy, allow access to subdirectories under the root export.suid()
Get the suid property: Allow SUID semantics.void
validate()
Validates the instance.withAccess
(NfsAccessRuleAccess access) Set the access property: Access allowed by this rule.withAnonymousGid
(String anonymousGid) Set the anonymousGid property: GID value that replaces 0 when rootSquash is true.withAnonymousUid
(String anonymousUid) Set the anonymousUid property: UID value that replaces 0 when rootSquash is true.withFilter
(String filter) Set the filter property: Filter applied to the scope for this rule.withRootSquash
(Boolean rootSquash) Set the rootSquash property: Map root accesses to anonymousUID and anonymousGID.withScope
(NfsAccessRuleScope scope) Set the scope property: Scope for this rule.withSubmountAccess
(Boolean submountAccess) Set the submountAccess property: For the default policy, allow access to subdirectories under the root export.Set the suid property: Allow SUID semantics.
-
Constructor Details
-
NfsAccessRule
public NfsAccessRule()
-
-
Method Details
-
scope
Get the scope property: Scope for this rule. The scope and filter determine which clients match the rule.- Returns:
- the scope value.
-
withScope
Set the scope property: Scope for this rule. The scope and filter determine which clients match the rule.- Parameters:
scope
- the scope value to set.- Returns:
- the NfsAccessRule object itself.
-
filter
Get the filter property: Filter applied to the scope for this rule. The filter's format depends on its scope. 'default' scope matches all clients and has no filter value. 'network' scope takes a filter in CIDR format (for example, 10.99.1.0/24). 'host' takes an IP address or fully qualified domain name as filter. If a client does not match any filter rule and there is no default rule, access is denied.- Returns:
- the filter value.
-
withFilter
Set the filter property: Filter applied to the scope for this rule. The filter's format depends on its scope. 'default' scope matches all clients and has no filter value. 'network' scope takes a filter in CIDR format (for example, 10.99.1.0/24). 'host' takes an IP address or fully qualified domain name as filter. If a client does not match any filter rule and there is no default rule, access is denied.- Parameters:
filter
- the filter value to set.- Returns:
- the NfsAccessRule object itself.
-
access
Get the access property: Access allowed by this rule.- Returns:
- the access value.
-
withAccess
Set the access property: Access allowed by this rule.- Parameters:
access
- the access value to set.- Returns:
- the NfsAccessRule object itself.
-
suid
Get the suid property: Allow SUID semantics.- Returns:
- the suid value.
-
withSuid
Set the suid property: Allow SUID semantics.- Parameters:
suid
- the suid value to set.- Returns:
- the NfsAccessRule object itself.
-
submountAccess
Get the submountAccess property: For the default policy, allow access to subdirectories under the root export. If this is set to no, clients can only mount the path '/'. If set to yes, clients can mount a deeper path, like '/a/b'.- Returns:
- the submountAccess value.
-
withSubmountAccess
Set the submountAccess property: For the default policy, allow access to subdirectories under the root export. If this is set to no, clients can only mount the path '/'. If set to yes, clients can mount a deeper path, like '/a/b'.- Parameters:
submountAccess
- the submountAccess value to set.- Returns:
- the NfsAccessRule object itself.
-
rootSquash
Get the rootSquash property: Map root accesses to anonymousUID and anonymousGID.- Returns:
- the rootSquash value.
-
withRootSquash
Set the rootSquash property: Map root accesses to anonymousUID and anonymousGID.- Parameters:
rootSquash
- the rootSquash value to set.- Returns:
- the NfsAccessRule object itself.
-
anonymousUid
Get the anonymousUid property: UID value that replaces 0 when rootSquash is true. 65534 will be used if not provided.- Returns:
- the anonymousUid value.
-
withAnonymousUid
Set the anonymousUid property: UID value that replaces 0 when rootSquash is true. 65534 will be used if not provided.- Parameters:
anonymousUid
- the anonymousUid value to set.- Returns:
- the NfsAccessRule object itself.
-
anonymousGid
Get the anonymousGid property: GID value that replaces 0 when rootSquash is true. This will use the value of anonymousUID if not provided.- Returns:
- the anonymousGid value.
-
withAnonymousGid
Set the anonymousGid property: GID value that replaces 0 when rootSquash is true. This will use the value of anonymousUID if not provided.- Parameters:
anonymousGid
- the anonymousGid value to set.- Returns:
- the NfsAccessRule object itself.
-
validate
public void validate()Validates the instance.- Throws:
IllegalArgumentException
- thrown if the instance is not valid.
-