Class LinkType
- java.lang.Object
-
- org.eclipse.lyo.oslc4j.core.model.AbstractResource
-
- com.sodius.oslc.server.process.model.LinkType
-
- All Implemented Interfaces:
IExtendedResource
,IResource
@OslcNamespace("http://www.sodius.com/ns/process#") @OslcResourceShape(title="Link Type Resource Shape", describes="http://www.sodius.com/ns/process#LinkType") public class LinkType extends AbstractResource
Describes a type of link between 2 OSLC resources.Link types are grouped by
AssociationType
.Here are some resources listing existing OSLC link types:
- Jazz wiki (association types): https://jazz.net/wiki/bin/view/Main/CALM2010LinkTypes
- Jazz wiki (CLM): https://jazz.net/wiki/bin/view/Deployment/IntegratingWithConfigurationManagementEnabledCLMApplications
- Jazz RM help page: https://jazz.net/help-dev/clm/index.jsp?re=1&topic=/com.ibm.rational.rrm.help.doc/topics/r_rm_link_domains.html
The set of supported link types can be restricted to a subset using a
ProcessScope
instance, that all methods returning link types in this class will use.- Since:
- 1.3.0
- See Also:
ProcessScope
-
-
Constructor Summary
Constructors Constructor Description LinkType()
LinkType(LinkType linkType, HttpServletRequest request)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static Collection<LinkType>
forAssociationType(String associationTypeId, HttpServletRequest request)
Returns the supported link types for the given association type.static Collection<LinkType>
forPropertyDefinition(URI propertyDefinition, HttpServletRequest request)
Returns the supported link types for the given property definition.static Collection<LinkType>
forSourceRange(URI sourceRange, HttpServletRequest request)
Returns the supported link types for the given source range.URI
getBacklinkPropertyDefinition()
String
getLinkDirection()
static Collection<LinkType>
getLinkTypes(HttpServletRequest request)
Returns all supported link types.URI
getPropertyDefinition()
URI
getSourceRange()
URI
getTargetRange()
String
getTitle()
boolean
isUserSelectable()
Determines whether the end-user must be offered to create a link of such type.void
setBacklinkPropertyDefinition(URI backlinkPropertyDefinition)
void
setLinkDirection(String linkDirection)
void
setPropertyDefinition(URI propertyDefinition)
void
setSourceRange(URI sourceRange)
void
setTargetRange(URI targetRange)
void
setTitle(String title)
-
Methods inherited from class org.eclipse.lyo.oslc4j.core.model.AbstractResource
addType, getAbout, getExtendedProperties, getTypes, setAbout, setExtendedProperties, setTypes
-
-
-
-
Constructor Detail
-
LinkType
public LinkType()
-
LinkType
public LinkType(LinkType linkType, HttpServletRequest request)
-
-
Method Detail
-
getLinkTypes
public static Collection<LinkType> getLinkTypes(HttpServletRequest request)
Returns all supported link types.- Parameters:
request
- the http request- Returns:
- all supported link types.
- Since:
- 1.5.0
-
forAssociationType
public static Collection<LinkType> forAssociationType(String associationTypeId, HttpServletRequest request)
Returns the supported link types for the given association type.- Parameters:
associationTypeId
- the association type identifierrequest
- the http request- Returns:
- the corresponding link types
-
forSourceRange
public static Collection<LinkType> forSourceRange(URI sourceRange, HttpServletRequest request)
Returns the supported link types for the given source range.- Parameters:
sourceRange
- the source range (e.g:OslcCm.TYPE_CHANGE_REQUEST
,OslcAm.TYPE_AMRESOURCE
,OslcRm.TYPE_REQUIREMENT
...)request
- the http request- Returns:
- the supported link types
-
forPropertyDefinition
public static Collection<LinkType> forPropertyDefinition(URI propertyDefinition, HttpServletRequest request)
Returns the supported link types for the given property definition.- Parameters:
propertyDefinition
- the link type property definitionrequest
- the http request- Returns:
- the corresponding link types
-
getPropertyDefinition
@OslcPropertyDefinition("http://open-services.net/ns/core#propertyDefinition") public URI getPropertyDefinition()
-
setPropertyDefinition
public void setPropertyDefinition(URI propertyDefinition)
-
getTitle
@OslcPropertyDefinition("http://purl.org/dc/terms/title") public String getTitle()
-
setTitle
public void setTitle(String title)
-
getBacklinkPropertyDefinition
@OslcPropertyDefinition("http://www.sodius.com/ns/process#backlinkPropertyDefinition") public URI getBacklinkPropertyDefinition()
-
setBacklinkPropertyDefinition
public void setBacklinkPropertyDefinition(URI backlinkPropertyDefinition)
-
getSourceRange
@OslcPropertyDefinition("http://www.sodius.com/ns/process#sourceRange") public URI getSourceRange()
-
setSourceRange
public void setSourceRange(URI sourceRange)
-
getTargetRange
@OslcPropertyDefinition("http://www.sodius.com/ns/process#targetRange") public URI getTargetRange()
-
setTargetRange
public void setTargetRange(URI targetRange)
-
getLinkDirection
@OslcPropertyDefinition("http://www.sodius.com/ns/process#linkDirection") public String getLinkDirection()
-
setLinkDirection
public void setLinkDirection(String linkDirection)
-
isUserSelectable
public boolean isUserSelectable()
Determines whether the end-user must be offered to create a link of such type. Most of the link types can be initiated by the end-user on his local resource, but some can only be created from the opposite bound, typically thetracksChangeSet
one.- Returns:
true
if the end-user can create such link on his local resource,false
otherwise.- Since:
- 3.3.1
-
-