Class InterfaceMatchMaker
- java.lang.Object
-
- fi.tut.mei.matchmaking.process.interfacemm.InterfaceMatchMaker
-
- All Implemented Interfaces:
IClearResults
,IInterfaceMatchMaker
public class InterfaceMatchMaker extends Object implements IInterfaceMatchMaker, IClearResults
Performs the Interface Matchmaking process.- Author:
- Niko Siltala
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description class
InterfaceMatchMaker.InputResources
Class storing the input resource list as structure of RDs and RIDs-
Nested classes/interfaces inherited from interface fi.tut.mei.matchmaking.process.interfacemm.IInterfaceMatchMaker
IInterfaceMatchMaker.eMatchingLevel
-
-
Field Summary
Fields Modifier and Type Field Description protected static String
JAR_IFMM_QUERY_TEMPLATES_LOCATION
Location of the Interface Matchmaking queries inside the compiled jarprotected static String
MAIN_RESOURCES_LOCATION
protected static String
NOT_EXISTING_IF_STD_CODE
protected static String
NOT_EXISTING_IF_STD_CODE_IMPLEMENTATION
protected static String
NOT_EXISTING_IF_STD_CODE_NAMESPACE
protected static String
QUERY_TEMPLATE_LOCATION
-
Constructor Summary
Constructors Constructor Description InterfaceMatchMaker(fi.tut.mei.capabilityQueryLib.Client ontoclient)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
areConnectable_Gid(List<String> resources)
Test are given resources connectable with each othervoid
clearAllResults()
Clear All results related markers and connections assigned for this instancevoid
clearConnections()
Clear all connections found for this instancevoid
clearMarkers()
Clears markers used for resultsString
getDefaultNamespaceURI()
IInterfaceMatchMaker.eMatchingLevel
getMatchingLevel()
List<String>
hasNoInterfaces(List<String> resources)
Test if resource(s) has no interface definitions.protected String
loadSparqlTemplate(String name)
IfMatchResult
makeInterfaceMatch_Gid(List<String> resources)
Test are given resources connectable with each othervoid
setDefaultNamespaceURI(String defaultNamespaceURI)
void
setMatchingLevel(IInterfaceMatchMaker.eMatchingLevel level)
Sets target interface matching level
-
-
-
Field Detail
-
JAR_IFMM_QUERY_TEMPLATES_LOCATION
protected static final String JAR_IFMM_QUERY_TEMPLATES_LOCATION
Location of the Interface Matchmaking queries inside the compiled jar- See Also:
- Constant Field Values
-
MAIN_RESOURCES_LOCATION
protected static final String MAIN_RESOURCES_LOCATION
- See Also:
- Constant Field Values
-
QUERY_TEMPLATE_LOCATION
protected static final String QUERY_TEMPLATE_LOCATION
- See Also:
- Constant Field Values
-
NOT_EXISTING_IF_STD_CODE
protected static final String NOT_EXISTING_IF_STD_CODE
- See Also:
- Constant Field Values
-
NOT_EXISTING_IF_STD_CODE_NAMESPACE
protected static final String NOT_EXISTING_IF_STD_CODE_NAMESPACE
- See Also:
- Constant Field Values
-
NOT_EXISTING_IF_STD_CODE_IMPLEMENTATION
protected static final String NOT_EXISTING_IF_STD_CODE_IMPLEMENTATION
- See Also:
- Constant Field Values
-
-
Method Detail
-
areConnectable_Gid
public boolean areConnectable_Gid(List<String> resources) throws GeneralIfMMException, ResourceNotFoundException
Description copied from interface:IInterfaceMatchMaker
Test are given resources connectable with each other- Specified by:
areConnectable_Gid
in interfaceIInterfaceMatchMaker
- Parameters:
resources
- List of tested resources. Full URI with namespace is expected.- Returns:
- true if all resources on the list are connectable with each other, and no resource is left unconnected.
- Throws:
GeneralIfMMException
ResourceNotFoundException
-
makeInterfaceMatch_Gid
public IfMatchResult makeInterfaceMatch_Gid(List<String> resources) throws GeneralIfMMException, ResourceNotFoundException
Description copied from interface:IInterfaceMatchMaker
Test are given resources connectable with each other- Specified by:
makeInterfaceMatch_Gid
in interfaceIInterfaceMatchMaker
- Parameters:
resources
- List of tested resources. Full URI with namespace is expected.- Returns:
- interface matchmaking result
- Throws:
GeneralIfMMException
ResourceNotFoundException
-
hasNoInterfaces
public List<String> hasNoInterfaces(List<String> resources)
Description copied from interface:IInterfaceMatchMaker
Test if resource(s) has no interface definitions.- Specified by:
hasNoInterfaces
in interfaceIInterfaceMatchMaker
- Parameters:
resources
- List of tested resources- Returns:
- List of resources, which have not interface definitions made, and thus cannot be connected with any other resource.
-
getMatchingLevel
public IInterfaceMatchMaker.eMatchingLevel getMatchingLevel()
- Returns:
- the matchingLevel
-
setMatchingLevel
public void setMatchingLevel(IInterfaceMatchMaker.eMatchingLevel level)
Description copied from interface:IInterfaceMatchMaker
Sets target interface matching level- Specified by:
setMatchingLevel
in interfaceIInterfaceMatchMaker
- Parameters:
level
- until which detail interface matchmaking is performed
-
clearAllResults
public void clearAllResults()
Description copied from interface:IClearResults
Clear All results related markers and connections assigned for this instance- Specified by:
clearAllResults
in interfaceIClearResults
-
clearMarkers
public void clearMarkers()
Description copied from interface:IClearResults
Clears markers used for results- Specified by:
clearMarkers
in interfaceIClearResults
-
clearConnections
public void clearConnections()
Description copied from interface:IClearResults
Clear all connections found for this instance- Specified by:
clearConnections
in interfaceIClearResults
-
getDefaultNamespaceURI
public String getDefaultNamespaceURI()
- Returns:
- the defaultNamespaceURI
-
setDefaultNamespaceURI
public void setDefaultNamespaceURI(String defaultNamespaceURI)
- Parameters:
defaultNamespaceURI
- the defaultNamespaceURI to set
-
loadSparqlTemplate
protected String loadSparqlTemplate(String name) throws IOException
- Throws:
IOException
-
-