Class WindowsPeSection
java.lang.Object
security.whisper.javastix.coo.types.WindowsPeSection
- All Implemented Interfaces:
Serializable,StixCustomProperties,WindowsPeSectionObj,GenericValidation,SdoDefaultValidator
@ParametersAreNonnullByDefault
@Generated("org.immutables.processor.ProxyProcessor")
@Immutable
@CheckReturnValue
public final class WindowsPeSection
extends Object
implements WindowsPeSectionObj
The PE Section type specifies metadata about a PE file section.
- See Also:
-
Nested Class Summary
Nested Classes -
Field Summary
Fields inherited from interface security.whisper.javastix.validation.SdoDefaultValidator
VALIDATOR -
Method Summary
Modifier and TypeMethodDescriptionstatic WindowsPeSection.Builderbuilder()Creates a builder forWindowsPeSection.static WindowsPeSectioncopyOf(WindowsPeSectionObj instance) Creates an immutable copy of aWindowsPeSectionObjvalue.booleanThis instance is equal to all instances ofWindowsPeSectionthat have equal attribute values.Custom Properties for STIX Objects.getName()getSize()inthashCode()Computes a hash code from attributes:name,size,entropy,hashes,customProperties.toString()Prints the immutable valueWindowsPeSectionwith attribute values.final WindowsPeSectionwithCustomProperties(Map<String, ? extends Object> entries) Copy the current immutable object by replacing thecustomPropertiesmap with the specified map.final WindowsPeSectionwithEntropy(float value) Copy the current immutable object by setting a present value for the optionalentropyattribute.final WindowsPeSectionwithEntropy(Optional<Float> optional) Copy the current immutable object by setting an optional value for theentropyattribute.final WindowsPeSectionwithHashes(Map<String, ? extends String> entries) Copy the current immutable object by replacing thehashesmap with the specified map.final WindowsPeSectionCopy the current immutable object by setting a present value for the optionalnameattribute.final WindowsPeSectionCopy the current immutable object by setting an optional value for thenameattribute.final WindowsPeSectionwithSize(long value) Copy the current immutable object by setting a present value for the optionalsizeattribute.final WindowsPeSectionCopy the current immutable object by setting an optional value for thesizeattribute.Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface security.whisper.javastix.validation.GenericValidation
validateEntityMethods inherited from interface security.whisper.javastix.validation.SdoDefaultValidator
validate, validateOnlyId
-
Method Details
-
getName
- Specified by:
getNamein interfaceWindowsPeSectionObj- Returns:
- The value of the
nameattribute
-
getSize
@JsonPropertyDescription("Specifies the size of the section, in bytes.") public Optional<Long> getSize()- Specified by:
getSizein interfaceWindowsPeSectionObj- Returns:
- The value of the
sizeattribute
-
getEntropy
@JsonPropertyDescription("Specifies the calculated entropy for the section, as calculated using the Shannon algorithm.") public Optional<Float> getEntropy()- Specified by:
getEntropyin interfaceWindowsPeSectionObj- Returns:
- The value of the
entropyattribute
-
getHashes
@JsonPropertyDescription("Specifies any hashes computed over the section.") public com.google.common.collect.ImmutableMap<String,String> getHashes()- Specified by:
getHashesin interfaceWindowsPeSectionObj- Returns:
- The value of the
hashesattribute
-
getCustomProperties
Custom Properties for STIX Objects. Any object that supports custom properties will have a validation of the custom property prefix (typically "x_"). If the additional property in the JSON does not meet the StartsWith condition, then the JSON will be rejected.- Specified by:
getCustomPropertiesin interfaceStixCustomProperties- Returns:
- Map of custom properties
Map<String, Object>
-
withName
Copy the current immutable object by setting a present value for the optionalnameattribute.- Parameters:
value- The value for name- Returns:
- A modified copy of
thisobject
-
withName
Copy the current immutable object by setting an optional value for thenameattribute. An equality check is used on inner nullable value to prevent copying of the same value by returningthis.- Parameters:
optional- A value for name- Returns:
- A modified copy of
thisobject
-
withSize
Copy the current immutable object by setting a present value for the optionalsizeattribute.- Parameters:
value- The value for size- Returns:
- A modified copy of
thisobject
-
withSize
Copy the current immutable object by setting an optional value for thesizeattribute. An equality check is used on inner nullable value to prevent copying of the same value by returningthis.- Parameters:
optional- A value for size- Returns:
- A modified copy of
thisobject
-
withEntropy
Copy the current immutable object by setting a present value for the optionalentropyattribute.- Parameters:
value- The value for entropy- Returns:
- A modified copy of
thisobject
-
withEntropy
Copy the current immutable object by setting an optional value for theentropyattribute. An equality check is used on inner nullable value to prevent copying of the same value by returningthis.- Parameters:
optional- A value for entropy- Returns:
- A modified copy of
thisobject
-
withHashes
Copy the current immutable object by replacing thehashesmap with the specified map. Nulls are not permitted as keys or values. A shallow reference equality check is used to prevent copying of the same value by returningthis.- Parameters:
entries- The entries to be added to the hashes map- Returns:
- A modified copy of
thisobject
-
withCustomProperties
Copy the current immutable object by replacing thecustomPropertiesmap with the specified map. Nulls are not permitted as keys or values. A shallow reference equality check is used to prevent copying of the same value by returningthis.- Parameters:
entries- The entries to be added to the customProperties map- Returns:
- A modified copy of
thisobject
-
equals
This instance is equal to all instances ofWindowsPeSectionthat have equal attribute values. -
hashCode
public int hashCode()Computes a hash code from attributes:name,size,entropy,hashes,customProperties. -
toString
Prints the immutable valueWindowsPeSectionwith attribute values. -
copyOf
Creates an immutable copy of aWindowsPeSectionObjvalue. Uses accessors to get values to initialize the new immutable instance. If an instance is already immutable, it is returned as is.- Parameters:
instance- The instance to copy- Returns:
- A copied immutable WindowsPeSection instance
-
builder
Creates a builder forWindowsPeSection.- Returns:
- A new WindowsPeSection builder
-