Project

General

Profile

« Previous | Next » 

Revision 7526

include class diagram for components in the cn-index-processor packaage (dataone), metacat, and solr library.

View differences:

docs/user/metacat/source/query-index.rst
75 75
..
76 76
  @startuml images/indexing-class-diagram.png
77 77
  
78
	package index.model {
79
		  
80
		abstract class FieldSpec {
81
			- String name
82
			+ abstract String[] extract(Reader s);
78
	package cn-index-processor.parser {
79
	
80
		interface IDocumentSubprocessor {
81
			+ boolean canProcess(Document doc)
82
			+ initExpression(XPath xpath)
83
			+ Map<String, SolrDoc> processDocument(String identifier, Map<String, SolrDoc> docs, Document doc)
83 84
		}
84
		
85
		class D1IndexField {
85
		class AbstractDocumentSubprocessor {
86
			- List<SolrField> fields
86 87
		}
87
		
88
		class XpathIndexField {
88
		class ResourceMapSubprocessor {
89
		}
90
		class ScienceMetadataDocumentSubprocessor {
91
		}
92
			  
93
		interface ISolrField {
94
			+ initExpression(XPath xpathObject)
95
			+ List<SolrElementField> getFields(Document doc, String identifier)
96
		}
97
		class SolrField {
98
			- String name
89 99
			- String xpath
100
			- boolean multivalue
90 101
		}
91
		
92
		class MCIndexDocDef {
93
			- Set<FieldSpec> fields
94
			+ add(FieldSpec)
95
			+ remove(FieldSpec)
102
		class CommonRootSolrField {
96 103
		}
104
		class FullTextSolrField {
105
		}
106
		class MergeSolrField {
107
		}
108
		class ResolveSolrField {
109
		}
110
		class SolrFieldResourceMap {
111
		}
97 112
		    
98 113
	}
99 114
	
100
	FieldSpec <|-- D1IndexField
101
	FieldSpec <|-- XpathIndexField
115
	IDocumentSubprocessor <|-- AbstractDocumentSubprocessor
116
	AbstractDocumentSubprocessor <|-- ResourceMapSubprocessor
117
	AbstractDocumentSubprocessor <|-- ScienceMetadataDocumentSubprocessor
118

  
119
	ISolrField <|-- SolrField
120
	SolrField <|-- CommonRootSolrField
121
	SolrField <|-- FullTextSolrField
122
	SolrField <|-- MergeSolrField
123
	SolrField <|-- ResolveSolrField			
124
	SolrField <|-- SolrFieldResourceMap		
102 125
	
103
	MCIndexDocDef  o--"*" FieldSpec
126
	AbstractDocumentSubprocessor o--"*" ISolrField
104 127
	
105
	package index {
128
	package metacat.index {
106 129
		  
107
		interface GenericIndex {
108
			+ insert(String, Map<String, String[]>)
109
			+ String [] query(String)
110
			+ remove(String)
111
			+ update(String, Map<String, String[]>)
130
		class MetacatIndex {
131
			- GenericIndex index
132
			+ insert(String pid, InputStream)
133
			+ update(String pid, InputStream)
134
			+ remove(String pid)
135
			+ OutputStream query(String solrQuery)
112 136
		}
113 137
		
114
		class D1Index {
138
		class GenericIndex {
115 139
		}
116
		
117 140
		class SolrjIndex {
118 141
		}
119
		
120 142
		class Embedded {
121 143
		}
122
		
123
		class LuceneIndex {
144
	
145
	}
146
	
147
	GenericIndex <|-- SolrjIndex		
148
	SolrjIndex <|-- Embedded		
149

  
150
	package solr {
151
		  
152
		abstract class SolrServer {
153
			+ add(SolrInputDocument doc)
154
			+ deleteByQuery(String id)
155
			+ query(SolrQuery query)
124 156
		}
125
		
126
		class MetacatIndex {
127
			+ remove(String)
128
			+ retrieve(String)
129
			+ update(String, Reader)
157
		class EmbeddedSolrServer {
130 158
		}
131
		
132
		class DocType {
133
			+ boolean isEml()
134
			+ boolean isSysmeta()
135
			+ boolean isSyseml()
136
			+ boolean isSysdryad()
137
			+ boolean isSysfgdc()
159
		class HttpSolrServer {
138 160
		}
139 161
	
140 162
	}
141 163
	
142
	GenericIndex <|-- D1Index
143
	GenericIndex <|-- SolrjIndex
144
	SolrjIndex <|-- Embedded
145
	GenericIndex <|-- LuceneIndex
164
	SolrServer <|-- EmbeddedSolrServer
165
	SolrServer <|-- HttpSolrServer
166
	
167
	SolrjIndex o--"1" HttpSolrServer
168
	Embedded o--"1" EmbeddedSolrServer
169
	MetacatIndex o--"1" GenericIndex
146 170
  
147 171
  @enduml

Also available in: Unified diff