edu.wisc.trace.urcsdk.client.resources
Class ResourceSheetDescription

java.lang.Object
  extended by edu.wisc.trace.urcsdk.client.resources.ResourceSheetDescription

public class ResourceSheetDescription
extends java.lang.Object

ResourceSheetDescription is the object form of the XML <ResourceSheet> element found in the TargetDirectory. It also provides constants until they get factored out.

Version:
$Revision: 1.21 $
Author:
Andrew Martin, Trace R&D Center Created on: Sep 8, 2004

Field Summary
static java.lang.String DOMAIN
          DOMAIN is the constant value referring to the "domain" metadata.
static java.lang.String HELP_EFFECT
          HELP_EFFECT is the constant value for referring to the "help/effect" type of "type."
static java.lang.String HELP_PURPOSE
          HELP_PURPOSE is the constant value for referring to the "help/purpose" type of "type."
static java.lang.String LABEL
          LABEL is the constant value for referring to "label" metadata.
static java.lang.String LANG
          LANG is the constant value for referring to "languageContexts" metadata.
static java.lang.String ROLE
          ROLE is the constant value for "role" metadata.
static java.lang.String TEXT
          TEXT is the constant value for referring to the "text" type of "type."
static java.lang.String TYPE
          TYPE is the constant value for referring to "type" metadata.
 
Constructor Summary
ResourceSheetDescription(ResourceDirectory parent, org.w3c.dom.Element element)
          Creates a new ResourceSheetDescription instance.
 
Method Summary
 java.net.URI getResourceSheetURI()
          getResourceSheetURI returns the URI associated with this ResourceSheetDescription.
 boolean hasMatchingMetadata(java.util.Map<java.lang.String,java.lang.Object> metadata)
          hasMatchingMetadata returns true or false depending on whether this ResourceSheetDescription matches the passed-in parameter's values.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

ROLE

public static final java.lang.String ROLE
ROLE is the constant value for "role" metadata.

See Also:
Constant Field Values

LABEL

public static final java.lang.String LABEL
LABEL is the constant value for referring to "label" metadata.

See Also:
Constant Field Values

LANG

public static final java.lang.String LANG
LANG is the constant value for referring to "languageContexts" metadata.

See Also:
Constant Field Values

TYPE

public static final java.lang.String TYPE
TYPE is the constant value for referring to "type" metadata.

See Also:
Constant Field Values

TEXT

public static final java.lang.String TEXT
TEXT is the constant value for referring to the "text" type of "type."

See Also:
Constant Field Values

HELP_PURPOSE

public static final java.lang.String HELP_PURPOSE
HELP_PURPOSE is the constant value for referring to the "help/purpose" type of "type."

See Also:
Constant Field Values

HELP_EFFECT

public static final java.lang.String HELP_EFFECT
HELP_EFFECT is the constant value for referring to the "help/effect" type of "type."

See Also:
Constant Field Values

DOMAIN

public static final java.lang.String DOMAIN
DOMAIN is the constant value referring to the "domain" metadata.

See Also:
Constant Field Values
Constructor Detail

ResourceSheetDescription

public ResourceSheetDescription(ResourceDirectory parent,
                                org.w3c.dom.Element element)
Creates a new ResourceSheetDescription instance.

Parameters:
parent - the ResourceDirectory containing this resource sheet.
element - the Element that is the XML representation of this resource sheet.
Method Detail

getResourceSheetURI

public java.net.URI getResourceSheetURI()
getResourceSheetURI returns the URI associated with this ResourceSheetDescription.

Returns:
URI object

hasMatchingMetadata

public boolean hasMatchingMetadata(java.util.Map<java.lang.String,java.lang.Object> metadata)
hasMatchingMetadata returns true or false depending on whether this ResourceSheetDescription matches the passed-in parameter's values. It checks the type, domain, role, and language metadata for matches.

Parameters:
metadata - a Map<String, Object> object.
Returns:
boolean


Copyright © 2006 Trace R&D Center, University of Wisconsin-Madison. All Rights Reserved.