Class NtfsAlternateDataStream.Builder
java.lang.Object
security.whisper.javastix.coo.types.NtfsAlternateDataStream.Builder
- Enclosing class:
NtfsAlternateDataStream
Builds instances of type
NtfsAlternateDataStream.
Initialize attributes and then invoke the build() method to create an
immutable instance.
Builder is not thread-safe and generally should not be stored in a field or collection,
but instead used immediately to create instances.
-
Method Summary
Modifier and TypeMethodDescriptionbuild()Builds a newNtfsAlternateDataStream.customProperties(Map<String, ? extends Object> entries) Sets or replaces all mappings from the specified map as entries for thecustomPropertiesmap.from(StixCustomProperties instance) Fill a builder with attribute values from the providedsecurity.whisper.javastix.common.StixCustomPropertiesinstance.from(NtfsAlternateDataStreamObj instance) Fill a builder with attribute values from the providedsecurity.whisper.javastix.coo.types.NtfsAlternateDataStreamObjinstance.Sets or replaces all mappings from the specified map as entries for thehashesmap.Initializes the value for thenameattribute.putAllCustomProperties(Map<String, ? extends Object> entries) Put all mappings from the specified map as entries tocustomPropertiesmap.putAllHashes(Map<String, ? extends String> entries) Put all mappings from the specified map as entries tohashesmap.putCustomProperty(String key, Object value) Put one entry to thecustomPropertiesmap.putCustomProperty(Map.Entry<String, ? extends Object> entry) Put one entry to thecustomPropertiesmap.Put one entry to thehashesmap.Put one entry to thehashesmap.size(long size) Initializes the optional valuesizeto size.Initializes the optional valuesizeto size.
-
Method Details
-
from
@CanIgnoreReturnValue public final NtfsAlternateDataStream.Builder from(StixCustomProperties instance) Fill a builder with attribute values from the providedsecurity.whisper.javastix.common.StixCustomPropertiesinstance.- Parameters:
instance- The instance from which to copy values- Returns:
thisbuilder for use in a chained invocation
-
from
@CanIgnoreReturnValue public final NtfsAlternateDataStream.Builder from(NtfsAlternateDataStreamObj instance) Fill a builder with attribute values from the providedsecurity.whisper.javastix.coo.types.NtfsAlternateDataStreamObjinstance.- Parameters:
instance- The instance from which to copy values- Returns:
thisbuilder for use in a chained invocation
-
name
@CanIgnoreReturnValue @JsonPropertyDescription("Specifies the name of the alternate data stream.") public final NtfsAlternateDataStream.Builder name(String name) Initializes the value for thenameattribute.- Parameters:
name- The value for name (can benull)- Returns:
thisbuilder for use in a chained invocation
-
putHash
@CanIgnoreReturnValue public final NtfsAlternateDataStream.Builder putHash(String key, String value) Put one entry to thehashesmap.- Parameters:
key- The key in the hashes mapvalue- The associated value in the hashes map- Returns:
thisbuilder for use in a chained invocation
-
putHash
@CanIgnoreReturnValue public final NtfsAlternateDataStream.Builder putHash(Map.Entry<String, ? extends String> entry) Put one entry to thehashesmap. Nulls are not permitted- Parameters:
entry- The key and value entry- Returns:
thisbuilder for use in a chained invocation
-
hashes
@CanIgnoreReturnValue @JsonPropertyDescription("Specifies a dictionary of hashes for the data contained in the alternate data stream.") public final NtfsAlternateDataStream.Builder hashes(Map<String, ? extends String> entries) Sets or replaces all mappings from the specified map as entries for thehashesmap. Nulls are not permitted- Parameters:
entries- The entries that will be added to the hashes map- Returns:
thisbuilder for use in a chained invocation
-
putAllHashes
@CanIgnoreReturnValue public final NtfsAlternateDataStream.Builder putAllHashes(Map<String, ? extends String> entries) Put all mappings from the specified map as entries tohashesmap. Nulls are not permitted- Parameters:
entries- The entries that will be added to the hashes map- Returns:
thisbuilder for use in a chained invocation
-
size
Initializes the optional valuesizeto size.- Parameters:
size- The value for size- Returns:
thisbuilder for chained invocation
-
size
@CanIgnoreReturnValue @JsonPropertyDescription("Specifies the size of the alternate data stream, in bytes, as a non-negative integer.") public final NtfsAlternateDataStream.Builder size(Optional<Long> size) Initializes the optional valuesizeto size.- Parameters:
size- The value for size- Returns:
thisbuilder for use in a chained invocation
-
putCustomProperty
@CanIgnoreReturnValue public final NtfsAlternateDataStream.Builder putCustomProperty(String key, Object value) Put one entry to thecustomPropertiesmap.- Parameters:
key- The key in the customProperties mapvalue- The associated value in the customProperties map- Returns:
thisbuilder for use in a chained invocation
-
putCustomProperty
@CanIgnoreReturnValue public final NtfsAlternateDataStream.Builder putCustomProperty(Map.Entry<String, ? extends Object> entry) Put one entry to thecustomPropertiesmap. Nulls are not permitted- Parameters:
entry- The key and value entry- Returns:
thisbuilder for use in a chained invocation
-
customProperties
@CanIgnoreReturnValue public final NtfsAlternateDataStream.Builder customProperties(Map<String, ? extends Object> entries) Sets or replaces all mappings from the specified map as entries for thecustomPropertiesmap. Nulls are not permitted- Parameters:
entries- The entries that will be added to the customProperties map- Returns:
thisbuilder for use in a chained invocation
-
putAllCustomProperties
@CanIgnoreReturnValue public final NtfsAlternateDataStream.Builder putAllCustomProperties(Map<String, ? extends Object> entries) Put all mappings from the specified map as entries tocustomPropertiesmap. Nulls are not permitted- Parameters:
entries- The entries that will be added to the customProperties map- Returns:
thisbuilder for use in a chained invocation
-
build
Builds a newNtfsAlternateDataStream.- Returns:
- An immutable instance of NtfsAlternateDataStream
- Throws:
IllegalStateException- if any required attributes are missing
-