eu.planets_project.services.datatypes
Class Metadata

java.lang.Object
  extended by eu.planets_project.services.datatypes.Metadata
All Implemented Interfaces:
java.io.Serializable

public final class Metadata
extends java.lang.Object
implements java.io.Serializable

Representation of immutable tagged metadata.

See Also:
MetadataTests, Serialized Form

Constructor Summary
Metadata(java.net.URI type, java.lang.String content)
           
Metadata(java.net.URI type, java.lang.String name, java.lang.String content)
           
 
Method Summary
 boolean equals(java.lang.Object obj)
          
 java.lang.String getContent()
           
 java.lang.String getName()
           
 java.net.URI getType()
           
 int hashCode()
          
 java.lang.String toString()
          
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

Metadata

public Metadata(java.net.URI type,
                java.lang.String content)
Parameters:
type - The metadata type. Represents the type of metadata. The URI could be the namespace of a xml schema, or a xml datatype like integer. But in short, given the URI, you should be able to figure out how to understand the metadata. No URI means that the metadata is readily readable, ie. clear text.
content - The actual metadata

Metadata

public Metadata(java.net.URI type,
                java.lang.String name,
                java.lang.String content)
Parameters:
type - The metadata type. Represents the type of metadata. The URI could be the namespace of a xml schema, or a xml datatype like integer. But in short, given the URI, you should be able to figure out how to understand the metadata. No URI means that the metadata is readily readable, ie. clear text.
name - A name for the metadata, used to distinguish between metatdata fragments of the same type.
content - The actual metadata
Method Detail

getContent

public java.lang.String getContent()
Returns:
The actual metadata.

getType

public java.net.URI getType()
Returns:
The metadata type.

getName

public java.lang.String getName()
Returns:
The metadata name

toString

public java.lang.String toString()

Overrides:
toString in class java.lang.Object
See Also:
Object.toString()

hashCode

public int hashCode()

Overrides:
hashCode in class java.lang.Object
See Also:
Object.hashCode()

equals

public boolean equals(java.lang.Object obj)

Overrides:
equals in class java.lang.Object
See Also:
Object.equals(java.lang.Object)


Copyright © 2007-2010 The Planets Consortium. All Rights Reserved.