root / trunk / extensions / extMetadata / src / org / gvsig / metadata / extended / ExtendedMetadata.java @ 24244
History | View | Annotate | Download (4.78 KB)
1 |
/* gvSIG. Geographic Information System of the Valencian Government
|
---|---|
2 |
*
|
3 |
* Copyright (C) 2007-2008 Infrastructures and Transports Department
|
4 |
* of the Valencian Government (CIT)
|
5 |
*
|
6 |
* This program is free software; you can redistribute it and/or
|
7 |
* modify it under the terms of the GNU General Public License
|
8 |
* as published by the Free Software Foundation; either version 2
|
9 |
* of the License, or (at your option) any later version.
|
10 |
*
|
11 |
* This program is distributed in the hope that it will be useful,
|
12 |
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
13 |
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
14 |
* GNU General Public License for more details.
|
15 |
*
|
16 |
* You should have received a copy of the GNU General Public License
|
17 |
* along with this program; if not, write to the Free Software
|
18 |
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
|
19 |
* MA 02110-1301, USA.
|
20 |
*
|
21 |
*/
|
22 |
|
23 |
/*
|
24 |
* AUTHORS (In addition to CIT):
|
25 |
* 2008 Geographic Information research group: http://www.geoinfo.uji.es
|
26 |
* Departamento de Lenguajes y Sistemas Inform?ticos (LSI)
|
27 |
* Universitat Jaume I
|
28 |
* {{Task}}
|
29 |
*/
|
30 |
|
31 |
|
32 |
|
33 |
|
34 |
package org.gvsig.metadata.extended; |
35 |
|
36 |
import java.util.Date; |
37 |
import java.util.Iterator; |
38 |
|
39 |
import org.gvsig.metadata.Metadata; |
40 |
import org.gvsig.metadata.exceptions.NamedMetadataNotFoundException; |
41 |
import org.gvsig.metadata.extended.registry.objects.MDDefinition; |
42 |
|
43 |
|
44 |
public interface ExtendedMetadata extends Metadata { |
45 |
|
46 |
/**
|
47 |
* Retrieves a MDElement from the ExtendedMetadata object
|
48 |
* @param name the name which identifies the object to return
|
49 |
* @return the object referenced by 'name' in the ExtendedMetadata object
|
50 |
* @throws ClassCastException thrown to indicate that the code has attempted to cast an object to a subclass of which it is not an instance
|
51 |
* @throws NamedMetadataNotFoundException if not Metadata with the 'name' is found
|
52 |
*/
|
53 |
public MDElement getElement(String name) throws ClassCastException, NamedMetadataNotFoundException; |
54 |
|
55 |
/**
|
56 |
* Puts a MDElement in the ExtendedMetadata object
|
57 |
* @param elem the MDElement object to put in the ExtendedMetadata object
|
58 |
*/
|
59 |
public void setElement(MDElement elem); |
60 |
|
61 |
/**
|
62 |
* Retrieves the identifier of the ExtendedMetadata object
|
63 |
* @return the String which identifies the ExtendedMetadata object
|
64 |
*/
|
65 |
public String getId(); |
66 |
|
67 |
/**
|
68 |
* Retrieves the description of the ExtendedMetadata object
|
69 |
* @return a String containing the description of the ExtendedMetadata object
|
70 |
*/
|
71 |
public String getDescription(); |
72 |
|
73 |
/**
|
74 |
* Set the description of the ExtendedMetadata object
|
75 |
*/
|
76 |
public void setDescription(String desc); |
77 |
|
78 |
/**
|
79 |
* Retrieves the date of creation of the object
|
80 |
* @return a Date object containing the system date when the ExtendedMetadata object was created
|
81 |
*/
|
82 |
public Date getCreateDate(); |
83 |
|
84 |
/**
|
85 |
* Retrieves the date of the last change in the object
|
86 |
* @return a Date object containing the system date when the ExtendedMetadata object was modified for the last time
|
87 |
*/
|
88 |
public Date getChangeDate(); |
89 |
|
90 |
/**
|
91 |
* Retrieves the ExtendedMetadata object type
|
92 |
* @return a MDDefinition object containing the name and the description of the ExtendedMetadata object
|
93 |
*/
|
94 |
public MDDefinition getType();
|
95 |
|
96 |
/**
|
97 |
* Retrieves the name of the creator of the ExtendedMetadata object
|
98 |
* @return a String containing the name of the creator of the object
|
99 |
*/
|
100 |
public String getAuthor(); |
101 |
|
102 |
/**
|
103 |
* Checks if the ExtendedMetadata object has a specific value
|
104 |
* @param name the name which identifies the value to check
|
105 |
* @return a boolean value which indicates if there is a value in the object referenced by 'name'
|
106 |
*/
|
107 |
public boolean hasValue(String name); |
108 |
|
109 |
/**
|
110 |
* Checks if the ExtendedMetadata object is empty
|
111 |
* @return a boolean value which indicates if the object has any value
|
112 |
*/
|
113 |
public boolean isEmpty(); |
114 |
|
115 |
/**
|
116 |
* Retrieves the father of the Metadata object, or null if it doesn't have.
|
117 |
* @return a ExtendedMetadata object or null
|
118 |
*/
|
119 |
public ExtendedMetadata getFather();
|
120 |
|
121 |
/**
|
122 |
* Changes father of the object
|
123 |
* @param father the new father value of the ExtendedMetadata object
|
124 |
*/
|
125 |
public void setFather(ExtendedMetadata father); |
126 |
|
127 |
/**
|
128 |
* Checks if the ExtendedMetadata has father
|
129 |
* @return a boolean value which indicates if the object has father
|
130 |
*/
|
131 |
public boolean hasFather(); |
132 |
|
133 |
/**
|
134 |
* Retrieves the deep level in the Metadata tree, 0 for the root.
|
135 |
* @return an integer value which indicates the level.
|
136 |
*/
|
137 |
public int getLevel(); |
138 |
|
139 |
/**
|
140 |
* Retrieves a Iterator to the Metadata elements.
|
141 |
* @return an Iterator object.
|
142 |
*/
|
143 |
public Iterator iterator(); |
144 |
|
145 |
/**
|
146 |
* Retrieves a String representing the Metadata object and its elements.
|
147 |
* @return a String.
|
148 |
*/
|
149 |
public String toString(); |
150 |
} |