Record Class PluginConflict
java.lang.Object
java.lang.Record
org.spongepowered.plugin.metadata.model.PluginConflict
- Record Components:
id- Theidversion- Theversion, as a maven range.fatal- Whether this conflict should prevent loadingreason- Thereason
public record PluginConflict(String id, VersionRange version, boolean fatal, Optional<String> reason)
extends Record
Specification for an entity considered to be conflicting with a
plugin metadata.
The vendor will either log a warning or refuse to load when this entity is present.
- See Also:
-
Constructor Summary
ConstructorsConstructorDescriptionPluginConflict(String id, VersionRange version, boolean fatal, @Nullable String reason) PluginConflict(String id, VersionRange version, boolean fatal, Optional<String> reason) Creates an instance of aPluginConflictrecord class. -
Method Summary
Modifier and TypeMethodDescriptionfinal booleanIndicates whether some other object is "equal to" this one.booleanfatal()Returns the value of thefatalrecord component.final inthashCode()Returns a hash code value for this object.id()Returns the value of theidrecord component.reason()Returns the value of thereasonrecord component.final StringtoString()Returns a string representation of this record class.version()Returns the value of theversionrecord component.
-
Constructor Details
-
Method Details
-
toString
Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components. -
hashCode
public final int hashCode()Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. Reference components are compared withObjects::equals(Object,Object); primitive components are compared with '=='. -
id
Returns the value of theidrecord component.- Returns:
- the value of the
idrecord component
-
version
Returns the value of theversionrecord component.- Returns:
- the value of the
versionrecord component
-
fatal
public boolean fatal()Returns the value of thefatalrecord component.- Returns:
- the value of the
fatalrecord component
-
reason
Returns the value of thereasonrecord component.- Returns:
- the value of the
reasonrecord component
-