Added methods to retrieve the String representation of Profile XSD
schema. Refs #17423
This commit is contained in:
parent
1292d0e50a
commit
6fbd228b0f
|
@ -174,22 +174,28 @@ public class DataCalogueMetadataFormatReader implements DataCatalogueMetadataDis
|
|||
namespaceCategories = null;
|
||||
}
|
||||
|
||||
|
||||
|
||||
@Override
|
||||
public String getProfileSchema() {
|
||||
if(profileSchema == null) {
|
||||
InputStream inputStream = getProfileSchemaInputStream();
|
||||
profileSchema = new BufferedReader(new InputStreamReader(inputStream)).lines()
|
||||
.collect(Collectors.joining("\n"));
|
||||
profileSchema = DataCalogueMetadataFormatReader.getProfileSchemaString();
|
||||
}
|
||||
return profileSchema;
|
||||
|
||||
}
|
||||
|
||||
static InputStream getProfileSchemaInputStream() {
|
||||
public static String getProfileSchemaString() {
|
||||
InputStream inputStream = DataCalogueMetadataFormatReader.getProfileSchemaInputStream();
|
||||
return new BufferedReader(new InputStreamReader(inputStream)).lines()
|
||||
.collect(Collectors.joining("\n"));
|
||||
}
|
||||
|
||||
public static InputStream getProfileSchemaInputStream() {
|
||||
return DataCalogueMetadataFormatReader.class.getResourceAsStream(SCHEMA_FILENAME);
|
||||
}
|
||||
|
||||
static URL getProfileSchemaURL() {
|
||||
public static URL getProfileSchemaURL() {
|
||||
return DataCalogueMetadataFormatReader.class.getResource(SCHEMA_FILENAME);
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue