Package cz.metacentrum.perun.core.api
Class Destination
java.lang.Object
cz.metacentrum.perun.core.api.PerunBean
cz.metacentrum.perun.core.api.Auditable
cz.metacentrum.perun.core.api.Destination
- All Implemented Interfaces:
Serializable
,Comparable<PerunBean>
- Direct Known Subclasses:
RichDestination
Destination where services are propagated.
- Author:
- Slavek Licehammer
- See Also:
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final String
static final String
static final String
static final String
static final String
static final String
static final String
static final String
static final String
static final String
static final String
static final String
static final String
static final String
-
Constructor Summary
ConstructorsConstructorDescriptionDestination
(int id, String destination) Destination
(int id, String destination, String type) Destination
(int id, String destination, String type, String propagationType) Destination
(int id, String destination, String type, String createdAt, String createdBy, String modifiedAt, String modifiedBy, Integer createdByUid, Integer modifiedByUid) -
Method Summary
Modifier and TypeMethodDescriptionint
boolean
Gets the destination for this instance.Gets the hostname from destination e.g. if destination is type user@host then return host e.g. if destination is type user@host:port then return host e.g. if destination is type user@host-windows then return host-windows if destination is other type then these three, return destination without changesGets the propagation type for this instance.getType()
Gets the type for this instance.int
hashCode()
void
setDestination
(String destination) Sets the destination for this instance.void
setPropagationType
(String type) Sets the propagation type for this instance.void
Sets the type for this instance.toString()
Methods inherited from class cz.metacentrum.perun.core.api.Auditable
getCreatedAt, getCreatedBy, getCreatedByUid, getModifiedAt, getModifiedBy, getModifiedByUid, setCreatedAt, setCreatedBy, setCreatedByUid, setModifiedAt, setModifiedBy, setModifiedByUid
Methods inherited from class cz.metacentrum.perun.core.api.PerunBean
getBeanName, getId, setId
-
Field Details
-
DESTINATIONHOSTTYPE
- See Also:
-
DESTINATIONEMAILTYPE
- See Also:
-
DESTINATIONSEMAILTYPE
- See Also:
-
DESTINATIONURLTYPE
- See Also:
-
DESTINATIONUSERHOSTTYPE
- See Also:
-
DESTINATIONUSERHOSTPORTTYPE
- See Also:
-
DESTINATIONSERVICESPECIFICTYPE
- See Also:
-
DESTINATIONWINDOWS
- See Also:
-
DESTINATIONWINDOWSPROXY
- See Also:
-
DESTINATIONS3TYPE
- See Also:
-
DESTINATIONURLJSON
- See Also:
-
PROPAGATIONTYPE_PARALLEL
- See Also:
-
PROPAGATIONTYPE_SERIAL
- See Also:
-
PROPAGATIONTYPE_DUMMY
- See Also:
-
-
Constructor Details
-
Destination
public Destination() -
Destination
-
Destination
-
Destination
-
Destination
-
-
Method Details
-
compareTo
- Specified by:
compareTo
in interfaceComparable<PerunBean>
- Overrides:
compareTo
in classPerunBean
-
equals
-
getDestination
Gets the destination for this instance.- Returns:
- The name.
-
setDestination
Sets the destination for this instance.- Parameters:
destination
- The destination.
-
getHostNameFromDestination
Gets the hostname from destination e.g. if destination is type user@host then return host e.g. if destination is type user@host:port then return host e.g. if destination is type user@host-windows then return host-windows if destination is other type then these three, return destination without changesif there is no chars @ and :, return not changed type if type is null, return this destination without changes if destination null, return destination without changes (null)
- Returns:
- host from destination if possible to separate, in other case return destination without changes
-
getPropagationType
Gets the propagation type for this instance.- Returns:
- The propagation type, either "PARALLEL", "SERIAL" or "DUMMY"
-
setPropagationType
Sets the propagation type for this instance.- Parameters:
type
- The propagation type.
-
getType
Gets the type for this instance.- Returns:
- The type.
-
setType
Sets the type for this instance.- Parameters:
type
- The type.
-
hashCode
public int hashCode() -
serializeToString
- Overrides:
serializeToString
in classAuditable
-
toString
-