|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.microsoft.tfs.core.clients.registration.RegistrationClient
public class RegistrationClient
A client for accessing the registration data available from a Team Foundation server.
This client provides several services on top of the Registration web service:
A RegistrationClient should normally be obtained from a
TFSTeamProjectCollection instead of being manually constructed.
Note: RegistrationClient is unlike other clients. TFSConnection calls into this client, and this calls back. Thus you need to be very careful of locking between TFSConnection and this.
| Constructor Summary | |
|---|---|
RegistrationClient(TFSTeamProjectCollection connection)
Creates a new RegistrationClient with a default refresh interval
and disk caching enabled. |
|
RegistrationClient(TFSTeamProjectCollection connection,
long refreshIntervalMillis,
boolean enableDiskCache)
Creates a new RegistrationClient, specifying the refresh interval
and disk caching policy. |
|
| Method Summary | |
|---|---|
ArtifactType |
getArtifactType(java.lang.String toolId,
java.lang.String artifactTypeName)
Gets the specified ArtifactType for the specified tool. |
ArtifactType |
getArtifactType(java.lang.String toolId,
java.lang.String artifactTypeName,
boolean forceRefresh)
Gets the specified ArtifactType for the specified tool,
specifying whether to force a refresh of the registration data from the
TF server. |
ArtifactType[] |
getArtifactTypes(java.lang.String toolId)
Gets all of the ArtifactTypes for the specified tool. |
ArtifactType[] |
getArtifactTypes(java.lang.String toolId,
boolean forceRefresh)
Gets all of the ArtifactTypes for the specified tool, specifying
whether to force a refresh of the registration data from the TF server. |
RegistrationExtendedAttribute |
getExtendedAttribute(java.lang.String toolId,
java.lang.String attributeName)
Gets the specified RegistrationExtendedAttribute for the
specified tool. |
RegistrationExtendedAttribute |
getExtendedAttribute(java.lang.String toolId,
java.lang.String attributeName,
boolean forceRefresh)
Gets the specified RegistrationExtendedAttribute for the
specified tool, specifying whether to force a refresh of the registration
data from the TF server. |
RegistrationExtendedAttribute[] |
getExtendedAttributes(java.lang.String toolId)
Gets all of the RegistrationExtendedAttributes for the specified
tool. |
RegistrationExtendedAttribute[] |
getExtendedAttributes(java.lang.String toolId,
boolean forceRefresh)
Gets all of the RegistrationExtendedAttributes for the specified
tool, specifying whether to force a refresh of the registration data from
the TF server. |
java.lang.String |
getExtendedAttributeValue(java.lang.String toolId,
java.lang.String attributeName)
Gets the specified extended attribute value for the specified tool. |
java.lang.String |
getExtendedAttributeValue(java.lang.String toolId,
java.lang.String attributeName,
boolean forceRefresh)
Gets the specified extended attribute value for the specified tool, specifying whether to force a refresh of the registration data from the TF server. |
com.microsoft.tfs.util.GUID |
getInstanceID()
Obtains the instance ID (server GUID) from the registration data. |
com.microsoft.tfs.util.GUID |
getInstanceID(boolean forceRefresh)
Obtains the instance ID (server GUID) from the registration data, specifying whether to force a refresh of the registration data from the TF server. |
OutboundLinkType[] |
getOutboundLinkTypes(java.lang.String toolId,
java.lang.String artifactTypeName)
Gets all of the OutboundLinkTypes for the specified tool and
artifact type. |
OutboundLinkType[] |
getOutboundLinkTypes(java.lang.String toolId,
java.lang.String artifactTypeName,
boolean forceRefresh)
Gets all of the OutboundLinkTypes for the specified tool and
artifact type, specifying whether to force a refresh of the registration
data from the TF server. |
RegistrationEntry[] |
getRegistrationEntries()
Gets all of the RegistrationEntrys. |
RegistrationEntry[] |
getRegistrationEntries(boolean forceRefresh)
Gets all of the RegistrationEntrys, specifying whether to force a
refresh of the registration data from the TF server. |
RegistrationEntry |
getRegistrationEntry(java.lang.String toolId)
Gets the RegistrationEntry for the specified tool. |
RegistrationEntry |
getRegistrationEntry(java.lang.String toolId,
boolean forceRefresh)
Gets the RegistrationEntry for the specified tool, specifying
whether to force a refresh of the registration data from the TF server. |
java.lang.String |
getRosarioURLForTeamProject(java.lang.String interfaceName,
java.lang.String projectName)
|
ServiceInterface |
getServiceInterface(java.lang.String toolId,
java.lang.String serviceInterfaceName)
Gets the specified ServiceInterface for the specified tool. |
ServiceInterface |
getServiceInterface(java.lang.String toolId,
java.lang.String serviceInterfaceName,
boolean forceRefresh)
Gets the specified ServiceInterface for the specified tool,
specifying whether to force a refresh of the registration data from the
TF server. |
ServiceInterface[] |
getServiceInterfaces(java.lang.String toolId)
Gets all of the ServiceInterfaces for the specified tool. |
ServiceInterface[] |
getServiceInterfaces(java.lang.String toolId,
boolean forceRefresh)
Gets all of the ServiceInterfaces for the specified tool,
specifying whether to force a refresh of the registration data from the
TF server. |
java.lang.String |
getServiceInterfaceURL(java.lang.String toolId,
java.lang.String serviceInterfaceName)
Gets the specified service interface URL for the specified tool. |
java.lang.String |
getServiceInterfaceURL(java.lang.String toolId,
java.lang.String serviceInterfaceName,
boolean forceRefresh,
boolean relative)
Gets the specified service interface URL for the specified tool, specifying whether to force a refresh of the registration data from the TF server. |
void |
refresh(boolean force)
Called to ensure that the registration data is up to date, specifying whether to force a refresh of the data from the TF server. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public RegistrationClient(TFSTeamProjectCollection connection)
RegistrationClient with a default refresh interval
and disk caching enabled.
connection - the TFSTeamProjectCollection to use (must not be
null)
public RegistrationClient(TFSTeamProjectCollection connection,
long refreshIntervalMillis,
boolean enableDiskCache)
RegistrationClient, specifying the refresh interval
and disk caching policy.
connection - the TFSTeamProjectCollection to use (must not be
null)refreshIntervalMillis - specifies the amount of time between refreshes of the registration
data from the serverenableDiskCache - true to enable caching of registration data to disk| Method Detail |
|---|
public RegistrationEntry[] getRegistrationEntries()
RegistrationEntrys. The returned array is safe -
no references to the returned RegistrationEntrys are held by this
class.
RegistrationEntrys (never null)public RegistrationEntry[] getRegistrationEntries(boolean forceRefresh)
RegistrationEntrys, specifying whether to force a
refresh of the registration data from the TF server. The returned array
is safe - no references to the returned RegistrationEntrys are
held by this class.
forceRefresh - true to force a call to the server to refresh the
registration data
RegistrationEntrys (never null)public RegistrationEntry getRegistrationEntry(java.lang.String toolId)
RegistrationEntry for the specified tool. The returned
RegistrationEntry is safe - no reference to it is held by this class.
toolId - specifies the tool to get the RegistrationEntry for (case
insensitive) (must not be null)
RegistrationEntry for the specified tool, or
null if the specified tool does not have a
registration entry
public RegistrationEntry getRegistrationEntry(java.lang.String toolId,
boolean forceRefresh)
RegistrationEntry for the specified tool, specifying
whether to force a refresh of the registration data from the TF server.
The returned RegistrationEntry is safe - no reference to it is held by
this class.
toolId - specifies the tool to get the RegistrationEntry for (case
insensitive) (must not be null)forceRefresh - true to force a call to the server to refresh the
registration data
RegistrationEntry for the specified tool, or
null if the specified tool does not have a
registration entrypublic ServiceInterface[] getServiceInterfaces(java.lang.String toolId)
ServiceInterfaces for the specified tool. The
returned array is safe - no references to the ServiceInterfaces
are held by this class.
toolId - specifies the tool to get ServiceInterfaces for (case
insensitive) (must not be null)
ServiceInterfaces for the specified tool, or
null if the specified tool does not have a
registration entry
public ServiceInterface[] getServiceInterfaces(java.lang.String toolId,
boolean forceRefresh)
ServiceInterfaces for the specified tool,
specifying whether to force a refresh of the registration data from the
TF server. The returned array is safe - no references to the
ServiceInterfaces are held by this class.
toolId - specifies the tool to get ServiceInterfaces for (case
insensitive) (must not be null)forceRefresh - true to force a call to the server to refresh the
registration data
ServiceInterfaces for the specified tool, or
null if the specified tool does not have a
registration entry
public ServiceInterface getServiceInterface(java.lang.String toolId,
java.lang.String serviceInterfaceName)
ServiceInterface for the specified tool. The
returned ServiceInterface is safe - no reference to it is held by
this class.
toolId - specifies the tool to get the ServiceInterface for (case
insensitive) (must not be null)serviceInterfaceName - specifies the service interface to get (case insensitive) (must
not be null)
ServiceInterface for the specified tool, or
null if the requested service interface does not
exist
public ServiceInterface getServiceInterface(java.lang.String toolId,
java.lang.String serviceInterfaceName,
boolean forceRefresh)
ServiceInterface for the specified tool,
specifying whether to force a refresh of the registration data from the
TF server. The returned ServiceInterface is safe - no reference
to it is held by this class.
toolId - specifies the tool to get the ServiceInterface for (case
insensitive) (must not be null)serviceInterfaceName - specifies the service interface to get (case insensitive) (must
not be null)forceRefresh - true to force a call to the server to refresh the
registration data
ServiceInterface for the specified tool, or
null if the requested service interface does not
exist
public java.lang.String getServiceInterfaceURL(java.lang.String toolId,
java.lang.String serviceInterfaceName)
toolId - specifies the tool to get the ServiceInterface for (case
insensitive) (must not be null)serviceInterfaceName - specifies the service interface to get (case insensitive) (must
not be null)
null if no such
service interface exists
public java.lang.String getServiceInterfaceURL(java.lang.String toolId,
java.lang.String serviceInterfaceName,
boolean forceRefresh,
boolean relative)
toolId - specifies the tool to get the ServiceInterface for (case
insensitive) (must not be null)serviceInterfaceName - specifies the service interface to get (case insensitive) (must
not be null)forceRefresh - true to force a call to the server to refresh the
registration data
null if no such
service interface existspublic ArtifactType[] getArtifactTypes(java.lang.String toolId)
ArtifactTypes for the specified tool. The
returned array is safe - no references to the ArtifactTypes are
held by this class.
toolId - specifies the tool to get ArtifactTypes for (case
insensitive) (must not be null)
ArtifactTypes for the specified tool, or
null if the specified tool does not have a
registration entry
public ArtifactType[] getArtifactTypes(java.lang.String toolId,
boolean forceRefresh)
ArtifactTypes for the specified tool, specifying
whether to force a refresh of the registration data from the TF server.
The returned array is safe - no references to the ArtifactTypes
are held by this class.
toolId - specifies the tool to get ArtifactTypes for (case
insensitive) (must not be null)forceRefresh - true to force a call to the server to refresh the
registration data
ArtifactTypes for the specified tool, or
null if the specified tool does not have a
registration entry
public ArtifactType getArtifactType(java.lang.String toolId,
java.lang.String artifactTypeName)
ArtifactType for the specified tool. The
returned ArtifactType is safe - no reference to it is held by
this class.
toolId - specifies the tool to get the ArtifactType for (case
insensitive) (must not be null)artifactTypeName - specifies the artifact type to get (case insensitive) (must not be
null)
ArtifactType for the specified tool, or
null if the requested artifact type does not exist
public ArtifactType getArtifactType(java.lang.String toolId,
java.lang.String artifactTypeName,
boolean forceRefresh)
ArtifactType for the specified tool,
specifying whether to force a refresh of the registration data from the
TF server. The returned ArtifactType is safe - no reference to it
is held by this class.
toolId - specifies the tool to get the ArtifactType for (case
insensitive) (must not be null)artifactTypeName - specifies the artifact type to get (case insensitive) (must not be
null)forceRefresh - true to force a call to the server to refresh the
registration data
ArtifactType for the specified tool, or
null if the requested artifact type does not exist
public OutboundLinkType[] getOutboundLinkTypes(java.lang.String toolId,
java.lang.String artifactTypeName)
OutboundLinkTypes for the specified tool and
artifact type. The returned array is safe - no references to the
OutboundLinkTypes are held by this class.
toolId - specifies the tool to get OutboundLinkTypes for (case
insensitive) (must not be null)artifactTypeName - specifies the artifact type to get (case insensitive) (must not be
null)
OutboundLinkTypes for the specified tool and
artifact type, or null if there is no such tool and
artifact type
public OutboundLinkType[] getOutboundLinkTypes(java.lang.String toolId,
java.lang.String artifactTypeName,
boolean forceRefresh)
OutboundLinkTypes for the specified tool and
artifact type, specifying whether to force a refresh of the registration
data from the TF server. The returned array is safe - no references to
the OutboundLinkTypes are held by this class.
toolId - specifies the tool to get OutboundLinkTypes for (case
insensitive) (must not be null)artifactTypeName - specifies the artifact type to get (case insensitive) (must not be
null)forceRefresh - true to force a call to the server to refresh the
registration data
OutboundLinkTypes for the specified tool and
artifact type, or null if there is no such tool and
artifact typepublic RegistrationExtendedAttribute[] getExtendedAttributes(java.lang.String toolId)
RegistrationExtendedAttributes for the specified
tool. The returned array is safe - no references to the
RegistrationExtendedAttributes are held by this class.
toolId - specifies the tool to get RegistrationExtendedAttributes
for (case insensitive) (must not be null)
RegistrationExtendedAttributes for the
specified tool, or null if the specified tool does
not have a registration entry
public RegistrationExtendedAttribute[] getExtendedAttributes(java.lang.String toolId,
boolean forceRefresh)
RegistrationExtendedAttributes for the specified
tool, specifying whether to force a refresh of the registration data from
the TF server. The returned array is safe - no references to the
RegistrationExtendedAttributes are held by this class.
toolId - specifies the tool to get RegistrationExtendedAttributes
for (case insensitive) (must not be null)forceRefresh - true to force a call to the server to refresh the
registration data
RegistrationExtendedAttributes for the
specified tool, or null if the specified tool does
not have a registration entry
public RegistrationExtendedAttribute getExtendedAttribute(java.lang.String toolId,
java.lang.String attributeName)
RegistrationExtendedAttribute for the
specified tool. The returned RegistrationExtendedAttribute is
safe - no reference to it is held by this class.
toolId - specifies the tool to get the
RegistrationExtendedAttribute for (case insensitive) (must
not be null)attributeName - specifies the attribute to get (case sensitive) (must not be
null)
RegistrationExtendedAttribute for the
specified tool, or null if no such attribute exists
public RegistrationExtendedAttribute getExtendedAttribute(java.lang.String toolId,
java.lang.String attributeName,
boolean forceRefresh)
RegistrationExtendedAttribute for the
specified tool, specifying whether to force a refresh of the registration
data from the TF server. The returned
RegistrationExtendedAttribute is safe - no reference to it is
held by this class.
toolId - specifies the tool to get the
RegistrationExtendedAttribute for (case insensitive) (must
not be null)attributeName - specifies the attribute to get (case sensitive) (must not be
null)forceRefresh - true to force a call to the server to refresh the
registration data
RegistrationExtendedAttribute for the
specified tool, or null if no such attribute exists
public java.lang.String getExtendedAttributeValue(java.lang.String toolId,
java.lang.String attributeName)
toolId - specifies the tool to get the
RegistrationExtendedAttribute for (case insensitive) (must
not be null)attributeName - specifies the attribute to get (case sensitive) (must not be
null)
null if no such
value exists
public java.lang.String getExtendedAttributeValue(java.lang.String toolId,
java.lang.String attributeName,
boolean forceRefresh)
toolId - specifies the tool to get the
RegistrationExtendedAttribute for (case insensitive) (must
not be null)attributeName - specifies the attribute to get (case sensitive) (must not be
null)forceRefresh - true to force a call to the server to refresh the
registration data
null if no such
value existspublic com.microsoft.tfs.util.GUID getInstanceID()
null if the instance ID
could not be determinedpublic com.microsoft.tfs.util.GUID getInstanceID(boolean forceRefresh)
forceRefresh - true to force a call to the server to refresh the
registration data
null if the instance ID
could not be determinedpublic void refresh(boolean force)
false and the cached data not stale, this method does
nothing. Otherwise, the TF server is contacted to get the latest
registration data.
force - true to force a server refresh even if the cached
data is not stale
public java.lang.String getRosarioURLForTeamProject(java.lang.String interfaceName,
java.lang.String projectName)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||