org.universAAL.support.utils.service
Class Typematch

Package class diagram package Typematch
java.lang.Object
  extended by org.universAAL.support.utils.service.Value
      extended by org.universAAL.support.utils.service.Typematch

public class Typematch
extends Value

Class representing a Type-match argument in a service request. Arguments are the "leaf" objects at the end of a property path and can be of several types depending on what you want to do with them. An Type-match argument means that values in the property path must be of the type represented by this argument.

Author:
alfiva

Field Summary
 
Fields inherited from class org.universAAL.support.utils.service.Value
isByURI, uri
 
Constructor Summary
Typematch(Object byValue)
          Deprecated. 
Typematch(String byTypeURI)
          Recommended for use by SimpleRequests and SimpleProfiles.
 
Method Summary
 String getURI()
          This is only supposed to be used internally.
 
Methods inherited from class org.universAAL.support.utils.service.Value
byURI, createEmptyInstance
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Typematch

public Typematch(String byTypeURI)
Recommended for use by SimpleRequests and SimpleProfiles. Value used to define types to match as arguments of a Request.

Parameters:
byTypeURI - The URI of the type that you want to match (you can get it with NameOfClass.MY_URI)

Typematch

@Deprecated
public Typematch(Object byValue)
Deprecated. 

Value used to define types to match as arguments of a Request.

DEPRECATED: The use of this constructor is discouraged as it behaves differently to other constructors of SimpleValues that take instance values. This one uses the passed value to extract its type, not to specify it as explicit instance.

This is a helper constructor that takes an instance of the type you want and extracts its type. The value of the instance is irrelevant, it's just intended for situations in which you already have an instance which type you want to match.

Parameters:
byValue - An instance of which type you want to match.
Method Detail

getURI

public String getURI()
This is only supposed to be used internally.

Returns:
The type URI to match


Copyright © 2014 universAAL Consortium. All Rights Reserved.