mirror of
https://github.com/itplr-kosit/validator.git
synced 2026-05-25 16:55:39 +00:00
Initial Implementation
This commit is contained in:
parent
2950785e25
commit
beeb104007
98 changed files with 29308 additions and 0 deletions
149
src/test/java/de/kosit/validationtool/api/InputFactoryTest.java
Normal file
149
src/test/java/de/kosit/validationtool/api/InputFactoryTest.java
Normal file
|
|
@ -0,0 +1,149 @@
|
|||
/*
|
||||
* Licensed to the Koordinierungsstelle für IT-Standards (KoSIT) under
|
||||
* one or more contributor license agreements. See the NOTICE file
|
||||
* distributed with this work for additional information
|
||||
* regarding copyright ownership. KoSIT licenses this file
|
||||
* to you under the Apache License, Version 2.0 (the
|
||||
* "License"); you may not use this file except in compliance
|
||||
* with the License. You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing,
|
||||
* software distributed under the License is distributed on an
|
||||
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||
* KIND, either express or implied. See the License for the
|
||||
* specific language governing permissions and limitations
|
||||
* under the License.
|
||||
*/
|
||||
|
||||
package de.kosit.validationtool.api;
|
||||
|
||||
import static org.assertj.core.api.Assertions.assertThat;
|
||||
|
||||
import java.io.ByteArrayInputStream;
|
||||
import java.io.File;
|
||||
import java.io.InputStream;
|
||||
import java.net.MalformedURLException;
|
||||
import java.net.URISyntaxException;
|
||||
import java.net.URL;
|
||||
import java.nio.file.Paths;
|
||||
|
||||
import org.junit.Rule;
|
||||
import org.junit.Test;
|
||||
import org.junit.rules.ExpectedException;
|
||||
|
||||
import de.kosit.validationtool.impl.ConversionServiceTest;
|
||||
|
||||
/**
|
||||
* Testet den Hashcode-Service.
|
||||
*
|
||||
* @author Andreas Penski
|
||||
*/
|
||||
public class InputFactoryTest {
|
||||
|
||||
private static final URL CONTENT = ConversionServiceTest.class.getResource("/valid/scenarios.xml");
|
||||
|
||||
private static final URL OTHER_CONTENT = ConversionServiceTest.class.getResource("/valid/report.xml");
|
||||
|
||||
public static final String SOME_VALUE = "some value";
|
||||
|
||||
private static URL NOT_EXISTING;
|
||||
|
||||
static {
|
||||
try {
|
||||
NOT_EXISTING = new URL("file://localhost/somefile.text");
|
||||
} catch (MalformedURLException e) {
|
||||
// just ignore;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@Rule
|
||||
public ExpectedException expectedException = ExpectedException.none();
|
||||
|
||||
@Test
|
||||
public void testDefaultDigestAlgorithm() {
|
||||
assertThat(new InputFactory().getAlgorithm()).isEqualTo(InputFactory.DEFAULT_ALGORITH);
|
||||
assertThat(new InputFactory("").getAlgorithm()).isEqualTo(InputFactory.DEFAULT_ALGORITH);
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testSimple() {
|
||||
final byte[] s1 = InputFactory.read(CONTENT).getHashCode();
|
||||
final byte[] s2 = InputFactory.read(CONTENT).getHashCode();
|
||||
final byte[] s3 = InputFactory.read(OTHER_CONTENT).getHashCode();
|
||||
assertThat(s1).isNotEmpty();
|
||||
assertThat(s1).isEqualTo(s2);
|
||||
assertThat(s3).isNotEmpty();
|
||||
assertThat(s1).isNotEqualTo(s3);
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testWrongAlgorithm() {
|
||||
expectedException.expect(IllegalStateException.class);
|
||||
InputFactory service = new InputFactory("unknown");
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testNullInputURL() {
|
||||
expectedException.expect(IllegalArgumentException.class);
|
||||
InputFactory.read((URL) null);
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testInputByte() {
|
||||
final Input input = InputFactory.read(SOME_VALUE.getBytes(), SOME_VALUE);
|
||||
assertThat(input).isNotNull();
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testInputStream() {
|
||||
final Input input = InputFactory.read(new ByteArrayInputStream(SOME_VALUE.getBytes()), SOME_VALUE);
|
||||
assertThat(input).isNotNull();
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testNullStream() {
|
||||
expectedException.expect(IllegalArgumentException.class);
|
||||
final Input input = InputFactory.read((InputStream)null, SOME_VALUE);
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testInputFile() throws URISyntaxException {
|
||||
final Input input = InputFactory.read(new File(CONTENT.toURI()));
|
||||
assertThat(input).isNotNull();
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testInputPath() throws URISyntaxException {
|
||||
final Input input = InputFactory.read(Paths.get(CONTENT.toURI()));
|
||||
assertThat(input).isNotNull();
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testNullInput() {
|
||||
expectedException.expect(IllegalArgumentException.class);
|
||||
InputFactory.read((byte[]) null, SOME_VALUE);
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testNullInputName() {
|
||||
expectedException.expect(IllegalArgumentException.class);
|
||||
InputFactory.read(SOME_VALUE.getBytes(), null);
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testEmptyInputName() {
|
||||
expectedException.expect(IllegalArgumentException.class);
|
||||
InputFactory.read(SOME_VALUE.getBytes(), "");
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testUnexistingInput() {
|
||||
expectedException.expect(IllegalArgumentException.class);
|
||||
InputFactory.read(NOT_EXISTING);
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
|
@ -0,0 +1,77 @@
|
|||
/*
|
||||
* Licensed to the Koordinierungsstelle für IT-Standards (KoSIT) under
|
||||
* one or more contributor license agreements. See the NOTICE file
|
||||
* distributed with this work for additional information
|
||||
* regarding copyright ownership. KoSIT licenses this file
|
||||
* to you under the Apache License, Version 2.0 (the
|
||||
* "License"); you may not use this file except in compliance
|
||||
* with the License. You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing,
|
||||
* software distributed under the License is distributed on an
|
||||
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||
* KIND, either express or implied. See the License for the
|
||||
* specific language governing permissions and limitations
|
||||
* under the License.
|
||||
*/
|
||||
|
||||
package de.kosit.validationtool.cmd;
|
||||
|
||||
import static org.assertj.core.api.Assertions.assertThat;
|
||||
|
||||
import java.io.IOException;
|
||||
import java.net.URISyntaxException;
|
||||
import java.net.URL;
|
||||
|
||||
import org.junit.Before;
|
||||
import org.junit.Test;
|
||||
|
||||
import de.kosit.validationtool.api.InputFactory;
|
||||
import de.kosit.validationtool.cmd.assertions.Assertions;
|
||||
import de.kosit.validationtool.impl.Helper;
|
||||
import de.kosit.validationtool.impl.ObjectFactory;
|
||||
import de.kosit.validationtool.impl.tasks.CheckAction;
|
||||
import de.kosit.validationtool.model.reportInput.CreateReportInput;
|
||||
|
||||
/**
|
||||
* Testet das Assertion-Feature.
|
||||
*
|
||||
* @author Andreas Penski
|
||||
*/
|
||||
public class CheckAssertionActionTest {
|
||||
|
||||
private static final URL SAMPLE = CheckAssertionActionTest.class.getResource("/examples/assertions/ubl-0001.xml");
|
||||
|
||||
private static final URL SAMPLE_REPORT = CheckAssertionActionTest.class.getResource("/examples/assertions/ubl-0001-report.xml");
|
||||
|
||||
private static final URL SAMPLE_ASSERTIONS = CheckAssertionActionTest.class.getResource("/examples/assertions/tests-xrechnung.xml");
|
||||
|
||||
private CommandLine commandLine;
|
||||
|
||||
@Before
|
||||
public void setup() throws IOException {
|
||||
commandLine = new CommandLine();
|
||||
commandLine.activate();
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testEmptyInput() {
|
||||
CheckAssertionAction a = new CheckAssertionAction(new Assertions(), ObjectFactory.createProcessor());
|
||||
a.check(new CheckAction.Bag(InputFactory.read(SAMPLE), new CreateReportInput()));
|
||||
assertThat(commandLine.getErrorOutput()).contains("Can not find assertions for");
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testSimple() throws URISyntaxException {
|
||||
final CheckAction.Bag bag = new CheckAction.Bag(InputFactory.read(SAMPLE), new CreateReportInput());
|
||||
bag.setReport(Helper.load(SAMPLE_REPORT).getObject());
|
||||
|
||||
final Assertions assertions = Helper.load(SAMPLE_ASSERTIONS, Assertions.class);
|
||||
CheckAssertionAction a = new CheckAssertionAction(assertions, ObjectFactory.createProcessor());
|
||||
a.check(bag);
|
||||
|
||||
assertThat(commandLine.getErrorOutput()).contains("Assertion mismatch");
|
||||
}
|
||||
}
|
||||
130
src/test/java/de/kosit/validationtool/cmd/CommandLine.java
Normal file
130
src/test/java/de/kosit/validationtool/cmd/CommandLine.java
Normal file
|
|
@ -0,0 +1,130 @@
|
|||
/*
|
||||
* Licensed to the Koordinierungsstelle für IT-Standards (KoSIT) under
|
||||
* one or more contributor license agreements. See the NOTICE file
|
||||
* distributed with this work for additional information
|
||||
* regarding copyright ownership. KoSIT licenses this file
|
||||
* to you under the Apache License, Version 2.0 (the
|
||||
* "License"); you may not use this file except in compliance
|
||||
* with the License. You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing,
|
||||
* software distributed under the License is distributed on an
|
||||
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||
* KIND, either express or implied. See the License for the
|
||||
* specific language governing permissions and limitations
|
||||
* under the License.
|
||||
*/
|
||||
|
||||
package de.kosit.validationtool.cmd;
|
||||
|
||||
import java.io.*;
|
||||
import java.util.List;
|
||||
|
||||
import org.apache.commons.io.IOUtils;
|
||||
import org.apache.commons.io.output.TeeOutputStream;
|
||||
|
||||
import lombok.Getter;
|
||||
import lombok.Setter;
|
||||
|
||||
/**
|
||||
* Helferlein um Ausgaben auf der Kommandozeile zu testen.
|
||||
*
|
||||
* @author Andreas Penski
|
||||
*/
|
||||
public class CommandLine {
|
||||
|
||||
private static ReplaceableOutputStream<ByteArrayOutputStream> out = new ReplaceableOutputStream<>();
|
||||
|
||||
private static ReplaceableOutputStream<ByteArrayOutputStream> error = new ReplaceableOutputStream<>();
|
||||
|
||||
static {
|
||||
// Initialisierung muss vor SL4J's SimpleLogger erfolgen, sonst sind logs nicht erfasst.
|
||||
// deshalb darf diese Klasse kein Log haben
|
||||
System.setOut(new PrintStream(new TeeOutputStream(System.out, out)));
|
||||
System.setErr(new PrintStream(new TeeOutputStream(System.err, error)));
|
||||
}
|
||||
|
||||
public String getOutput() {
|
||||
return new String(out.getOut().toByteArray());
|
||||
}
|
||||
|
||||
|
||||
public String getErrorOutput() {
|
||||
return new String(error.getOut().toByteArray());
|
||||
}
|
||||
|
||||
public List<String> getOutputLines() {
|
||||
return readLines(out.getOut().toByteArray());
|
||||
}
|
||||
|
||||
public List<String> getErrorLines() {
|
||||
return readLines(error.getOut().toByteArray());
|
||||
}
|
||||
|
||||
private List<String> readLines(byte[] bytes) {
|
||||
try ( ByteArrayInputStream in = new ByteArrayInputStream(bytes);
|
||||
Reader r = new InputStreamReader(in) ) {
|
||||
|
||||
return IOUtils.readLines(r);
|
||||
} catch (IOException e) {
|
||||
throw new IllegalStateException("Can not read input");
|
||||
}
|
||||
}
|
||||
|
||||
public void activate() {
|
||||
out.setOut(new ByteArrayOutputStream());
|
||||
error.setOut(new ByteArrayOutputStream());
|
||||
|
||||
}
|
||||
|
||||
public void deactivate() {
|
||||
out.setOut(null);
|
||||
error.setOut(null);
|
||||
}
|
||||
|
||||
/**
|
||||
* Simpler Proxy für {@link OutputStream}, dessen target ausgetauscht werden kann.
|
||||
*
|
||||
* @param <O> Typ des eigentlichen {@link OutputStream}
|
||||
*/
|
||||
private static class ReplaceableOutputStream<O extends OutputStream> extends OutputStream {
|
||||
|
||||
@Getter
|
||||
@Setter
|
||||
private O out;
|
||||
|
||||
public void write(int idx) throws IOException {
|
||||
if (out != null) {
|
||||
this.out.write(idx);
|
||||
}
|
||||
}
|
||||
|
||||
public void write(byte[] bts) throws IOException {
|
||||
if (out != null) {
|
||||
this.out.write(bts);
|
||||
}
|
||||
}
|
||||
|
||||
public void write(byte[] bts, int st, int end) throws IOException {
|
||||
if (out != null) {
|
||||
this.out.write(bts, st, end);
|
||||
}
|
||||
}
|
||||
|
||||
public void flush() throws IOException {
|
||||
|
||||
if (out != null) {
|
||||
this.out.flush();
|
||||
}
|
||||
}
|
||||
|
||||
public void close() throws IOException {
|
||||
if (out != null) {
|
||||
this.out.close();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
|
@ -0,0 +1,178 @@
|
|||
/*
|
||||
* Licensed to the Koordinierungsstelle für IT-Standards (KoSIT) under
|
||||
* one or more contributor license agreements. See the NOTICE file
|
||||
* distributed with this work for additional information
|
||||
* regarding copyright ownership. KoSIT licenses this file
|
||||
* to you under the Apache License, Version 2.0 (the
|
||||
* "License"); you may not use this file except in compliance
|
||||
* with the License. You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing,
|
||||
* software distributed under the License is distributed on an
|
||||
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||
* KIND, either express or implied. See the License for the
|
||||
* specific language governing permissions and limitations
|
||||
* under the License.
|
||||
*/
|
||||
|
||||
package de.kosit.validationtool.cmd;
|
||||
|
||||
import org.junit.Before;
|
||||
import org.junit.Test;
|
||||
|
||||
import java.io.IOException;
|
||||
import java.nio.file.Files;
|
||||
import java.nio.file.Path;
|
||||
import java.nio.file.Paths;
|
||||
import java.util.List;
|
||||
|
||||
import static de.kosit.validationtool.impl.Helper.*;
|
||||
import static org.assertj.core.api.Assertions.assertThat;
|
||||
|
||||
/**
|
||||
* Testet die Parameter des Kommandozeilen-Tools.
|
||||
*
|
||||
* @author Andreas Penski
|
||||
*/
|
||||
public class CommandlineApplicationTest {
|
||||
|
||||
public static final String RESULT_OUTPUT = "Processing 1 object(s) completed";
|
||||
|
||||
private CommandLine commandLine;
|
||||
|
||||
|
||||
@Before
|
||||
public void setup() throws IOException {
|
||||
commandLine = new CommandLine();
|
||||
commandLine.activate();
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testHelp() {
|
||||
String[] args = new String[] { "-?" };
|
||||
CommandLineApplication.mainProgram(args);
|
||||
assertThat(commandLine.getErrorOutput()).isEmpty();
|
||||
checkForHelp(commandLine.getOutputLines());
|
||||
}
|
||||
|
||||
private void checkForHelp(List<String> outputLines) {
|
||||
assertThat(outputLines.size()).isGreaterThan(0);
|
||||
outputLines.subList(1, outputLines.size() - 1).forEach(l -> assertThat(l.startsWith(" -") || l.startsWith(" ")));
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testRequiredScenarioFile() {
|
||||
String[] args = new String[] { "-d", "arguments", "egal welche", "argument drin sind" };
|
||||
CommandLineApplication.mainProgram(args);
|
||||
assertThat(commandLine.getErrorOutput()).isNotEmpty();
|
||||
assertThat(commandLine.getErrorOutput()).contains("Missing required option: s");
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testNotExistingScenarioFile() {
|
||||
String[] args = new String[] { "-s", Paths.get(NOT_EXISTING).toString(), Paths.get(NOT_EXISTING).toString() };
|
||||
CommandLineApplication.mainProgram(args);
|
||||
assertThat(commandLine.getErrorOutput()).isNotEmpty();
|
||||
assertThat(commandLine.getErrorOutput()).contains("Not a valid path for scenario definition specified");
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testIncorrectRepository() {
|
||||
String[] args = new String[] { "-s", Paths.get(SCENARIO_FILE).toString(), Paths.get(NOT_EXISTING).toString() };
|
||||
CommandLineApplication.mainProgram(args);
|
||||
assertThat(commandLine.getErrorOutput()).isNotEmpty();
|
||||
assertThat(commandLine.getErrorOutput()).contains("Can not load schema from sources");
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testNotExistingTestTarget() {
|
||||
String[] args = new String[] { "-s", Paths.get(SCENARIO_FILE).toString(), "-r", Paths.get(REPOSITORY).toString(),
|
||||
Paths.get(NOT_EXISTING).toString() };
|
||||
CommandLineApplication.mainProgram(args);
|
||||
assertThat(commandLine.getErrorOutput()).isNotEmpty();
|
||||
assertThat(commandLine.getErrorOutput()).contains("No test targets found");
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testValidMinimalConfiguration() {
|
||||
String[] args = new String[] { "-s", Paths.get(SCENARIO_FILE).toString(), "-r", Paths.get(REPOSITORY).toString(),
|
||||
Paths.get(SAMPLE).toString() };
|
||||
CommandLineApplication.mainProgram(args);
|
||||
assertThat(commandLine.getErrorOutput()).contains(RESULT_OUTPUT);
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testValidMultipleInput() {
|
||||
String[] args = new String[] { "-s", Paths.get(SCENARIO_FILE).toString(), "-r", Paths.get(REPOSITORY).toString(),
|
||||
Paths.get(SAMPLE).toString(), Paths.get(SAMPLE2).toString() };
|
||||
CommandLineApplication.mainProgram(args);
|
||||
assertThat(commandLine.getErrorOutput()).contains("Processing 2 object(s) completed");
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testValidDirectoryInput() {
|
||||
String[] args = new String[] { "-s", Paths.get(SCENARIO_FILE).toString(), "-r", Paths.get(REPOSITORY).toString(),
|
||||
Paths.get(SAMPLE_DIR).toString() };
|
||||
CommandLineApplication.mainProgram(args);
|
||||
assertThat(commandLine.getErrorOutput()).contains("Processing 4 object(s) completed");
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testValidOutputConfiguration() throws IOException {
|
||||
Path output = Paths.get("output");
|
||||
// assertThat(output).doesNotExist();
|
||||
String[] args = new String[] { "-s", Paths.get(SCENARIO_FILE).toString(), "-o", output.getFileName().toString(), "-r",
|
||||
Paths.get(REPOSITORY).toString(), Paths.get(SAMPLE).toString() };
|
||||
CommandLineApplication.mainProgram(args);
|
||||
assertThat(commandLine.getErrorOutput()).contains(RESULT_OUTPUT);
|
||||
assertThat(output).exists();
|
||||
assertThat(Files.list(output)).hasSize(1);
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testNoInput() {
|
||||
// assertThat(output).doesNotExist();
|
||||
String[] args = new String[] { "-s", Paths.get(SCENARIO_FILE).toString(), "-r", Paths.get(REPOSITORY).toString(), };
|
||||
CommandLineApplication.mainProgram(args);
|
||||
checkForHelp(commandLine.getOutputLines());
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testPrint() {
|
||||
|
||||
String[] args = new String[] { "-s", Paths.get(SCENARIO_FILE).toString(), "-p", "-r", Paths.get(REPOSITORY).toString(),
|
||||
Paths.get(SAMPLE).toString() };
|
||||
CommandLineApplication.mainProgram(args);
|
||||
assertThat(commandLine.getErrorOutput()).contains(RESULT_OUTPUT);
|
||||
assertThat(commandLine.getOutputLines()).contains("<?xml version=\"1.0\" encoding=\"UTF-8\"?>");
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testHtmlExtraktion() throws IOException {
|
||||
Path output = Files.createTempDirectory("pruef-tool-test");
|
||||
String[] args = new String[] { "-s", Paths.get(SCENARIO_FILE).toString(), "-h", "-o", output.toAbsolutePath().toString(), "-r",
|
||||
Paths.get(REPOSITORY).toString(), Paths.get(SAMPLE).toString() };
|
||||
CommandLineApplication.mainProgram(args);
|
||||
assertThat(commandLine.getErrorOutput()).contains(RESULT_OUTPUT);
|
||||
assertThat(Files.list(output).filter(f -> f.toString().endsWith(".html")).count()).isGreaterThan(0);
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testAssertionsExtraktion() throws IOException {
|
||||
String[] args = new String[] { "-d", "-s", Paths.get(SCENARIO_FILE).toString(), "-r", Paths.get(REPOSITORY).toString(), "-c",
|
||||
Paths.get(ASSERTIONS).toString(), Paths.get(REPOSITORY).toString(), Paths.get(SAMPLE).toString() };
|
||||
CommandLineApplication.mainProgram(args);
|
||||
assertThat(commandLine.getErrorOutput()).contains(RESULT_OUTPUT);
|
||||
assertThat(commandLine.getErrorOutput()).contains("Can not find assertions for ");
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testDebugFlag() throws IOException {
|
||||
String[] args = new String[] { "-s", Paths.get(SCENARIO_FILE).toString(), "-r", "unknown", "-d", Paths.get(ASSERTIONS).toString() };
|
||||
CommandLineApplication.mainProgram(args);
|
||||
assertThat(commandLine.getErrorOutput()).contains("at de.kosit.validationtool");
|
||||
}
|
||||
|
||||
}
|
||||
|
|
@ -0,0 +1,74 @@
|
|||
/*
|
||||
* Licensed to the Koordinierungsstelle für IT-Standards (KoSIT) under
|
||||
* one or more contributor license agreements. See the NOTICE file
|
||||
* distributed with this work for additional information
|
||||
* regarding copyright ownership. KoSIT licenses this file
|
||||
* to you under the Apache License, Version 2.0 (the
|
||||
* "License"); you may not use this file except in compliance
|
||||
* with the License. You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing,
|
||||
* software distributed under the License is distributed on an
|
||||
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||
* KIND, either express or implied. See the License for the
|
||||
* specific language governing permissions and limitations
|
||||
* under the License.
|
||||
*/
|
||||
|
||||
package de.kosit.validationtool.cmd;
|
||||
|
||||
import static org.assertj.core.api.Assertions.assertThat;
|
||||
|
||||
import java.io.IOException;
|
||||
import java.net.URL;
|
||||
import java.nio.file.Files;
|
||||
import java.nio.file.Path;
|
||||
import java.util.stream.Collectors;
|
||||
|
||||
import org.apache.commons.io.FileUtils;
|
||||
import org.junit.After;
|
||||
import org.junit.Before;
|
||||
import org.junit.Test;
|
||||
|
||||
import de.kosit.validationtool.api.InputFactory;
|
||||
import de.kosit.validationtool.impl.Helper;
|
||||
import de.kosit.validationtool.impl.tasks.CheckAction;
|
||||
|
||||
/**
|
||||
* Testet die HTML-Extrkation des Kommondazeilenprogramms.
|
||||
*
|
||||
* @author Andreas Penski
|
||||
*/
|
||||
public class ExtractHtmlActionTest {
|
||||
|
||||
private static final URL REPORT = SerializeReportActionTest.class.getResource("/examples/results/report.xml");
|
||||
|
||||
private ExtractHtmlContentAction action;
|
||||
|
||||
private Path tmpDirectory;
|
||||
|
||||
@Before
|
||||
public void setup() throws IOException {
|
||||
tmpDirectory = Files.createTempDirectory("checktool");
|
||||
action = new ExtractHtmlContentAction(Helper.loadTestRepository(), tmpDirectory);
|
||||
}
|
||||
|
||||
@After
|
||||
public void tearDown() throws IOException {
|
||||
FileUtils.deleteDirectory(tmpDirectory.toFile());
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testSimple() throws IOException {
|
||||
CheckAction.Bag b = new CheckAction.Bag(InputFactory.read(REPORT));
|
||||
assertThat(action.isSkipped(b)).isTrue();
|
||||
b.setReport(Helper.load(REPORT).getObject());
|
||||
action.check(b);
|
||||
assertThat(action.isSkipped(b)).isFalse();
|
||||
action.check(b);
|
||||
assertThat(b.isStopped()).isFalse();
|
||||
assertThat(Files.list(tmpDirectory).collect(Collectors.toList())).hasSize(1);
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,70 @@
|
|||
/*
|
||||
* Licensed to the Koordinierungsstelle für IT-Standards (KoSIT) under
|
||||
* one or more contributor license agreements. See the NOTICE file
|
||||
* distributed with this work for additional information
|
||||
* regarding copyright ownership. KoSIT licenses this file
|
||||
* to you under the Apache License, Version 2.0 (the
|
||||
* "License"); you may not use this file except in compliance
|
||||
* with the License. You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing,
|
||||
* software distributed under the License is distributed on an
|
||||
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||
* KIND, either express or implied. See the License for the
|
||||
* specific language governing permissions and limitations
|
||||
* under the License.
|
||||
*/
|
||||
|
||||
package de.kosit.validationtool.cmd;
|
||||
|
||||
import static org.assertj.core.api.Assertions.assertThat;
|
||||
|
||||
import java.io.IOException;
|
||||
import java.net.URL;
|
||||
|
||||
import org.junit.After;
|
||||
import org.junit.Before;
|
||||
import org.junit.Test;
|
||||
|
||||
import de.kosit.validationtool.api.InputFactory;
|
||||
import de.kosit.validationtool.impl.Helper;
|
||||
import de.kosit.validationtool.impl.tasks.CheckAction;
|
||||
|
||||
/**
|
||||
* @author Andreas Penski
|
||||
*/
|
||||
public class PrintReportActionTest {
|
||||
|
||||
private static final URL REPORT = SerializeReportActionTest.class.getResource("/examples/results/report.xml");
|
||||
|
||||
private CommandLine commandLine;
|
||||
|
||||
private PrintReportAction action;
|
||||
|
||||
@Before
|
||||
public void setup() throws IOException {
|
||||
commandLine = new CommandLine();
|
||||
commandLine.activate();
|
||||
action = new PrintReportAction();
|
||||
}
|
||||
|
||||
@After
|
||||
public void tearDownd() throws IOException {
|
||||
commandLine.deactivate();
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testSimpleSerialize() {
|
||||
CheckAction.Bag b = new CheckAction.Bag(InputFactory.read(REPORT));
|
||||
b.setReport(Helper.load(REPORT).getObject());
|
||||
assertThat(action.isSkipped(b)).isFalse();
|
||||
action.check(b);
|
||||
assertThat(b.isStopped()).isFalse();
|
||||
assertThat(commandLine.getOutput()).isNotEmpty();
|
||||
assertThat(commandLine.getOutput()).startsWith("<?xml version=\"1.0\" ");
|
||||
assertThat(commandLine.getErrorOutput()).isEmpty();
|
||||
}
|
||||
|
||||
}
|
||||
|
|
@ -0,0 +1,78 @@
|
|||
/*
|
||||
* Licensed to the Koordinierungsstelle für IT-Standards (KoSIT) under
|
||||
* one or more contributor license agreements. See the NOTICE file
|
||||
* distributed with this work for additional information
|
||||
* regarding copyright ownership. KoSIT licenses this file
|
||||
* to you under the Apache License, Version 2.0 (the
|
||||
* "License"); you may not use this file except in compliance
|
||||
* with the License. You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing,
|
||||
* software distributed under the License is distributed on an
|
||||
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||
* KIND, either express or implied. See the License for the
|
||||
* specific language governing permissions and limitations
|
||||
* under the License.
|
||||
*/
|
||||
|
||||
package de.kosit.validationtool.cmd;
|
||||
|
||||
import de.kosit.validationtool.api.InputFactory;
|
||||
import de.kosit.validationtool.impl.Helper;
|
||||
import de.kosit.validationtool.impl.tasks.CheckAction;
|
||||
import org.apache.commons.io.FileUtils;
|
||||
import org.junit.After;
|
||||
import org.junit.Before;
|
||||
import org.junit.Test;
|
||||
|
||||
import java.io.IOException;
|
||||
import java.net.URL;
|
||||
import java.nio.file.Files;
|
||||
import java.nio.file.Path;
|
||||
|
||||
import static org.assertj.core.api.Assertions.assertThat;
|
||||
|
||||
/**
|
||||
* @author Andreas Penski
|
||||
*/
|
||||
public class SerializeReportActionTest {
|
||||
|
||||
private static final URL REPORT = SerializeReportActionTest.class.getResource("/examples/results/report.xml");
|
||||
|
||||
private Path tmpDirectory;
|
||||
|
||||
private SerializeReportAction action;
|
||||
|
||||
@Before
|
||||
public void setup() throws IOException {
|
||||
tmpDirectory = Files.createTempDirectory("checktool");
|
||||
action = new SerializeReportAction(tmpDirectory);
|
||||
}
|
||||
|
||||
@After
|
||||
public void tearDown() throws IOException {
|
||||
FileUtils.deleteDirectory(tmpDirectory.toFile());
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testSimpleSerialize() {
|
||||
CheckAction.Bag b = new CheckAction.Bag(InputFactory.read(REPORT));
|
||||
assertThat(action.isSkipped(b)).isTrue();
|
||||
b.setReport(Helper.load(REPORT).getObject());
|
||||
assertThat(action.isSkipped(b)).isFalse();
|
||||
action.check(b);
|
||||
assertThat(b.isStopped()).isFalse();
|
||||
assertThat(tmpDirectory.toFile().listFiles()).hasSize(1);
|
||||
}
|
||||
|
||||
//ERPT-83
|
||||
@Test
|
||||
public void testName(){
|
||||
final String name = "some.name.with.dots";
|
||||
CheckAction.Bag b = new CheckAction.Bag(InputFactory.read("ega".getBytes(), name + ".xml"));
|
||||
assertThat(b.getName()).isEqualTo(name);
|
||||
}
|
||||
|
||||
}
|
||||
|
|
@ -0,0 +1,111 @@
|
|||
/*
|
||||
* Licensed to the Koordinierungsstelle für IT-Standards (KoSIT) under
|
||||
* one or more contributor license agreements. See the NOTICE file
|
||||
* distributed with this work for additional information
|
||||
* regarding copyright ownership. KoSIT licenses this file
|
||||
* to you under the Apache License, Version 2.0 (the
|
||||
* "License"); you may not use this file except in compliance
|
||||
* with the License. You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing,
|
||||
* software distributed under the License is distributed on an
|
||||
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||
* KIND, either express or implied. See the License for the
|
||||
* specific language governing permissions and limitations
|
||||
* under the License.
|
||||
*/
|
||||
|
||||
package de.kosit.validationtool.impl;
|
||||
|
||||
import static org.assertj.core.api.Assertions.assertThat;
|
||||
|
||||
import java.net.MalformedURLException;
|
||||
import java.util.Collections;
|
||||
import java.util.HashMap;
|
||||
import java.util.Map;
|
||||
|
||||
import javax.xml.validation.Schema;
|
||||
|
||||
import org.junit.Before;
|
||||
import org.junit.Rule;
|
||||
import org.junit.Test;
|
||||
import org.junit.rules.ExpectedException;
|
||||
|
||||
import net.sf.saxon.s9api.XPathExecutable;
|
||||
import net.sf.saxon.s9api.XsltExecutable;
|
||||
|
||||
/**
|
||||
* Testet das ContentRepository.
|
||||
*
|
||||
* @author Andreas Penski
|
||||
*/
|
||||
public class ContentRepositoryTest {
|
||||
|
||||
private ContentRepository repository;
|
||||
|
||||
@Rule
|
||||
public ExpectedException exception = ExpectedException.none();
|
||||
|
||||
|
||||
@Before
|
||||
public void setup() {
|
||||
repository = new ContentRepository(ObjectFactory.createProcessor(), Helper.REPOSITORY);
|
||||
}
|
||||
|
||||
|
||||
@Test
|
||||
public void testCreateSchema() throws MalformedURLException {
|
||||
final Schema schema = repository.createSchema(Helper.ASSERTION_SCHEMA.toURL());
|
||||
assertThat(schema).isNotNull();
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testSchemaCaching() throws MalformedURLException {
|
||||
final Schema schema = repository.getReportInputSchema();
|
||||
assertThat(repository.getReportInputSchema()).isSameAs(schema);
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testCreateSchemaNotExisting()throws Exception {
|
||||
exception.expect(IllegalStateException.class);
|
||||
repository.createSchema(Helper.ASSERTION_SCHEMA.resolve("noexisting").toURL());
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testLoadXSLT() throws MalformedURLException {
|
||||
final XsltExecutable executable = repository.loadXsltScript(Helper.SAMPLE_XSLT);
|
||||
assertThat(executable).isNotNull();
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testLoadXSLTNotExisting() throws MalformedURLException {
|
||||
exception.expect(IllegalStateException.class);
|
||||
repository.loadXsltScript(Helper.SAMPLE_XSLT.resolve("notexisting"));
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testXpathCreation() throws MalformedURLException {
|
||||
XPathExecutable xPath = repository.createXPath("//html", null);
|
||||
assertThat(xPath).isNotNull();
|
||||
xPath = repository.createXPath("//html", Collections.emptyMap());
|
||||
assertThat(xPath).isNotNull();
|
||||
Map<String,String> namespace = new HashMap<>();
|
||||
namespace.put("html", "http://www.w3.org/1999/xhtml");
|
||||
xPath = repository.createXPath("//html:html", namespace );
|
||||
assertThat(xPath).isNotNull();
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testXpathCreationWithoutNamespace(){
|
||||
exception.expect(IllegalStateException.class);
|
||||
repository.createXPath("//html:html", null );
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testIllegalXpath(){
|
||||
exception.expect(IllegalStateException.class);
|
||||
repository.createXPath("kein Xpath Ausdruck", null );
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,121 @@
|
|||
/*
|
||||
* Licensed to the Koordinierungsstelle für IT-Standards (KoSIT) under
|
||||
* one or more contributor license agreements. See the NOTICE file
|
||||
* distributed with this work for additional information
|
||||
* regarding copyright ownership. KoSIT licenses this file
|
||||
* to you under the Apache License, Version 2.0 (the
|
||||
* "License"); you may not use this file except in compliance
|
||||
* with the License. You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing,
|
||||
* software distributed under the License is distributed on an
|
||||
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||
* KIND, either express or implied. See the License for the
|
||||
* specific language governing permissions and limitations
|
||||
* under the License.
|
||||
*/
|
||||
|
||||
package de.kosit.validationtool.impl;
|
||||
|
||||
import static org.assertj.core.api.Java6Assertions.assertThat;
|
||||
|
||||
import java.io.File;
|
||||
import java.io.Serializable;
|
||||
import java.net.URISyntaxException;
|
||||
import java.net.URL;
|
||||
|
||||
import org.junit.Before;
|
||||
import org.junit.Rule;
|
||||
import org.junit.Test;
|
||||
import org.junit.rules.ExpectedException;
|
||||
|
||||
import de.kosit.validationtool.model.scenarios.Scenarios;
|
||||
|
||||
/**
|
||||
* Simple test for testing the jaxb conversion service.
|
||||
*
|
||||
* @author apenski
|
||||
*/
|
||||
public class ConversionServiceTest {
|
||||
|
||||
private static final URL VALID_XML = ConversionServiceTest.class.getResource("/valid/scenarios.xml");
|
||||
|
||||
private static final URL INVALID_XML = ConversionServiceTest.class.getResource("/invalid/scenarios-invalid.xml");
|
||||
|
||||
private static final URL ILLFORMED_XML = ConversionServiceTest.class.getResource("/invalid/scenarios-illformed.xml");
|
||||
|
||||
private static final URL SCHEMA = ConversionServiceTest.class.getResource("/xsd/scenarios.xsd");
|
||||
|
||||
@Rule
|
||||
public ExpectedException exception = ExpectedException.none();
|
||||
|
||||
private ConversionService service;
|
||||
|
||||
private ContentRepository repository;
|
||||
|
||||
@Before
|
||||
public void setup() {
|
||||
service = new ConversionService();
|
||||
repository = new ContentRepository(ObjectFactory.createProcessor(), new File("src/test/resources/examples/repository").toURI());
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testMarshalNull() {
|
||||
exception.expect(ConversionService.ConversionExeption.class);
|
||||
service.writeXml(null);
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testMarshalUnknown() {
|
||||
exception.expect(ConversionService.ConversionExeption.class);
|
||||
service.writeXml(new Serializable() {
|
||||
});
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testUnmarshal() throws URISyntaxException {
|
||||
final Scenarios s = service.readXml(VALID_XML.toURI(), Scenarios.class);
|
||||
assertThat(s).isNotNull();
|
||||
assertThat(s.getName()).isEqualToIgnoringCase("XInneres");
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testUnmarshalWithSchema() throws URISyntaxException {
|
||||
final Scenarios s = service.readXml(VALID_XML.toURI(), Scenarios.class, repository.createSchema(SCHEMA));
|
||||
assertThat(s).isNotNull();
|
||||
assertThat(s.getName()).isEqualToIgnoringCase("XInneres");
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testUnmarshalInvalidXml() throws URISyntaxException {
|
||||
exception.expect(ConversionService.ConversionExeption.class);
|
||||
service.readXml(INVALID_XML.toURI(), Scenarios.class, repository.createSchema(SCHEMA));
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testUnmarshalIllFormed() throws URISyntaxException {
|
||||
exception.expect(ConversionService.ConversionExeption.class);
|
||||
service.readXml(ILLFORMED_XML.toURI(), Scenarios.class, repository.createSchema(SCHEMA));
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testUnmarshalEmpty() {
|
||||
exception.expect(ConversionService.ConversionExeption.class);
|
||||
service.readXml(null, Scenarios.class);
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testUnmarshalUnknownType() throws URISyntaxException {
|
||||
exception.expect(ConversionService.ConversionExeption.class);
|
||||
service.readXml(VALID_XML.toURI(), ConversionService.class);
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testUnmarshalWithoutType() throws URISyntaxException {
|
||||
exception.expect(ConversionService.ConversionExeption.class);
|
||||
service.readXml(VALID_XML.toURI(), null);
|
||||
}
|
||||
|
||||
}
|
||||
|
|
@ -0,0 +1,75 @@
|
|||
/*
|
||||
* Licensed to the Koordinierungsstelle für IT-Standards (KoSIT) under
|
||||
* one or more contributor license agreements. See the NOTICE file
|
||||
* distributed with this work for additional information
|
||||
* regarding copyright ownership. KoSIT licenses this file
|
||||
* to you under the Apache License, Version 2.0 (the
|
||||
* "License"); you may not use this file except in compliance
|
||||
* with the License. You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing,
|
||||
* software distributed under the License is distributed on an
|
||||
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||
* KIND, either express or implied. See the License for the
|
||||
* specific language governing permissions and limitations
|
||||
* under the License.
|
||||
*/
|
||||
|
||||
package de.kosit.validationtool.impl;
|
||||
|
||||
import de.kosit.validationtool.api.CheckConfiguration;
|
||||
import de.kosit.validationtool.api.Input;
|
||||
import org.junit.Before;
|
||||
import org.junit.Test;
|
||||
import org.w3c.dom.Document;
|
||||
|
||||
import java.io.File;
|
||||
import java.net.URISyntaxException;
|
||||
import java.net.URL;
|
||||
import java.util.List;
|
||||
import java.util.stream.Collectors;
|
||||
import java.util.stream.IntStream;
|
||||
|
||||
import static de.kosit.validationtool.api.InputFactory.read;
|
||||
import static org.assertj.core.api.Assertions.assertThat;
|
||||
|
||||
/**
|
||||
* Test das Check-Interface
|
||||
*
|
||||
* @author Andreas Penski
|
||||
*/
|
||||
public class DefaultCheckTest {
|
||||
|
||||
private static final URL SCENARIO_DEFINITION = ScenarioRepositoryTest.class.getResource("/examples/UBLReady/scenarios-2.xml");
|
||||
|
||||
private static final URL VALID_EXAMPLE = ScenarioRepositoryTest.class
|
||||
.getResource("/examples/UBLReady/UBLReady_EU_UBL-NL_20170102_FULL.xml");
|
||||
|
||||
public static final int MULTI_COUNT = 5;
|
||||
|
||||
private DefaultCheck implementation;
|
||||
|
||||
@Before
|
||||
public void setup() throws URISyntaxException {
|
||||
CheckConfiguration d = new CheckConfiguration(SCENARIO_DEFINITION.toURI());
|
||||
d.setScenarioRepository(new File("src/test/resources/examples/repository").toURI());
|
||||
implementation = new DefaultCheck(d);
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testHappyCase() throws Exception {
|
||||
final Document doc = implementation.check(read(VALID_EXAMPLE));
|
||||
assertThat(doc).isNotNull();
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testMultipleCase() throws Exception {
|
||||
final List<Input> input = IntStream.range(0, MULTI_COUNT).mapToObj(i -> read(VALID_EXAMPLE)).collect(Collectors.toList());
|
||||
final List<Document> docs = implementation.check(input);
|
||||
assertThat(docs).isNotNull();
|
||||
assertThat(docs).hasSize(MULTI_COUNT);
|
||||
}
|
||||
|
||||
}
|
||||
|
|
@ -0,0 +1,88 @@
|
|||
/*
|
||||
* Licensed to the Koordinierungsstelle für IT-Standards (KoSIT) under
|
||||
* one or more contributor license agreements. See the NOTICE file
|
||||
* distributed with this work for additional information
|
||||
* regarding copyright ownership. KoSIT licenses this file
|
||||
* to you under the Apache License, Version 2.0 (the
|
||||
* "License"); you may not use this file except in compliance
|
||||
* with the License. You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing,
|
||||
* software distributed under the License is distributed on an
|
||||
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||
* KIND, either express or implied. See the License for the
|
||||
* specific language governing permissions and limitations
|
||||
* under the License.
|
||||
*/
|
||||
|
||||
package de.kosit.validationtool.impl;
|
||||
|
||||
import static de.kosit.validationtool.api.InputFactory.read;
|
||||
import static org.assertj.core.api.Assertions.assertThat;
|
||||
|
||||
import java.io.IOException;
|
||||
import java.net.URL;
|
||||
|
||||
import org.junit.Before;
|
||||
import org.junit.Rule;
|
||||
import org.junit.Test;
|
||||
import org.junit.rules.ExpectedException;
|
||||
import org.w3c.dom.Document;
|
||||
|
||||
import de.kosit.validationtool.impl.model.Result;
|
||||
import de.kosit.validationtool.impl.tasks.DocumentParseAction;
|
||||
import de.kosit.validationtool.model.reportInput.XMLSyntaxError;
|
||||
|
||||
/**
|
||||
* @author Andreas Penski
|
||||
*/
|
||||
public class DocumentParserTest {
|
||||
|
||||
private static final URL CONTENT = ConversionServiceTest.class.getResource("/valid/scenarios.xml");
|
||||
|
||||
private static final URL ILLFORMED = ConversionServiceTest.class.getResource("/invalid/scenarios-illformed.xml");
|
||||
|
||||
private static final URL NOT_EXISTING = ConversionServiceTest.class.getResource("/does not exist.xml");
|
||||
|
||||
|
||||
|
||||
@Rule
|
||||
public ExpectedException exception = ExpectedException.none();
|
||||
|
||||
private DocumentParseAction parser;
|
||||
|
||||
@Before
|
||||
public void setup() {
|
||||
parser = new DocumentParseAction();
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testSimple() throws IOException {
|
||||
final Result<Document, XMLSyntaxError> result = parser.parseDocument(read(CONTENT));
|
||||
assertThat(result).isNotNull();
|
||||
assertThat(result.getObject()).isNotNull();
|
||||
assertThat(result.getErrors()).isEmpty();
|
||||
assertThat(result.isValid()).isTrue();
|
||||
}
|
||||
|
||||
|
||||
@Test
|
||||
public void testIllformed() throws IOException {
|
||||
final Result<Document, XMLSyntaxError> result = parser.parseDocument(read(ILLFORMED));
|
||||
assertThat(result).isNotNull();
|
||||
assertThat(result.getErrors()).isNotEmpty();
|
||||
assertThat(result.getObject()).isNull();
|
||||
assertThat(result.isValid()).isFalse();
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testNullInput() {
|
||||
exception.expect(IllegalArgumentException.class);
|
||||
parser.parseDocument(null);
|
||||
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
102
src/test/java/de/kosit/validationtool/impl/Helper.java
Normal file
102
src/test/java/de/kosit/validationtool/impl/Helper.java
Normal file
|
|
@ -0,0 +1,102 @@
|
|||
/*
|
||||
* Licensed to the Koordinierungsstelle für IT-Standards (KoSIT) under
|
||||
* one or more contributor license agreements. See the NOTICE file
|
||||
* distributed with this work for additional information
|
||||
* regarding copyright ownership. KoSIT licenses this file
|
||||
* to you under the Apache License, Version 2.0 (the
|
||||
* "License"); you may not use this file except in compliance
|
||||
* with the License. You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing,
|
||||
* software distributed under the License is distributed on an
|
||||
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||
* KIND, either express or implied. See the License for the
|
||||
* specific language governing permissions and limitations
|
||||
* under the License.
|
||||
*/
|
||||
|
||||
package de.kosit.validationtool.impl;
|
||||
|
||||
import java.io.File;
|
||||
import java.net.URI;
|
||||
import java.net.URISyntaxException;
|
||||
import java.net.URL;
|
||||
import java.nio.file.Paths;
|
||||
|
||||
import org.w3c.dom.Document;
|
||||
|
||||
import de.kosit.validationtool.api.InputFactory;
|
||||
import de.kosit.validationtool.impl.model.Result;
|
||||
import de.kosit.validationtool.impl.tasks.CheckAction;
|
||||
import de.kosit.validationtool.impl.tasks.DocumentParseAction;
|
||||
import de.kosit.validationtool.model.reportInput.XMLSyntaxError;
|
||||
|
||||
/**
|
||||
* Helferlein für Test-Artefakte
|
||||
*
|
||||
* @author Andreas Penski
|
||||
*/
|
||||
public class Helper {
|
||||
|
||||
public static final URI SOURCE_ROOT = Paths.get("src/main/resources").toUri();
|
||||
|
||||
public static final URI MODEL_ROOT = Paths.get("src/main/model").toUri();
|
||||
|
||||
public static final URI ASSERTION_SCHEMA = MODEL_ROOT.resolve("xsd/assertions.xsd");
|
||||
|
||||
public static final URI SCENARIO_SCHEMA = MODEL_ROOT.resolve("xsd/scenarios.xsd");
|
||||
|
||||
public static final URI TEST_ROOT = Paths.get("src/test/resources").toUri();
|
||||
|
||||
|
||||
|
||||
public static final URI EXAMPLES_DIR = TEST_ROOT.resolve("examples/");
|
||||
public static final URI ASSERTIONS = EXAMPLES_DIR.resolve("assertions/tests-xrechnung.xml");
|
||||
|
||||
public static final URI SCENARIO_FILE = EXAMPLES_DIR.resolve("UBLReady/scenarios-2.xml");
|
||||
|
||||
|
||||
public static final URI REPOSITORY = EXAMPLES_DIR.resolve("repository/");
|
||||
|
||||
public static final URI NOT_EXISTING = EXAMPLES_DIR.resolve("doesnotexist");
|
||||
|
||||
public static final URI SAMPLE_DIR = EXAMPLES_DIR.resolve("UBLReady/");
|
||||
public static final URI SAMPLE_XSLT = EXAMPLES_DIR.resolve("repository/resources/eRechnung/report.xsl");
|
||||
public static final URI SAMPLE = SAMPLE_DIR.resolve("UBLReady_EU_UBL-NL_20170102_FULL.xml");
|
||||
|
||||
public static final URI SAMPLE2 = SAMPLE_DIR.resolve("UBLReady_EU_UBL-NL_20170102_FULL-invalid.xml");
|
||||
|
||||
|
||||
/**
|
||||
* Lädt ein XML-Dokument von der gegebenen URL
|
||||
*
|
||||
* @param url die url die geladen werden soll
|
||||
* @return ein result objekt mit Dokument
|
||||
*/
|
||||
public static Result<Document, XMLSyntaxError> load(URL url) {
|
||||
DocumentParseAction a = new DocumentParseAction();
|
||||
CheckAction.Bag b = new CheckAction.Bag(InputFactory.read(url));
|
||||
a.check(b);
|
||||
return b.getParserResult();
|
||||
}
|
||||
|
||||
public static <T> T load(URL url, Class<T> type) throws URISyntaxException {
|
||||
ConversionService c = new ConversionService();
|
||||
c.initialize(de.kosit.validationtool.model.reportInput.ObjectFactory.class.getPackage(),
|
||||
de.kosit.validationtool.cmd.assertions.ObjectFactory.class.getPackage(),
|
||||
de.kosit.validationtool.model.scenarios.ObjectFactory.class.getPackage());
|
||||
return c.readXml(url.toURI(), type);
|
||||
}
|
||||
|
||||
/**
|
||||
* Lädt das default test repository mit Artefacten für Unit-Tests
|
||||
*
|
||||
* @return ein {@link ContentRepository}
|
||||
*/
|
||||
public static ContentRepository loadTestRepository() {
|
||||
return new ContentRepository(ObjectFactory.createProcessor(), new File("src/test/resources/examples/repository").toURI());
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -0,0 +1,74 @@
|
|||
/*
|
||||
* Licensed to the Koordinierungsstelle für IT-Standards (KoSIT) under
|
||||
* one or more contributor license agreements. See the NOTICE file
|
||||
* distributed with this work for additional information
|
||||
* regarding copyright ownership. KoSIT licenses this file
|
||||
* to you under the Apache License, Version 2.0 (the
|
||||
* "License"); you may not use this file except in compliance
|
||||
* with the License. You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing,
|
||||
* software distributed under the License is distributed on an
|
||||
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||
* KIND, either express or implied. See the License for the
|
||||
* specific language governing permissions and limitations
|
||||
* under the License.
|
||||
*/
|
||||
|
||||
package de.kosit.validationtool.impl;
|
||||
|
||||
import static org.assertj.core.api.Assertions.assertThat;
|
||||
|
||||
import java.net.URI;
|
||||
import java.net.URISyntaxException;
|
||||
|
||||
import javax.xml.transform.Source;
|
||||
import javax.xml.transform.TransformerException;
|
||||
import javax.xml.transform.URIResolver;
|
||||
|
||||
import org.junit.Rule;
|
||||
import org.junit.Test;
|
||||
import org.junit.rules.ExpectedException;
|
||||
|
||||
/**
|
||||
* Testet den Uri-Resolver der relative auflösen soll
|
||||
*
|
||||
* @author Andreas Penski
|
||||
*/
|
||||
public class RelativeUriResolverTest {
|
||||
|
||||
private static final URI BASE;
|
||||
|
||||
static {
|
||||
try {
|
||||
BASE = RelativeUriResolver.class.getResource("/examples/assertions/").toURI();
|
||||
} catch (URISyntaxException e) {
|
||||
throw new IllegalStateException(e);
|
||||
}
|
||||
}
|
||||
|
||||
@Rule
|
||||
public ExpectedException exception = ExpectedException.none();
|
||||
|
||||
private URIResolver resolver = new RelativeUriResolver(BASE);
|
||||
|
||||
@Test
|
||||
public void testSucces() throws TransformerException {
|
||||
final Source resource = resolver.resolve("ubl-0001.xml", BASE.toASCIIString());
|
||||
assertThat(resource).isNotNull();
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testNotExisting() throws TransformerException {
|
||||
exception.expect(IllegalStateException.class);
|
||||
resolver.resolve("ubl-0001", BASE.toASCIIString());
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testOutOfPath() throws TransformerException {
|
||||
exception.expect(IllegalStateException.class);
|
||||
resolver.resolve("../results/report.xml", BASE.toASCIIString());
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,76 @@
|
|||
/*
|
||||
* Licensed to the Koordinierungsstelle für IT-Standards (KoSIT) under
|
||||
* one or more contributor license agreements. See the NOTICE file
|
||||
* distributed with this work for additional information
|
||||
* regarding copyright ownership. KoSIT licenses this file
|
||||
* to you under the Apache License, Version 2.0 (the
|
||||
* "License"); you may not use this file except in compliance
|
||||
* with the License. You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing,
|
||||
* software distributed under the License is distributed on an
|
||||
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||
* KIND, either express or implied. See the License for the
|
||||
* specific language governing permissions and limitations
|
||||
* under the License.
|
||||
*/
|
||||
|
||||
package de.kosit.validationtool.impl;
|
||||
|
||||
import static org.junit.Assert.fail;
|
||||
|
||||
import java.io.IOException;
|
||||
import java.net.URL;
|
||||
|
||||
import javax.xml.transform.dom.DOMSource;
|
||||
import javax.xml.transform.stream.StreamSource;
|
||||
|
||||
import org.apache.commons.lang3.StringUtils;
|
||||
import org.junit.Test;
|
||||
import org.w3c.dom.Document;
|
||||
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
|
||||
import net.sf.saxon.s9api.*;
|
||||
|
||||
/**
|
||||
* Testet verschiedene Saxon Security Einstellungen.
|
||||
*
|
||||
* @author Andreas Penski
|
||||
*/
|
||||
@Slf4j
|
||||
public class SaxonSecurityTest {
|
||||
|
||||
@Test
|
||||
public void testEvilStylesheets() throws IOException {
|
||||
Processor p = ObjectFactory.createProcessor();
|
||||
for (int i = 1; i <= 5; i++) {
|
||||
try {
|
||||
URL resource = SaxonSecurityTest.class.getResource(String.format("/evil/evil%s.xsl", i));
|
||||
final XsltCompiler compiler = p.newXsltCompiler();
|
||||
final RelativeUriResolver resolver = new RelativeUriResolver(Helper.REPOSITORY);
|
||||
compiler.setURIResolver(resolver);
|
||||
final XsltExecutable exetuable = compiler.compile(new StreamSource(resource.openStream()));
|
||||
final XsltTransformer transformer = exetuable.load();
|
||||
final Document document = ObjectFactory.createDocumentBuilder(false).newDocument();
|
||||
document.createElement("root");
|
||||
Document result = ObjectFactory.createDocumentBuilder(false).newDocument();
|
||||
transformer.getUnderlyingController().setUnparsedTextURIResolver(resolver);
|
||||
transformer.setURIResolver(resolver);
|
||||
transformer.setSource(new DOMSource(document));
|
||||
transformer.setDestination(new DOMDestination(result));
|
||||
transformer.transform();
|
||||
|
||||
// wenn der Punkt erreicht wird, sollte wenigstens, das Element evil nicht mit 'bösen' Inhalten gefüllt sein!
|
||||
if (StringUtils.isNotBlank(result.getDocumentElement().getTextContent())) {
|
||||
fail(String.format("Saxon configuration should prevent expansion within %s", resource));
|
||||
}
|
||||
|
||||
} catch (SaxonApiException | RuntimeException e) {
|
||||
log.info("Expected exception detected", e.getMessage());
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,101 @@
|
|||
/*
|
||||
* Licensed to the Koordinierungsstelle für IT-Standards (KoSIT) under
|
||||
* one or more contributor license agreements. See the NOTICE file
|
||||
* distributed with this work for additional information
|
||||
* regarding copyright ownership. KoSIT licenses this file
|
||||
* to you under the Apache License, Version 2.0 (the
|
||||
* "License"); you may not use this file except in compliance
|
||||
* with the License. You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing,
|
||||
* software distributed under the License is distributed on an
|
||||
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||
* KIND, either express or implied. See the License for the
|
||||
* specific language governing permissions and limitations
|
||||
* under the License.
|
||||
*/
|
||||
|
||||
package de.kosit.validationtool.impl;
|
||||
|
||||
import static de.kosit.validationtool.api.InputFactory.read;
|
||||
import static org.assertj.core.api.Assertions.assertThat;
|
||||
|
||||
import java.io.File;
|
||||
import java.io.IOException;
|
||||
import java.net.URL;
|
||||
|
||||
import org.junit.Before;
|
||||
import org.junit.Rule;
|
||||
import org.junit.Test;
|
||||
import org.junit.rules.ExpectedException;
|
||||
import org.w3c.dom.Document;
|
||||
|
||||
import de.kosit.validationtool.impl.model.Result;
|
||||
import de.kosit.validationtool.impl.tasks.DocumentParseAction;
|
||||
import de.kosit.validationtool.model.scenarios.ScenarioType;
|
||||
import de.kosit.validationtool.model.scenarios.Scenarios;
|
||||
|
||||
/**
|
||||
* Testet das {@link ScenarioRepository}.
|
||||
*
|
||||
* @author Andreas Penski
|
||||
*/
|
||||
|
||||
public class ScenarioRepositoryTest {
|
||||
|
||||
private static final URL SAMPLE = ScenarioRepositoryTest.class.getResource("/valid/scenarios.xml");
|
||||
|
||||
@Rule
|
||||
public ExpectedException expectedException = ExpectedException.none();
|
||||
|
||||
ContentRepository content;
|
||||
|
||||
private ScenarioRepository repository;
|
||||
|
||||
@Before
|
||||
public void setup() {
|
||||
content = new ContentRepository(ObjectFactory.createProcessor(), new File("src/test/resources/examples/repository").toURI());
|
||||
Scenarios def = new Scenarios();
|
||||
ScenarioType t = new ScenarioType();
|
||||
t.setMatch("//*:name");
|
||||
t.setName("Test");
|
||||
t.initialize(content, true);
|
||||
def.getScenario().add(t);
|
||||
repository = new ScenarioRepository(ObjectFactory.createProcessor(), content);
|
||||
repository.initialize(def);
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testHappyCase() throws Exception {
|
||||
final Result<ScenarioType, String> scenario = repository.selectScenario(load(SAMPLE));
|
||||
assertThat(scenario).isNotNull();
|
||||
assertThat(scenario.isValid()).isTrue();
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testNonMatch() throws Exception {
|
||||
repository.getScenarios().getScenario().clear();
|
||||
final Result<ScenarioType, String> scenario = repository.selectScenario(load(SAMPLE));
|
||||
assertThat(scenario).isNotNull();
|
||||
assertThat(scenario.isValid()).isFalse();
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testMultiMatch() throws Exception {
|
||||
ScenarioType t = new ScenarioType();
|
||||
t.setMatch("//*:name");
|
||||
t.setName("Test");
|
||||
t.initialize(content, true);
|
||||
repository.getScenarios().getScenario().add(t);
|
||||
final Result<ScenarioType, String> scenario = repository.selectScenario(load(SAMPLE));
|
||||
assertThat(scenario).isNotNull();
|
||||
assertThat(scenario.isValid()).isFalse();
|
||||
}
|
||||
|
||||
private Document load(URL url) throws IOException {
|
||||
DocumentParseAction p = new DocumentParseAction();
|
||||
return p.parseDocument(read(url)).getObject();
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,115 @@
|
|||
/*
|
||||
* Licensed to the Koordinierungsstelle für IT-Standards (KoSIT) under
|
||||
* one or more contributor license agreements. See the NOTICE file
|
||||
* distributed with this work for additional information
|
||||
* regarding copyright ownership. KoSIT licenses this file
|
||||
* to you under the Apache License, Version 2.0 (the
|
||||
* "License"); you may not use this file except in compliance
|
||||
* with the License. You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing,
|
||||
* software distributed under the License is distributed on an
|
||||
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||
* KIND, either express or implied. See the License for the
|
||||
* specific language governing permissions and limitations
|
||||
* under the License.
|
||||
*/
|
||||
|
||||
package de.kosit.validationtool.impl;
|
||||
|
||||
import static org.assertj.core.api.Assertions.assertThat;
|
||||
|
||||
import java.net.MalformedURLException;
|
||||
import java.net.URI;
|
||||
import java.net.URL;
|
||||
import java.util.Collections;
|
||||
|
||||
import javax.xml.validation.Schema;
|
||||
|
||||
import org.junit.Before;
|
||||
import org.junit.Test;
|
||||
import org.junit.rules.ExpectedException;
|
||||
|
||||
import de.kosit.validationtool.api.InputFactory;
|
||||
import de.kosit.validationtool.impl.model.Result;
|
||||
import de.kosit.validationtool.impl.tasks.CheckAction;
|
||||
import de.kosit.validationtool.impl.tasks.SchemaValidationAction;
|
||||
import de.kosit.validationtool.model.reportInput.CreateReportInput;
|
||||
import de.kosit.validationtool.model.scenarios.ResourceType;
|
||||
import de.kosit.validationtool.model.scenarios.ScenarioType;
|
||||
import de.kosit.validationtool.model.scenarios.ValidateWithXmlSchema;
|
||||
|
||||
/**
|
||||
* Testet die {@linkSchemaValidatorAction}.
|
||||
*
|
||||
* @author Andreas Penski
|
||||
*/
|
||||
public class SchemaValidatorActionTest {
|
||||
|
||||
private static final URL VALID_EXAMPLE = SchemaValidatorActionTest.class
|
||||
.getResource("/examples/UBLReady/UBLReady_EU_UBL-NL_20170102_FULL.xml");
|
||||
|
||||
private static final URI INVALID_EXAMPLE = Helper.TEST_ROOT.resolve("invalid/scenarios-invalid.xml");
|
||||
|
||||
public ExpectedException expectedException = ExpectedException.none();
|
||||
|
||||
private SchemaValidationAction service;
|
||||
|
||||
private ContentRepository repository;
|
||||
|
||||
@Before
|
||||
public void setup() {
|
||||
service = new SchemaValidationAction();
|
||||
repository = new ContentRepository(ObjectFactory.createProcessor(), Helper.REPOSITORY);
|
||||
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testSimple() {
|
||||
CheckAction.Bag bag = new CheckAction.Bag(InputFactory.read(VALID_EXAMPLE), new CreateReportInput());
|
||||
bag.setParserResult(Helper.load(VALID_EXAMPLE));
|
||||
ScenarioType t = new ScenarioType();
|
||||
ValidateWithXmlSchema v = new ValidateWithXmlSchema();
|
||||
ResourceType r = new ResourceType();
|
||||
r.setLocation("resources/eRechnung/UBL-2.1/xsdrt/maindoc/UBL-Invoice-2.1.xsd");
|
||||
r.setName("invoice");
|
||||
v.getResource().add(r);
|
||||
t.setValidateWithXmlSchema(v);
|
||||
t.initialize(repository, true);
|
||||
bag.setScenarioSelectionResult(new Result<>(t, Collections.emptyList()));
|
||||
service.check(bag);
|
||||
assertThat(bag.getSchemaValidationResult().isValid()).isTrue();
|
||||
assertThat(bag.getSchemaValidationResult()).isNotNull();
|
||||
assertThat(bag.getSchemaValidationResult().isValid()).isTrue();
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testValidationFailure() throws MalformedURLException {
|
||||
CheckAction.Bag bag = new CheckAction.Bag(InputFactory.read(INVALID_EXAMPLE.toURL()), new CreateReportInput());
|
||||
bag.setParserResult(Helper.load(INVALID_EXAMPLE.toURL()));
|
||||
ScenarioType t = new ScenarioType();
|
||||
ValidateWithXmlSchema v = new ValidateWithXmlSchema();
|
||||
ResourceType r = new ResourceType();
|
||||
r.setLocation(Helper.REPOSITORY.relativize(Helper.SCENARIO_SCHEMA).getRawPath());
|
||||
r.setName("invoice");
|
||||
v.getResource().add(r);
|
||||
t.setValidateWithXmlSchema(v);
|
||||
t.initialize(repository, true);
|
||||
bag.setScenarioSelectionResult(new Result<>(t, Collections.emptyList()));
|
||||
service.check(bag);
|
||||
assertThat(bag.getSchemaValidationResult().isValid()).isFalse();
|
||||
bag.getSchemaValidationResult().getErrors().forEach(e->{
|
||||
assertThat(e.getRowNumber()).isGreaterThan(0);
|
||||
assertThat(e.getColumnNumber()).isGreaterThan(0);
|
||||
});
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testSchemaReferences() {
|
||||
final Schema reportInputSchema = repository.getReportInputSchema();
|
||||
assertThat(reportInputSchema).isNotNull();
|
||||
}
|
||||
|
||||
}
|
||||
|
|
@ -0,0 +1,86 @@
|
|||
/*
|
||||
* Licensed to the Koordinierungsstelle für IT-Standards (KoSIT) under
|
||||
* one or more contributor license agreements. See the NOTICE file
|
||||
* distributed with this work for additional information
|
||||
* regarding copyright ownership. KoSIT licenses this file
|
||||
* to you under the Apache License, Version 2.0 (the
|
||||
* "License"); you may not use this file except in compliance
|
||||
* with the License. You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing,
|
||||
* software distributed under the License is distributed on an
|
||||
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||
* KIND, either express or implied. See the License for the
|
||||
* specific language governing permissions and limitations
|
||||
* under the License.
|
||||
*/
|
||||
|
||||
package de.kosit.validationtool.impl;
|
||||
|
||||
import static org.assertj.core.api.Assertions.assertThat;
|
||||
|
||||
import java.io.File;
|
||||
import java.net.URISyntaxException;
|
||||
import java.net.URL;
|
||||
|
||||
import org.junit.Before;
|
||||
import org.junit.Rule;
|
||||
import org.junit.Test;
|
||||
import org.junit.rules.ExpectedException;
|
||||
|
||||
import de.kosit.validationtool.model.scenarios.Scenarios;
|
||||
|
||||
/**
|
||||
* Testet die Versionierung von Scenario-Dateien aka Konfigurationsdaten.
|
||||
*
|
||||
* @author Andreas Penski
|
||||
*/
|
||||
public class VersioningTest {
|
||||
|
||||
private static final URL BASE = VersioningTest.class.getResource("/examples/versioning/scenarios-base.xml");
|
||||
|
||||
private static final URL INCREMENT = VersioningTest.class.getResource("/examples/versioning/scenarios-increment.xml");
|
||||
|
||||
private static final URL NEW_FEATURE = VersioningTest.class.getResource("/examples/versioning/scenarios-newfeature.xml");
|
||||
|
||||
private static final URL NEW_VERSION = VersioningTest.class.getResource("/examples/versioning/scenarios-newVersion.xml");
|
||||
|
||||
@Rule
|
||||
public ExpectedException exception = ExpectedException.none();
|
||||
|
||||
private ConversionService service;
|
||||
|
||||
private ContentRepository repository;
|
||||
|
||||
@Before
|
||||
public void setup() {
|
||||
service = new ConversionService();
|
||||
repository = new ContentRepository(ObjectFactory.createProcessor(), new File("src/test/resources/examples/repository").toURI());
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testBase() throws URISyntaxException {
|
||||
final Scenarios result = service.readXml(BASE.toURI(), Scenarios.class, repository.getScenarioSchema());
|
||||
assertThat(result).isNotNull();
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testFrameworkIncrement() throws URISyntaxException {
|
||||
final Scenarios result = service.readXml(INCREMENT.toURI(), Scenarios.class, repository.getScenarioSchema());
|
||||
assertThat(result).isNotNull();
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testNewFeature() throws URISyntaxException {
|
||||
exception.expect(ConversionService.ConversionExeption.class);
|
||||
service.readXml(NEW_FEATURE.toURI(), Scenarios.class, repository.getScenarioSchema());
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testNewVersion() throws URISyntaxException {
|
||||
exception.expect(ConversionService.ConversionExeption.class);
|
||||
service.readXml(NEW_VERSION.toURI(), Scenarios.class, repository.getScenarioSchema());
|
||||
}
|
||||
}
|
||||
32
src/test/resources/evil/evil1.xsl
Normal file
32
src/test/resources/evil/evil1.xsl
Normal file
|
|
@ -0,0 +1,32 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!--
|
||||
~ Licensed to the Koordinierungsstelle für IT-Standards (KoSIT) under
|
||||
~ one or more contributor license agreements. See the NOTICE file
|
||||
~ distributed with this work for additional information
|
||||
~ regarding copyright ownership. KoSIT licenses this file
|
||||
~ to you under the Apache License, Version 2.0 (the
|
||||
~ "License"); you may not use this file except in compliance
|
||||
~ with the License. You may obtain a copy of the License at
|
||||
~
|
||||
~ http://www.apache.org/licenses/LICENSE-2.0
|
||||
~
|
||||
~ Unless required by applicable law or agreed to in writing,
|
||||
~ software distributed under the License is distributed on an
|
||||
~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||
~ KIND, either express or implied. See the License for the
|
||||
~ specific language governing permissions and limitations
|
||||
~ under the License.
|
||||
-->
|
||||
|
||||
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
|
||||
xmlns:xs="http://www.w3.org/2001/XMLSchema"
|
||||
exclude-result-prefixes="xs"
|
||||
version="2.0">
|
||||
|
||||
<xsl:template match="/">
|
||||
<xsl:result-document href="ref.xml">
|
||||
<evil-content/>
|
||||
</xsl:result-document>
|
||||
</xsl:template>
|
||||
|
||||
</xsl:stylesheet>
|
||||
30
src/test/resources/evil/evil2.xsl
Normal file
30
src/test/resources/evil/evil2.xsl
Normal file
|
|
@ -0,0 +1,30 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!--
|
||||
~ Licensed to the Koordinierungsstelle für IT-Standards (KoSIT) under
|
||||
~ one or more contributor license agreements. See the NOTICE file
|
||||
~ distributed with this work for additional information
|
||||
~ regarding copyright ownership. KoSIT licenses this file
|
||||
~ to you under the Apache License, Version 2.0 (the
|
||||
~ "License"); you may not use this file except in compliance
|
||||
~ with the License. You may obtain a copy of the License at
|
||||
~
|
||||
~ http://www.apache.org/licenses/LICENSE-2.0
|
||||
~
|
||||
~ Unless required by applicable law or agreed to in writing,
|
||||
~ software distributed under the License is distributed on an
|
||||
~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||
~ KIND, either express or implied. See the License for the
|
||||
~ specific language governing permissions and limitations
|
||||
~ under the License.
|
||||
-->
|
||||
|
||||
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
|
||||
xmlns:xs="http://www.w3.org/2001/XMLSchema"
|
||||
exclude-result-prefixes="xs"
|
||||
version="2.0">
|
||||
|
||||
<xsl:template match="/">
|
||||
<evil-content><xsl:value-of select="document('http://google.de')"/></evil-content>
|
||||
</xsl:template>
|
||||
|
||||
</xsl:stylesheet>
|
||||
13
src/test/resources/evil/evil3.xsl
Normal file
13
src/test/resources/evil/evil3.xsl
Normal file
|
|
@ -0,0 +1,13 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
|
||||
xmlns:xs="http://www.w3.org/2001/XMLSchema"
|
||||
exclude-result-prefixes="xs"
|
||||
version="2.0">
|
||||
|
||||
<xsl:include href="www.evil.de/xsl.xsl"/>
|
||||
|
||||
<xsl:template match="/">
|
||||
<evil-content/>
|
||||
</xsl:template>
|
||||
|
||||
</xsl:stylesheet>
|
||||
14
src/test/resources/evil/evil4.xsl
Normal file
14
src/test/resources/evil/evil4.xsl
Normal file
|
|
@ -0,0 +1,14 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
|
||||
xmlns:xs="http://www.w3.org/2001/XMLSchema"
|
||||
exclude-result-prefixes="xs"
|
||||
version="2.0">
|
||||
|
||||
<!-- Absoluter Pfad, sicherlich nicht unterhalb von -r -->
|
||||
<xsl:include href="file://c/temp/myfile.txt"/>
|
||||
|
||||
<xsl:template match="/">
|
||||
<evil-content/>
|
||||
</xsl:template>
|
||||
|
||||
</xsl:stylesheet>
|
||||
33
src/test/resources/evil/evil5.xsl
Normal file
33
src/test/resources/evil/evil5.xsl
Normal file
|
|
@ -0,0 +1,33 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!--
|
||||
~ Licensed to the Koordinierungsstelle für IT-Standards (KoSIT) under
|
||||
~ one or more contributor license agreements. See the NOTICE file
|
||||
~ distributed with this work for additional information
|
||||
~ regarding copyright ownership. KoSIT licenses this file
|
||||
~ to you under the Apache License, Version 2.0 (the
|
||||
~ "License"); you may not use this file except in compliance
|
||||
~ with the License. You may obtain a copy of the License at
|
||||
~
|
||||
~ http://www.apache.org/licenses/LICENSE-2.0
|
||||
~
|
||||
~ Unless required by applicable law or agreed to in writing,
|
||||
~ software distributed under the License is distributed on an
|
||||
~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||
~ KIND, either express or implied. See the License for the
|
||||
~ specific language governing permissions and limitations
|
||||
~ under the License.
|
||||
-->
|
||||
|
||||
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
|
||||
xmlns:xs="http://www.w3.org/2001/XMLSchema"
|
||||
exclude-result-prefixes="xs"
|
||||
version="2.0">
|
||||
|
||||
|
||||
<xsl:template match="/">
|
||||
<evil-content>
|
||||
<xsl:value-of select="unparsed-text('src/test/resources/evil/ref.txt')"/>
|
||||
</evil-content>
|
||||
</xsl:template>
|
||||
|
||||
</xsl:stylesheet>
|
||||
1
src/test/resources/evil/ref.txt
Normal file
1
src/test/resources/evil/ref.txt
Normal file
|
|
@ -0,0 +1 @@
|
|||
this content should not appear in
|
||||
|
|
@ -0,0 +1,301 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!--
|
||||
~ Licensed to the Koordinierungsstelle für IT-Standards (KoSIT) under
|
||||
~ one or more contributor license agreements. See the NOTICE file
|
||||
~ distributed with this work for additional information
|
||||
~ regarding copyright ownership. KoSIT licenses this file
|
||||
~ to you under the Apache License, Version 2.0 (the
|
||||
~ "License"); you may not use this file except in compliance
|
||||
~ with the License. You may obtain a copy of the License at
|
||||
~
|
||||
~ http://www.apache.org/licenses/LICENSE-2.0
|
||||
~
|
||||
~ Unless required by applicable law or agreed to in writing,
|
||||
~ software distributed under the License is distributed on an
|
||||
~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||
~ KIND, either express or implied. See the License for the
|
||||
~ specific language governing permissions and limitations
|
||||
~ under the License.
|
||||
-->
|
||||
|
||||
<!-- FROM http://www.softwarepakket.nl/upload/ublketentest/voorbeelden/referentiefactuur/UBLReady_EU_UBL-NL_20170102.xml
|
||||
VIA https://www.xml.com/news/2017-06-ublpdf-demo-invoices/
|
||||
-->
|
||||
<Invoice xmlns:cac="urn:oasis:names:specification:ubl:schema:xsd:CommonAggregateComponents-2"
|
||||
xmlns:cbc="urn:oasis:names:specification:ubl:schema:xsd:CommonBasicComponents-2"
|
||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||
xmlns="urn:oasis:names:specification:ubl:schema:xsd:Invoice-2"
|
||||
xsi:schemaLocation="urn:oasis:names:specification:ubl:schema:xsd:Invoice-2
|
||||
http://docs.oasis-open.org/ubl/os-UBL-2.1/xsd/maindoc/UBL-Invoice-2.1.xsd">
|
||||
|
||||
<cbc:CustomizationID>urn:cen.eu:en16931:2017</cbc:CustomizationID>
|
||||
|
||||
<cbc:ProfileID>urn:www.cenbii.eu:profile:bii04:ver2.0</cbc:ProfileID>
|
||||
|
||||
<cbc:ID>20170102</cbc:ID>
|
||||
<cbc:IssueDate>2017-02-16</cbc:IssueDate>
|
||||
<cbc:DueDate>2017-03-18</cbc:DueDate>
|
||||
<cbc:InvoiceTypeCode listID="UNCL1001" listAgencyID="6">380</cbc:InvoiceTypeCode>
|
||||
<cbc:TaxPointDate>2017-02-16</cbc:TaxPointDate>
|
||||
<cbc:DocumentCurrencyCode listID="ISO 4217 Alpha" listAgencyID="6"
|
||||
>EUR
|
||||
</cbc:DocumentCurrencyCode>
|
||||
<cbc:AccountingCost>RK20172013</cbc:AccountingCost>
|
||||
<cac:InvoicePeriod>
|
||||
<cbc:StartDate>2017-02-14</cbc:StartDate>
|
||||
<cbc:EndDate>2017-02-14</cbc:EndDate>
|
||||
</cac:InvoicePeriod>
|
||||
|
||||
<cac:OrderReference>
|
||||
<cbc:ID>20170205</cbc:ID>
|
||||
</cac:OrderReference>
|
||||
|
||||
<cac:AccountingSupplierParty>
|
||||
<cac:Party>
|
||||
<cac:BigPartyName>
|
||||
<cbc:Name>UBL Platform</cbc:Name>
|
||||
</cac:BigPartyName>
|
||||
<cac:PostalAddress>
|
||||
<cbc:StreetName>Readystreet 9a</cbc:StreetName>
|
||||
<cbc:CityName>Amsterdam</cbc:CityName>
|
||||
<cbc:PostalZone>9876 YZ</cbc:PostalZone>
|
||||
<cac:SmallCountry>
|
||||
<cbc:IdentificationCode listID="ISO3166-1:Alpha2" listAgencyID="6"
|
||||
>NL
|
||||
</cbc:IdentificationCode>
|
||||
</cac:SmallCountry>
|
||||
</cac:PostalAddress>
|
||||
<cac:PartyTaxScheme>
|
||||
<cbc:CompanyID schemeID="NL:VAT" schemeAgencyID="ZZZ">NL123456789B01</cbc:CompanyID>
|
||||
<cac:TaxScheme>
|
||||
<cbc:ID schemeID="UN/ECE 5153" schemeAgencyID="6">VAT</cbc:ID>
|
||||
</cac:TaxScheme>
|
||||
</cac:PartyTaxScheme>
|
||||
<cac:PartyLegalEntity>
|
||||
<cbc:RegistrationName>UBL Ketentest BV</cbc:RegistrationName>
|
||||
<cbc:CompanyID>12345678</cbc:CompanyID>
|
||||
</cac:PartyLegalEntity>
|
||||
<cac:Contact>
|
||||
<cbc:Telephone>06 987654321</cbc:Telephone>
|
||||
<cbc:ElectronicMail>info@gbned.nl</cbc:ElectronicMail>
|
||||
</cac:Contact>
|
||||
</cac:Party>
|
||||
</cac:AccountingSupplierParty>
|
||||
|
||||
<cac:AccountingCustomerParty>
|
||||
<cac:Party>
|
||||
<cac:PartyName>
|
||||
<cbc:Name>UBL Ready</cbc:Name>
|
||||
</cac:PartyName>
|
||||
<cac:PostalAddress>
|
||||
<cbc:StreetName>Demostreet 1</cbc:StreetName>
|
||||
<cbc:CityName>Arnhem</cbc:CityName>
|
||||
<cbc:PostalZone>1234 AB</cbc:PostalZone>
|
||||
<cac:Country>
|
||||
<cbc:IdentificationCode listID="ISO3166-1:Alpha2" listAgencyID="6"
|
||||
>NL
|
||||
</cbc:IdentificationCode>
|
||||
</cac:Country>
|
||||
</cac:PostalAddress>
|
||||
|
||||
<cac:PartyLegalEntity>
|
||||
<cbc:RegistrationName>UBL Ready</cbc:RegistrationName>
|
||||
</cac:PartyLegalEntity>
|
||||
<cac:Contact>
|
||||
<cbc:Name>John Doe</cbc:Name>
|
||||
<cbc:Telephone>070-1111111</cbc:Telephone>
|
||||
<cbc:ElectronicMail>invoices@ublready.com</cbc:ElectronicMail>
|
||||
</cac:Contact>
|
||||
</cac:Party>
|
||||
</cac:AccountingCustomerParty>
|
||||
|
||||
<cac:Delivery>
|
||||
<cbc:ActualDeliveryDate>2017-02-16</cbc:ActualDeliveryDate>
|
||||
<cac:DeliveryLocation>
|
||||
<cac:Address>
|
||||
<cbc:StreetName>Stocklane 10</cbc:StreetName>
|
||||
<cbc:CityName>Arnhem</cbc:CityName>
|
||||
<cbc:PostalZone>4321 BA</cbc:PostalZone>
|
||||
<cac:Country>
|
||||
<cbc:IdentificationCode listID="ISO3166-1:Alpha2" listAgencyID="6"
|
||||
>NL
|
||||
</cbc:IdentificationCode>
|
||||
</cac:Country>
|
||||
</cac:Address>
|
||||
</cac:DeliveryLocation>
|
||||
</cac:Delivery>
|
||||
|
||||
<cac:PaymentMeans>
|
||||
<cbc:PaymentMeansCode listID="UNCL4461">31</cbc:PaymentMeansCode>
|
||||
<cac:PayeeFinancialAccount>
|
||||
<cbc:ID schemeID="IBAN">NL23ABNA0123456789</cbc:ID>
|
||||
<cac:FinancialInstitutionBranch>
|
||||
<cac:FinancialInstitution>
|
||||
<cbc:ID schemeID="BIC">ABNANL2A</cbc:ID>
|
||||
</cac:FinancialInstitution>
|
||||
</cac:FinancialInstitutionBranch>
|
||||
</cac:PayeeFinancialAccount>
|
||||
</cac:PaymentMeans>
|
||||
|
||||
<cac:PaymentTerms>
|
||||
<cbc:Note>Payments within 30 days.</cbc:Note>
|
||||
</cac:PaymentTerms>
|
||||
|
||||
<cac:AllowanceCharge>
|
||||
<cbc:ChargeIndicator>false</cbc:ChargeIndicator>
|
||||
<cbc:AllowanceChargeReasonCode listID="UNCL5189">64</cbc:AllowanceChargeReasonCode>
|
||||
<cbc:AllowanceChargeReason>Invoice allowance (VAT low 6%)</cbc:AllowanceChargeReason>
|
||||
<cbc:MultiplierFactorNumeric>1</cbc:MultiplierFactorNumeric>
|
||||
<cbc:Amount currencyID="EUR">22</cbc:Amount>
|
||||
<cbc:BaseAmount currencyID="EUR">220</cbc:BaseAmount>
|
||||
<cac:TaxCategory>
|
||||
<cbc:ID schemeID="UNCL5305">S</cbc:ID>
|
||||
<cbc:Percent>6</cbc:Percent>
|
||||
<cac:TaxScheme>
|
||||
<cbc:ID schemeID="UN/ECE 5153" schemeAgencyID="6">VAT</cbc:ID>
|
||||
</cac:TaxScheme>
|
||||
</cac:TaxCategory>
|
||||
</cac:AllowanceCharge>
|
||||
<cac:AllowanceCharge>
|
||||
<cbc:ChargeIndicator>false</cbc:ChargeIndicator>
|
||||
<cbc:AllowanceChargeReasonCode listID="UNCL5189">64</cbc:AllowanceChargeReasonCode>
|
||||
<cbc:AllowanceChargeReason>Invoice allowance (VAT high 21%)</cbc:AllowanceChargeReason>
|
||||
<cbc:MultiplierFactorNumeric>1</cbc:MultiplierFactorNumeric>
|
||||
<cbc:Amount currencyID="EUR">18</cbc:Amount>
|
||||
<cbc:BaseAmount currencyID="EUR">180</cbc:BaseAmount>
|
||||
<cac:TaxCategory>
|
||||
<cbc:ID schemeID="UNCL5305">S</cbc:ID>
|
||||
<cbc:Percent>21</cbc:Percent>
|
||||
<cac:TaxScheme>
|
||||
<cbc:ID schemeID="UN/ECE 5153" schemeAgencyID="6">VAT</cbc:ID>
|
||||
</cac:TaxScheme>
|
||||
</cac:TaxCategory>
|
||||
</cac:AllowanceCharge>
|
||||
<cac:AllowanceCharge>
|
||||
<cbc:ChargeIndicator>true</cbc:ChargeIndicator>
|
||||
<cbc:AllowanceChargeReasonCode listID="UNCL7161">ZZZ</cbc:AllowanceChargeReasonCode>
|
||||
<cbc:AllowanceChargeReason>Handling costs</cbc:AllowanceChargeReason>
|
||||
<cbc:Amount currencyID="EUR">10</cbc:Amount>
|
||||
<cac:TaxCategory>
|
||||
<cbc:ID schemeID="UNCL5305">S</cbc:ID>
|
||||
<cbc:Percent>21</cbc:Percent>
|
||||
<cac:TaxScheme>
|
||||
<cbc:ID schemeID="UN/ECE 5153" schemeAgencyID="6">VAT</cbc:ID>
|
||||
</cac:TaxScheme>
|
||||
</cac:TaxCategory>
|
||||
</cac:AllowanceCharge>
|
||||
<cac:TaxTotal>
|
||||
<cbc:TaxAmount currencyID="EUR">48.00</cbc:TaxAmount>
|
||||
<cac:TaxSubtotal>
|
||||
<cbc:TaxableAmount currencyID="EUR">198</cbc:TaxableAmount>
|
||||
<cbc:TaxAmount currencyID="EUR">11.88</cbc:TaxAmount>
|
||||
<cac:TaxCategory>
|
||||
<cbc:ID schemeID="UNCL5305">S</cbc:ID>
|
||||
<cbc:Percent>6.00</cbc:Percent>
|
||||
<cac:TaxScheme>
|
||||
<cbc:ID schemeID="UN/ECE 5153" schemeAgencyID="6">VAT</cbc:ID>
|
||||
</cac:TaxScheme>
|
||||
</cac:TaxCategory>
|
||||
</cac:TaxSubtotal>
|
||||
<cac:TaxSubtotal>
|
||||
<cbc:TaxableAmount currencyID="EUR">172</cbc:TaxableAmount>
|
||||
<cbc:TaxAmount currencyID="EUR">36.12</cbc:TaxAmount>
|
||||
<cac:TaxCategory>
|
||||
<cbc:ID schemeID="UNCL5305">S</cbc:ID>
|
||||
<cbc:Percent>21.00</cbc:Percent>
|
||||
<cac:TaxScheme>
|
||||
<cbc:ID schemeID="UN/ECE 5153" schemeAgencyID="6">VAT</cbc:ID>
|
||||
</cac:TaxScheme>
|
||||
</cac:TaxCategory>
|
||||
</cac:TaxSubtotal>
|
||||
</cac:TaxTotal>
|
||||
|
||||
<cac:LegalMonetaryTotal>
|
||||
<cbc:LineExtensionAmount currencyID="EUR">400.00</cbc:LineExtensionAmount>
|
||||
<cbc:TaxExclusiveAmount currencyID="EUR">370.00</cbc:TaxExclusiveAmount>
|
||||
<cbc:TaxInclusiveAmount currencyID="EUR">418.00</cbc:TaxInclusiveAmount>
|
||||
<cbc:AllowanceTotalAmount currencyID="EUR">40.00</cbc:AllowanceTotalAmount>
|
||||
<cbc:ChargeTotalAmount currencyID="EUR">10.00</cbc:ChargeTotalAmount>
|
||||
<cbc:PayableAmount currencyID="EUR">418.00</cbc:PayableAmount>
|
||||
</cac:LegalMonetaryTotal>
|
||||
|
||||
<cac:InvoiceLine>
|
||||
<cbc:ID>5</cbc:ID>
|
||||
<cbc:InvoicedQuantity unitCodeListID="UNECERec20" unitCode="ZZ">1.00</cbc:InvoicedQuantity>
|
||||
<cbc:LineExtensionAmount currencyID="EUR">50.00</cbc:LineExtensionAmount>
|
||||
<cac:Item>
|
||||
<cbc:Description>Book The digital highway in Holland</cbc:Description>
|
||||
<cbc:Name>The digital highway</cbc:Name>
|
||||
<cac:SellersItemIdentification>
|
||||
<cbc:ID>BK0232</cbc:ID>
|
||||
</cac:SellersItemIdentification>
|
||||
<cac:ClassifiedTaxCategory>
|
||||
<cbc:ID schemeID="UNCL5305">S</cbc:ID>
|
||||
<cbc:Percent>6.00</cbc:Percent>
|
||||
<cac:TaxScheme>
|
||||
<cbc:ID schemeID="UN/ECE 5153" schemeAgencyID="6">VAT</cbc:ID>
|
||||
</cac:TaxScheme>
|
||||
</cac:ClassifiedTaxCategory>
|
||||
</cac:Item>
|
||||
<cac:Price>
|
||||
<cbc:PriceAmount currencyID="EUR">50.00</cbc:PriceAmount>
|
||||
<cbc:BaseQuantity unitCodeListID="UNECERec20" unitCode="ZZ">1.00</cbc:BaseQuantity>
|
||||
</cac:Price>
|
||||
</cac:InvoiceLine>
|
||||
|
||||
<cac:InvoiceLine>
|
||||
<cbc:ID>10</cbc:ID>
|
||||
<cbc:InvoicedQuantity unitCodeListID="UNECERec20" unitCode="ZZ">2.00</cbc:InvoicedQuantity>
|
||||
<cbc:LineExtensionAmount currencyID="EUR">170.00</cbc:LineExtensionAmount>
|
||||
<cac:Item>
|
||||
<cbc:Description>Book Coding UBL for orders and invoices</cbc:Description>
|
||||
<cbc:Name>Coding UBL</cbc:Name>
|
||||
<cac:SellersItemIdentification>
|
||||
<cbc:ID>BK3025</cbc:ID>
|
||||
</cac:SellersItemIdentification>
|
||||
<cac:ClassifiedTaxCategory>
|
||||
<cbc:ID schemeID="UNCL5305">S</cbc:ID>
|
||||
<cbc:Percent>6.00</cbc:Percent>
|
||||
<cac:TaxScheme>
|
||||
<cbc:ID schemeID="UN/ECE 5153" schemeAgencyID="6">VAT</cbc:ID>
|
||||
</cac:TaxScheme>
|
||||
</cac:ClassifiedTaxCategory>
|
||||
</cac:Item>
|
||||
<cac:Price>
|
||||
<cbc:PriceAmount currencyID="EUR">85.00</cbc:PriceAmount>
|
||||
<cbc:BaseQuantity unitCodeListID="UNECERec20" unitCode="ZZ">2.00</cbc:BaseQuantity>
|
||||
</cac:Price>
|
||||
</cac:InvoiceLine>
|
||||
|
||||
<cac:InvoiceLine>
|
||||
<cbc:ID>15</cbc:ID>
|
||||
<cbc:InvoicedQuantity unitCodeListID="UNECERec20" unitCode="ZZ">1.00</cbc:InvoicedQuantity>
|
||||
<cbc:LineExtensionAmount currencyID="EUR">180.00</cbc:LineExtensionAmount>
|
||||
<cac:AllowanceCharge>
|
||||
<cbc:ChargeIndicator>false</cbc:ChargeIndicator>
|
||||
<cbc:AllowanceChargeReason>Price discount</cbc:AllowanceChargeReason>
|
||||
<cbc:MultiplierFactorNumeric>10</cbc:MultiplierFactorNumeric>
|
||||
<cbc:Amount currencyID="EUR">20.00</cbc:Amount>
|
||||
<cbc:BaseAmount currencyID="EUR">200</cbc:BaseAmount>
|
||||
</cac:AllowanceCharge>
|
||||
<cac:Item>
|
||||
<cbc:Description>Conversion softwarepackage to UBL</cbc:Description>
|
||||
<cbc:Name>Conversion UBL</cbc:Name>
|
||||
<cac:SellersItemIdentification>
|
||||
<cbc:ID>SW4026</cbc:ID>
|
||||
</cac:SellersItemIdentification>
|
||||
<cac:ClassifiedTaxCategory>
|
||||
<cbc:ID schemeID="UNCL5305">S</cbc:ID>
|
||||
<cbc:Percent>21.00</cbc:Percent>
|
||||
<cac:TaxScheme>
|
||||
<cbc:ID schemeID="UN/ECE 5153" schemeAgencyID="6">VAT</cbc:ID>
|
||||
</cac:TaxScheme>
|
||||
</cac:ClassifiedTaxCategory>
|
||||
</cac:Item>
|
||||
<cac:Price>
|
||||
<cbc:PriceAmount currencyID="EUR">200.00</cbc:PriceAmount>
|
||||
<cbc:BaseQuantity unitCodeListID="UNECERec20" unitCode="ZZ">1.00</cbc:BaseQuantity>
|
||||
</cac:Price>
|
||||
</cac:InvoiceLine>
|
||||
|
||||
</Invoice>
|
||||
|
|
@ -0,0 +1,302 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!--
|
||||
~ Licensed to the Koordinierungsstelle für IT-Standards (KoSIT) under
|
||||
~ one or more contributor license agreements. See the NOTICE file
|
||||
~ distributed with this work for additional information
|
||||
~ regarding copyright ownership. KoSIT licenses this file
|
||||
~ to you under the Apache License, Version 2.0 (the
|
||||
~ "License"); you may not use this file except in compliance
|
||||
~ with the License. You may obtain a copy of the License at
|
||||
~
|
||||
~ http://www.apache.org/licenses/LICENSE-2.0
|
||||
~
|
||||
~ Unless required by applicable law or agreed to in writing,
|
||||
~ software distributed under the License is distributed on an
|
||||
~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||
~ KIND, either express or implied. See the License for the
|
||||
~ specific language governing permissions and limitations
|
||||
~ under the License.
|
||||
-->
|
||||
|
||||
<!-- FROM http://www.softwarepakket.nl/upload/ublketentest/voorbeelden/referentiefactuur/UBLReady_EU_UBL-NL_20170102.xml
|
||||
VIA https://www.xml.com/news/2017-06-ublpdf-demo-invoices/
|
||||
-->
|
||||
<Invoice xmlns:cac="urn:oasis:names:specification:ubl:schema:xsd:CommonAggregateComponents-2"
|
||||
xmlns:cbc="urn:oasis:names:specification:ubl:schema:xsd:CommonBasicComponents-2"
|
||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||
xmlns="urn:oasis:names:specification:ubl:schema:xsd:Invoice-2"
|
||||
xsi:schemaLocation="urn:oasis:names:specification:ubl:schema:xsd:Invoice-2
|
||||
http://docs.oasis-open.org/ubl/os-UBL-2.1/xsd/maindoc/UBL-Invoice-2.1.xsd">
|
||||
|
||||
<cbc:CustomizationID>urn:cen.eu:en16931:2017</cbc:CustomizationID>
|
||||
|
||||
<cbc:ProfileID>urn:www.cenbii.eu:profile:bii04:ver2.0</cbc:ProfileID>
|
||||
|
||||
<cbc:ID>20170102</cbc:ID>
|
||||
<cbc:IssueDate>2017-02-16</cbc:IssueDate>
|
||||
<cbc:DueDate>2017-03-18</cbc:DueDate>
|
||||
<cbc:InvoiceTypeCode listID="UNCL1001" listAgencyID="6">380</cbc:InvoiceTypeCode>
|
||||
<cbc:TaxPointDate>2017-02-16</cbc:TaxPointDate>
|
||||
<cbc:DocumentCurrencyCode listID="ISO 4217 Alpha" listAgencyID="6"
|
||||
>EUR
|
||||
</cbc:DocumentCurrencyCode>
|
||||
<cbc:AccountingCost>RK20172013</cbc:AccountingCost>
|
||||
<cac:InvoicePeriod>
|
||||
<cbc:StartDate>2017-02-14</cbc:StartDate>
|
||||
<cbc:EndDate>2017-02-14</cbc:EndDate>
|
||||
</cac:InvoicePeriod>
|
||||
|
||||
<cac:OrderReference>
|
||||
<cbc:ID>20170205</cbc:ID>
|
||||
</cac:OrderReference>
|
||||
|
||||
<cac:AccountingSupplierParty>
|
||||
<cac:Party>
|
||||
<cac:PartyName>
|
||||
<cbc:Name>UBL Platform</cbc:Name>
|
||||
</cac:PartyName>
|
||||
<cac:PostalAddress>
|
||||
<cbc:StreetName>Readystreet 9a</cbc:StreetName>
|
||||
<cbc:CityName>Amsterdam</cbc:CityName>
|
||||
<cbc:PostalZone>9876 YZ</cbc:PostalZone>
|
||||
<cac:Country>
|
||||
<cbc:IdentificationCode listID="ISO3166-1:Alpha2" listAgencyID="6"
|
||||
>NL
|
||||
</cbc:IdentificationCode>
|
||||
</cac:Country>
|
||||
</cac:PostalAddress>
|
||||
<cac:PartyTaxScheme>
|
||||
<cbc:CompanyID schemeID="NL:VAT" schemeAgencyID="ZZZ">NL123456789B01</cbc:CompanyID>
|
||||
<cac:TaxScheme>
|
||||
<cbc:ID schemeID="UN/ECE 5153" schemeAgencyID="6">VAT</cbc:ID>
|
||||
</cac:TaxScheme>
|
||||
</cac:PartyTaxScheme>
|
||||
<cac:PartyLegalEntity>
|
||||
<cbc:RegistrationName>UBL Ketentest BV</cbc:RegistrationName>
|
||||
<cbc:CompanyID>12345678</cbc:CompanyID>
|
||||
</cac:PartyLegalEntity>
|
||||
<cac:Contact>
|
||||
<cbc:Telephone>06 987654321</cbc:Telephone>
|
||||
<cbc:ElectronicMail>info@gbned.nl</cbc:ElectronicMail>
|
||||
</cac:Contact>
|
||||
</cac:Party>
|
||||
</cac:AccountingSupplierParty>
|
||||
|
||||
<cac:AccountingCustomerParty>
|
||||
<cac:Party>
|
||||
<cac:PartyName>
|
||||
<cbc:Name>UBL Ready</cbc:Name>
|
||||
</cac:PartyName>
|
||||
<cac:PostalAddress>
|
||||
<cbc:StreetName>Demostreet 1</cbc:StreetName>
|
||||
<cbc:CityName>Arnhem</cbc:CityName>
|
||||
<cbc:PostalZone>1234 AB</cbc:PostalZone>
|
||||
<cac:Country>
|
||||
<cbc:IdentificationCode listID="ISO3166-1:Alpha2" listAgencyID="6"
|
||||
>NL
|
||||
</cbc:IdentificationCode>
|
||||
</cac:Country>
|
||||
</cac:PostalAddress>
|
||||
|
||||
<cac:PartyLegalEntity>
|
||||
<cbc:RegistrationName>UBL Ready</cbc:RegistrationName>
|
||||
</cac:PartyLegalEntity>
|
||||
<cac:Contact>
|
||||
<cbc:Name>John Doe</cbc:Name>
|
||||
<cbc:Telephone>070-1111111</cbc:Telephone>
|
||||
<cbc:ElectronicMail>invoices@ublready.com</cbc:ElectronicMail>
|
||||
</cac:Contact>
|
||||
</cac:Party>
|
||||
</cac:AccountingCustomerParty>
|
||||
|
||||
<cac:Delivery>
|
||||
<cbc:ActualDeliveryDate>2017-02-16</cbc:ActualDeliveryDate>
|
||||
<cac:DeliveryLocation>
|
||||
<cac:Address>
|
||||
<cbc:StreetName>Stocklane 10</cbc:StreetName>
|
||||
<cbc:CityName>Arnhem</cbc:CityName>
|
||||
<cbc:PostalZone>4321 BA</cbc:PostalZone>
|
||||
<cac:Country>
|
||||
<cbc:IdentificationCode listID="ISO3166-1:Alpha2" listAgencyID="6"
|
||||
>NL
|
||||
</cbc:IdentificationCode>
|
||||
</cac:Country>
|
||||
</cac:Address>
|
||||
</cac:DeliveryLocation>
|
||||
</cac:Delivery>
|
||||
|
||||
<cac:PaymentMeans>
|
||||
<cbc:PaymentMeansCode listID="UNCL4461">31</cbc:PaymentMeansCode>
|
||||
<cac:PayeeFinancialAccount>
|
||||
<cbc:ID schemeID="IBAN">NL23ABNA0123456789</cbc:ID>
|
||||
<cac:FinancialInstitutionBranch>
|
||||
<cac:FinancialInstitution>
|
||||
<cbc:ID schemeID="BIC">ABNANL2A</cbc:ID>
|
||||
</cac:FinancialInstitution>
|
||||
</cac:FinancialInstitutionBranch>
|
||||
</cac:PayeeFinancialAccount>
|
||||
</cac:PaymentMeans>
|
||||
|
||||
<cac:PaymentTerms>
|
||||
<cbc:Note>Payments within 30 days.</cbc:Note>
|
||||
</cac:PaymentTerms>
|
||||
|
||||
<cac:AllowanceCharge>
|
||||
<cbc:ChargeIndicator>false</cbc:ChargeIndicator>
|
||||
<cbc:AllowanceChargeReasonCode listID="UNCL5189">64</cbc:AllowanceChargeReasonCode>
|
||||
<cbc:AllowanceChargeReason>Invoice allowance (VAT low 6%)</cbc:AllowanceChargeReason>
|
||||
<cbc:MultiplierFactorNumeric>1</cbc:MultiplierFactorNumeric>
|
||||
<cbc:Amount currencyID="EUR">22</cbc:Amount>
|
||||
<cbc:BaseAmount currencyID="EUR">220</cbc:BaseAmount>
|
||||
<cac:TaxCategory>
|
||||
<cbc:ID schemeID="UNCL5305">S</cbc:ID>
|
||||
<cbc:Percent>6</cbc:Percent>
|
||||
<cac:TaxScheme>
|
||||
<cbc:ID schemeID="UN/ECE 5153" schemeAgencyID="6">VAT</cbc:ID>
|
||||
</cac:TaxScheme>
|
||||
</cac:TaxCategory>
|
||||
</cac:AllowanceCharge>
|
||||
<cac:AllowanceCharge>
|
||||
<cbc:ChargeIndicator>false</cbc:ChargeIndicator>
|
||||
<cbc:AllowanceChargeReasonCode listID="UNCL5189">64</cbc:AllowanceChargeReasonCode>
|
||||
<cbc:AllowanceChargeReason>Invoice allowance (VAT high 21%)</cbc:AllowanceChargeReason>
|
||||
<cbc:MultiplierFactorNumeric>1</cbc:MultiplierFactorNumeric>
|
||||
<cbc:Amount currencyID="EUR">18</cbc:Amount>
|
||||
<cbc:BaseAmount currencyID="EUR">180</cbc:BaseAmount>
|
||||
<cac:TaxCategory>
|
||||
<cbc:ID schemeID="UNCL5305">S</cbc:ID>
|
||||
<cbc:Percent>21</cbc:Percent>
|
||||
<cac:TaxScheme>
|
||||
<cbc:ID schemeID="UN/ECE 5153" schemeAgencyID="6">VAT</cbc:ID>
|
||||
</cac:TaxScheme>
|
||||
</cac:TaxCategory>
|
||||
</cac:AllowanceCharge>
|
||||
<cac:AllowanceCharge>
|
||||
<cbc:ChargeIndicator>true</cbc:ChargeIndicator>
|
||||
<cbc:AllowanceChargeReasonCode listID="UNCL7161">ZZZ</cbc:AllowanceChargeReasonCode>
|
||||
<cbc:AllowanceChargeReason>Handling costs</cbc:AllowanceChargeReason>
|
||||
<cbc:Amount currencyID="EUR">10</cbc:Amount>
|
||||
<cac:TaxCategory>
|
||||
<cbc:ID schemeID="UNCL5305">S</cbc:ID>
|
||||
<cbc:Percent>21</cbc:Percent>
|
||||
<cac:TaxScheme>
|
||||
<cbc:ID schemeID="UN/ECE 5153" schemeAgencyID="6">VAT</cbc:ID>
|
||||
</cac:TaxScheme>
|
||||
</cac:TaxCategory>
|
||||
</cac:AllowanceCharge>
|
||||
<cac:TaxTotal>
|
||||
<cbc:TaxAmount currencyID="EUR">48.00</cbc:TaxAmount>
|
||||
<cac:TaxSubtotal>
|
||||
<cbc:TaxableAmount currencyID="EUR">198</cbc:TaxableAmount>
|
||||
<cbc:TaxAmount currencyID="EUR">11.88</cbc:TaxAmount>
|
||||
<cac:TaxCategory>
|
||||
<cbc:ID schemeID="UNCL5305">S</cbc:ID>
|
||||
<cbc:Percent>6.00</cbc:Percent>
|
||||
<cac:TaxScheme>
|
||||
<cbc:ID schemeID="UN/ECE 5153" schemeAgencyID="6">VAT</cbc:ID>
|
||||
</cac:TaxScheme>
|
||||
</cac:TaxCategory>
|
||||
</cac:TaxSubtotal>
|
||||
<cac:TaxSubtotal>
|
||||
<cbc:TaxableAmount currencyID="EUR">172</cbc:TaxableAmount>
|
||||
<cbc:TaxAmount currencyID="EUR">36.12</cbc:TaxAmount>
|
||||
<cac:TaxCategory>
|
||||
<cbc:ID schemeID="UNCL5305">S</cbc:ID>
|
||||
<cbc:Percent>21.00</cbc:Percent>
|
||||
<cac:TaxScheme>
|
||||
<cbc:ID schemeID="UN/ECE 5153" schemeAgencyID="6">VAT</cbc:ID>
|
||||
</cac:TaxScheme>
|
||||
</cac:TaxCategory>
|
||||
</cac:TaxSubtotal>
|
||||
</cac:TaxTotal>
|
||||
|
||||
<cac:LegalMonetaryTotal>
|
||||
<cbc:LineExtensionAmount currencyID="EUR">400.00</cbc:LineExtensionAmount>
|
||||
<cbc:TaxExclusiveAmount currencyID="EUR">370.00</cbc:TaxExclusiveAmount>
|
||||
<cbc:TaxInclusiveAmount currencyID="EUR">418.00</cbc:TaxInclusiveAmount>
|
||||
<cbc:AllowanceTotalAmount currencyID="EUR">40.00</cbc:AllowanceTotalAmount>
|
||||
<cbc:ChargeTotalAmount currencyID="EUR">10.00</cbc:ChargeTotalAmount>
|
||||
<cbc:PayableAmount currencyID="EUR">418.00</cbc:PayableAmount>
|
||||
</cac:LegalMonetaryTotal>
|
||||
|
||||
<cac:InvoiceLine>
|
||||
<cbc:ID>5</cbc:ID>
|
||||
<cbc:InvoicedQuantity unitCodeListID="UNECERec20" unitCode="ZZ">1.00</cbc:InvoicedQuantity>
|
||||
<cbc:LineExtensionAmount currencyID="EUR">50.00</cbc:LineExtensionAmount>
|
||||
<cac:Item>
|
||||
<cbc:Description>Book The digital highway in Holland</cbc:Description>
|
||||
<cbc:Name>The digital highway</cbc:Name>
|
||||
<cac:SellersItemIdentification>
|
||||
<cbc:ID>BK0232</cbc:ID>
|
||||
</cac:SellersItemIdentification>
|
||||
<cac:ClassifiedTaxCategory>
|
||||
<cbc:ID schemeID="UNCL5305">S</cbc:ID>
|
||||
<cbc:Percent>6.00</cbc:Percent>
|
||||
<cac:TaxScheme>
|
||||
<cbc:ID schemeID="UN/ECE 5153" schemeAgencyID="6">VAT</cbc:ID>
|
||||
</cac:TaxScheme>
|
||||
</cac:ClassifiedTaxCategory>
|
||||
</cac:Item>
|
||||
<cac:Price>
|
||||
<cbc:PriceAmount currencyID="EUR">50.00</cbc:PriceAmount>
|
||||
<cbc:BaseQuantity unitCodeListID="UNECERec20" unitCode="ZZ">1.00</cbc:BaseQuantity>
|
||||
</cac:Price>
|
||||
</cac:InvoiceLine>
|
||||
|
||||
<cac:InvoiceLine>
|
||||
<cbc:ID>10</cbc:ID>
|
||||
<cbc:InvoicedQuantity unitCodeListID="UNECERec20" unitCode="ZZ">2.00</cbc:InvoicedQuantity>
|
||||
<cbc:LineExtensionAmount currencyID="EUR">170.00</cbc:LineExtensionAmount>
|
||||
<cac:Item>
|
||||
<cbc:Description>Book Coding UBL for orders and invoices</cbc:Description>
|
||||
<cbc:Name>Coding UBL</cbc:Name>
|
||||
<cac:SellersItemIdentification>
|
||||
<cbc:ID>BK3025</cbc:ID>
|
||||
</cac:SellersItemIdentification>
|
||||
<cac:ClassifiedTaxCategory>
|
||||
<cbc:ID schemeID="UNCL5305">S</cbc:ID>
|
||||
<cbc:Percent>6.00</cbc:Percent>
|
||||
<cac:TaxScheme>
|
||||
<cbc:ID schemeID="UN/ECE 5153" schemeAgencyID="6">VAT</cbc:ID>
|
||||
</cac:TaxScheme>
|
||||
</cac:ClassifiedTaxCategory>
|
||||
</cac:Item>
|
||||
<cac:Price>
|
||||
<cbc:PriceAmount currencyID="EUR">85.00</cbc:PriceAmount>
|
||||
<cbc:BaseQuantity unitCodeListID="UNECERec20" unitCode="ZZ">2.00</cbc:BaseQuantity>
|
||||
</cac:Price>
|
||||
</cac:InvoiceLine>
|
||||
|
||||
<cac:InvoiceLine>
|
||||
<cbc:ID>15</cbc:ID>
|
||||
<cbc:InvoicedQuantity unitCodeListID="UNECERec20" unitCode="ZZ">1.00</cbc:InvoicedQuantity>
|
||||
<cbc:LineExtensionAmount currencyID="EUR">180.00</cbc:LineExtensionAmount>
|
||||
<cac:AllowanceCharge>
|
||||
<cbc:ChargeIndicator>false</cbc:ChargeIndicator>
|
||||
<cbc:AllowanceChargeReason>Price discount</cbc:AllowanceChargeReason>
|
||||
<cbc:MultiplierFactorNumeric>10</cbc:MultiplierFactorNumeric>
|
||||
<cbc:Amount currencyID="EUR">20.00</cbc:Amount>
|
||||
<cbc:BaseAmount currencyID="EUR">200</cbc:BaseAmount>
|
||||
</cac:AllowanceCharge>
|
||||
<cac:Item>
|
||||
<cbc:Description>Conversion softwarepackage to UBL</cbc:Description>
|
||||
<cbc:Name>Conversion UBL</cbc:Name>
|
||||
<cac:SellersItemIdentification>
|
||||
<cbc:ID>SW4026</cbc:ID>
|
||||
</cac:SellersItemIdentification>
|
||||
<cac:ClassifiedTaxCategory>
|
||||
<cbc:ID schemeID="UNCL5305">S</cbc:ID>
|
||||
<cbc:Percent>21.00</cbc:Percent>
|
||||
<cac:TaxScheme>
|
||||
<cbc:ID schemeID="UN/ECE 5153" schemeAgencyID="6">VAT</cbc:ID>
|
||||
</cac:TaxScheme>
|
||||
</cac:ClassifiedTaxCategory>
|
||||
</cac:Item>
|
||||
<cac:Price>
|
||||
<cbc:PriceAmount currencyID="EUR">200.00</cbc:PriceAmount>
|
||||
<cbc:BaseQuantity unitCodeListID="UNECERec20" unitCode="ZZ">1.00</cbc:BaseQuantity>
|
||||
</cac:Price>
|
||||
</cac:InvoiceLine>
|
||||
|
||||
</Invoice>
|
||||
|
||||
55
src/test/resources/examples/UBLReady/scenarios-1.xml
Normal file
55
src/test/resources/examples/UBLReady/scenarios-1.xml
Normal file
|
|
@ -0,0 +1,55 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!--
|
||||
~ Licensed to the Koordinierungsstelle für IT-Standards (KoSIT) under
|
||||
~ one or more contributor license agreements. See the NOTICE file
|
||||
~ distributed with this work for additional information
|
||||
~ regarding copyright ownership. KoSIT licenses this file
|
||||
~ to you under the Apache License, Version 2.0 (the
|
||||
~ "License"); you may not use this file except in compliance
|
||||
~ with the License. You may obtain a copy of the License at
|
||||
~
|
||||
~ http://www.apache.org/licenses/LICENSE-2.0
|
||||
~
|
||||
~ Unless required by applicable law or agreed to in writing,
|
||||
~ software distributed under the License is distributed on an
|
||||
~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||
~ KIND, either express or implied. See the License for the
|
||||
~ specific language governing permissions and limitations
|
||||
~ under the License.
|
||||
-->
|
||||
|
||||
<scenarios xmlns="http://www.xoev.de/de/validator/framework/1/scenarios" frameworkVersion="1.0.0">
|
||||
<name>XInneres</name>
|
||||
<date>2017-08-08</date>
|
||||
<description>
|
||||
<p>Prüft XInneres Nachrichten anhand der von uns offiziell herausgegebenen XML Schemata und Beispielen für mögliche weitergehende Prüfungen mit Schematron. </p>
|
||||
<p>Prüft elektronische Rechnungen im Format UBL 2.1 </p>
|
||||
</description>
|
||||
|
||||
<scenario>
|
||||
<name>UBL 2.1 Invoice</name>
|
||||
<namespace prefix="invoice">urn:oasis:names:specification:ubl:schema:xsd:Invoice-2</namespace>
|
||||
<match>/invoice:Invoice</match>
|
||||
|
||||
<validateWithXmlSchema>
|
||||
<resource>
|
||||
<name>UBL 2.1 Invoice</name>
|
||||
<location>resources/eRechnung/UBL-2.1/xsdrt/maindoc/UBL-Invoice-2.1.xsd</location>
|
||||
</resource>
|
||||
</validateWithXmlSchema>
|
||||
<createReport>
|
||||
<resource>
|
||||
<name>Report für eRechnung</name>
|
||||
<!-- noch nicht vorhanden -->
|
||||
<location>does-not-exist.xsl</location>
|
||||
</resource>
|
||||
</createReport>
|
||||
</scenario>
|
||||
<noScenarioReport>
|
||||
<resource>
|
||||
<name>default</name>
|
||||
<location>resources/eRechnung/report.xsl</location>
|
||||
</resource>
|
||||
</noScenarioReport>
|
||||
|
||||
</scenarios>
|
||||
66
src/test/resources/examples/UBLReady/scenarios-2.xml
Normal file
66
src/test/resources/examples/UBLReady/scenarios-2.xml
Normal file
|
|
@ -0,0 +1,66 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!--
|
||||
~ Licensed to the Koordinierungsstelle für IT-Standards (KoSIT) under
|
||||
~ one or more contributor license agreements. See the NOTICE file
|
||||
~ distributed with this work for additional information
|
||||
~ regarding copyright ownership. KoSIT licenses this file
|
||||
~ to you under the Apache License, Version 2.0 (the
|
||||
~ "License"); you may not use this file except in compliance
|
||||
~ with the License. You may obtain a copy of the License at
|
||||
~
|
||||
~ http://www.apache.org/licenses/LICENSE-2.0
|
||||
~
|
||||
~ Unless required by applicable law or agreed to in writing,
|
||||
~ software distributed under the License is distributed on an
|
||||
~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||
~ KIND, either express or implied. See the License for the
|
||||
~ specific language governing permissions and limitations
|
||||
~ under the License.
|
||||
-->
|
||||
|
||||
<scenarios xmlns="http://www.xoev.de/de/validator/framework/1/scenarios" frameworkVersion="1.1.1">
|
||||
<name>XInneres</name>
|
||||
<date>2017-08-08</date>
|
||||
<description>
|
||||
<p>Prüft XInneres Nachrichten anhand der von uns offiziell herausgegebenen XML Schemata und Beispielen für mögliche weitergehende Prüfungen mit Schematron. </p>
|
||||
<p>Prüft elektronische Rechnungen im Format UBL 2.1 </p>
|
||||
</description>
|
||||
|
||||
<scenario>
|
||||
<name>UBL 2.1 Invoice</name>
|
||||
<namespace prefix="invoice">urn:oasis:names:specification:ubl:schema:xsd:Invoice-2</namespace>
|
||||
<match>/invoice:Invoice</match>
|
||||
|
||||
<validateWithXmlSchema>
|
||||
<resource>
|
||||
<name>UBL 2.1 Invoice</name>
|
||||
<location>resources/eRechnung/UBL-2.1/xsdrt/maindoc/UBL-Invoice-2.1.xsd</location>
|
||||
</resource>
|
||||
</validateWithXmlSchema>
|
||||
<validateWithSchematron>
|
||||
<resource>
|
||||
<name>BII Rules for Invoice</name>
|
||||
<location>resources/eRechnung/UBL-2.1/xsl/BIIRULES-UBL-T10.xsl</location>
|
||||
</resource>
|
||||
</validateWithSchematron>
|
||||
<validateWithSchematron>
|
||||
<resource>
|
||||
<name>openPEPPOL Rules for Invoice</name>
|
||||
<location>resources/eRechnung/UBL-2.1/xsl/OPENPEPPOL-UBL-T10.xsl</location>
|
||||
</resource>
|
||||
</validateWithSchematron>
|
||||
<createReport>
|
||||
<resource>
|
||||
<name>Report für eRechnung</name>
|
||||
<location>resources/eRechnung/report.xsl</location>
|
||||
</resource>
|
||||
</createReport>
|
||||
</scenario>
|
||||
<noScenarioReport>
|
||||
<resource>
|
||||
<name>default</name>
|
||||
<location>resources/eRechnung/default-report.xsl</location>
|
||||
</resource>
|
||||
</noScenarioReport>
|
||||
|
||||
</scenarios>
|
||||
45
src/test/resources/examples/assertions/tests-xrechnung.xml
Normal file
45
src/test/resources/examples/assertions/tests-xrechnung.xml
Normal file
|
|
@ -0,0 +1,45 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!--
|
||||
~ Licensed to the Koordinierungsstelle für IT-Standards (KoSIT) under
|
||||
~ one or more contributor license agreements. See the NOTICE file
|
||||
~ distributed with this work for additional information
|
||||
~ regarding copyright ownership. KoSIT licenses this file
|
||||
~ to you under the Apache License, Version 2.0 (the
|
||||
~ "License"); you may not use this file except in compliance
|
||||
~ with the License. You may obtain a copy of the License at
|
||||
~
|
||||
~ http://www.apache.org/licenses/LICENSE-2.0
|
||||
~
|
||||
~ Unless required by applicable law or agreed to in writing,
|
||||
~ software distributed under the License is distributed on an
|
||||
~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||
~ KIND, either express or implied. See the License for the
|
||||
~ specific language governing permissions and limitations
|
||||
~ under the License.
|
||||
-->
|
||||
|
||||
<assertions xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||
xmlns="http://www.xoev.de/de/validator/framework/1/assertions"
|
||||
xsi:schemaLocation="http://www.xoev.de/de/validator/framework/1/assertions file:/C:/fb/svn/xoev/produkte/prueftool/trunk/xsd/assertions.xsd">
|
||||
|
||||
<namespace prefix="rep">http://www.xoev.de/de/validator/varl/1</namespace>
|
||||
|
||||
<assertion report-doc="ubl-0001.xml" test="/rep:report/rep:scenarioMatched/rep:validationStepResult/@id = 'xsd'">
|
||||
Schema wurde validiert
|
||||
</assertion>
|
||||
<assertion report-doc="ubl-0001.xml" test="/rep:report/rep:scenarioMatched/rep:validationStepResult/@id = 'sch.1'">
|
||||
Schematron wurde validiert
|
||||
</assertion>
|
||||
<assertion report-doc="ubl-0001.xml" test="/rep:report/rep:assessment/rep:accept">Empfehlung zur Annahme</assertion>
|
||||
|
||||
<assertion report-doc="ubl-0002.xml"
|
||||
test="/rep:report/rep:scenarioMatched/rep:validationStepResult/@id = 'val-xsd'">Schema wurde validiert
|
||||
</assertion>
|
||||
<assertion report-doc="ubl-0002.xml" test="/rep:report/rep:scenarioMatched/rep:validationStepResult/@id = 'sch.1'">
|
||||
Schematron wurde validiert
|
||||
</assertion>
|
||||
<assertion report-doc="ubl-0002.xml" test="/rep:report/rep:assessment/rep:accept">Empfehlung zur Ablehnung
|
||||
</assertion>
|
||||
|
||||
|
||||
</assertions>
|
||||
3426
src/test/resources/examples/assertions/ubl-0001-report.xml
Normal file
3426
src/test/resources/examples/assertions/ubl-0001-report.xml
Normal file
File diff suppressed because it is too large
Load diff
542
src/test/resources/examples/assertions/ubl-0001.xml
Normal file
542
src/test/resources/examples/assertions/ubl-0001.xml
Normal file
|
|
@ -0,0 +1,542 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!--
|
||||
~ Licensed to the Koordinierungsstelle für IT-Standards (KoSIT) under
|
||||
~ one or more contributor license agreements. See the NOTICE file
|
||||
~ distributed with this work for additional information
|
||||
~ regarding copyright ownership. KoSIT licenses this file
|
||||
~ to you under the Apache License, Version 2.0 (the
|
||||
~ "License"); you may not use this file except in compliance
|
||||
~ with the License. You may obtain a copy of the License at
|
||||
~
|
||||
~ http://www.apache.org/licenses/LICENSE-2.0
|
||||
~
|
||||
~ Unless required by applicable law or agreed to in writing,
|
||||
~ software distributed under the License is distributed on an
|
||||
~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||
~ KIND, either express or implied. See the License for the
|
||||
~ specific language governing permissions and limitations
|
||||
~ under the License.
|
||||
-->
|
||||
|
||||
<Invoice xmlns:cac="urn:oasis:names:specification:ubl:schema:xsd:CommonAggregateComponents-2"
|
||||
xmlns:cbc="urn:oasis:names:specification:ubl:schema:xsd:CommonBasicComponents-2"
|
||||
xmlns="urn:oasis:names:specification:ubl:schema:xsd:Invoice-2">
|
||||
<cbc:CustomizationID>urn:cen.eu:en16931:2017</cbc:CustomizationID>
|
||||
<cbc:ID>12115118</cbc:ID>
|
||||
<cbc:IssueDate>2015-01-09</cbc:IssueDate>
|
||||
<cbc:DueDate>2015-01-09</cbc:DueDate>
|
||||
<cbc:InvoiceTypeCode>380</cbc:InvoiceTypeCode>
|
||||
<cbc:Note>Alle leveringen zijn franco. Alle prijzen zijn incl. BTW. Betalingstermijn: 14 dagen netto.
|
||||
Prijswijzigingen voorbehouden. Op al onze aanbiedingen, leveringen en overeenkomsten zijn van toepassing in de
|
||||
algemene verkoop en leveringsvoorwaarden. Gedeponeerd bij de K.v.K. te Amsterdam 25-04-'85##Delivery terms
|
||||
</cbc:Note>
|
||||
<cbc:DocumentCurrencyCode>EUR</cbc:DocumentCurrencyCode>
|
||||
<cac:AccountingSupplierParty>
|
||||
<cac:Party>
|
||||
<cac:PostalAddress>
|
||||
<cbc:StreetName>Postbus 7l</cbc:StreetName>
|
||||
<cbc:CityName>Velsen-Noord</cbc:CityName>
|
||||
<cbc:PostalZone>1950 AB</cbc:PostalZone>
|
||||
<cac:Country>
|
||||
<cbc:IdentificationCode>NL</cbc:IdentificationCode>
|
||||
</cac:Country>
|
||||
</cac:PostalAddress>
|
||||
<cac:PartyTaxScheme>
|
||||
<cbc:CompanyID>NL8200.98.395.B.01</cbc:CompanyID>
|
||||
<cac:TaxScheme>
|
||||
<cbc:ID>VAT</cbc:ID>
|
||||
</cac:TaxScheme>
|
||||
</cac:PartyTaxScheme>
|
||||
<cac:PartyLegalEntity>
|
||||
<cbc:RegistrationName>De Koksmaat</cbc:RegistrationName>
|
||||
<cbc:CompanyID>57151520</cbc:CompanyID>
|
||||
</cac:PartyLegalEntity>
|
||||
</cac:Party>
|
||||
</cac:AccountingSupplierParty>
|
||||
<cac:AccountingCustomerParty>
|
||||
<cac:Party>
|
||||
<cac:PartyIdentification>
|
||||
<cbc:ID>10202</cbc:ID>
|
||||
</cac:PartyIdentification>
|
||||
<cac:PostalAddress>
|
||||
<cbc:StreetName>POSTBUS 367</cbc:StreetName>
|
||||
<cbc:CityName>HEEMSKERK</cbc:CityName>
|
||||
<cbc:PostalZone>1960 AJ</cbc:PostalZone>
|
||||
<cac:Country>
|
||||
<cbc:IdentificationCode>NL</cbc:IdentificationCode>
|
||||
</cac:Country>
|
||||
</cac:PostalAddress>
|
||||
<cac:PartyLegalEntity>
|
||||
<cbc:RegistrationName>ODIN 59</cbc:RegistrationName>
|
||||
</cac:PartyLegalEntity>
|
||||
<cac:Contact>
|
||||
<cbc:Name>Dhr. J BLOKKER</cbc:Name>
|
||||
</cac:Contact>
|
||||
</cac:Party>
|
||||
</cac:AccountingCustomerParty>
|
||||
<cac:PaymentMeans>
|
||||
<cbc:PaymentMeansCode>30</cbc:PaymentMeansCode>
|
||||
<cbc:PaymentID>Deb. 10202 / Fact. 12115118</cbc:PaymentID>
|
||||
<cac:PayeeFinancialAccount>
|
||||
<cbc:ID>NL57 RABO 0107307510</cbc:ID>
|
||||
</cac:PayeeFinancialAccount>
|
||||
</cac:PaymentMeans>
|
||||
<cac:PaymentMeans>
|
||||
<cbc:PaymentMeansCode>30</cbc:PaymentMeansCode>
|
||||
<cbc:PaymentID>Deb. 10202 / Fact. 12115118</cbc:PaymentID>
|
||||
<cac:PayeeFinancialAccount>
|
||||
<cbc:ID>NL03 INGB 0004489902</cbc:ID>
|
||||
</cac:PayeeFinancialAccount>
|
||||
</cac:PaymentMeans>
|
||||
<cac:TaxTotal>
|
||||
<cbc:TaxAmount currencyID="EUR">20.73</cbc:TaxAmount>
|
||||
<cac:TaxSubtotal>
|
||||
<cbc:TaxableAmount currencyID="EUR">183.23</cbc:TaxableAmount>
|
||||
<cbc:TaxAmount currencyID="EUR">10.99</cbc:TaxAmount>
|
||||
<cac:TaxCategory>
|
||||
<cbc:ID>S</cbc:ID>
|
||||
<cbc:Percent>6</cbc:Percent>
|
||||
<cac:TaxScheme>
|
||||
<cbc:ID>VAT</cbc:ID>
|
||||
</cac:TaxScheme>
|
||||
</cac:TaxCategory>
|
||||
</cac:TaxSubtotal>
|
||||
<cac:TaxSubtotal>
|
||||
<cbc:TaxableAmount currencyID="EUR">46.37</cbc:TaxableAmount>
|
||||
<cbc:TaxAmount currencyID="EUR">9.74</cbc:TaxAmount>
|
||||
<cac:TaxCategory>
|
||||
<cbc:ID>S</cbc:ID>
|
||||
<cbc:Percent>21</cbc:Percent>
|
||||
<cac:TaxScheme>
|
||||
<cbc:ID>VAT</cbc:ID>
|
||||
</cac:TaxScheme>
|
||||
</cac:TaxCategory>
|
||||
</cac:TaxSubtotal>
|
||||
</cac:TaxTotal>
|
||||
<cac:LegalMonetaryTotal>
|
||||
<cbc:LineExtensionAmount currencyID="EUR">229.60</cbc:LineExtensionAmount>
|
||||
<cbc:TaxExclusiveAmount currencyID="EUR">229.60</cbc:TaxExclusiveAmount>
|
||||
<cbc:TaxInclusiveAmount currencyID="EUR">250.33</cbc:TaxInclusiveAmount>
|
||||
<cbc:PayableAmount currencyID="EUR">250.33</cbc:PayableAmount>
|
||||
</cac:LegalMonetaryTotal>
|
||||
<cac:InvoiceLine>
|
||||
<cbc:ID>1</cbc:ID>
|
||||
<cbc:InvoicedQuantity unitCode="EA">2</cbc:InvoicedQuantity>
|
||||
<cbc:LineExtensionAmount currencyID="EUR">19.90</cbc:LineExtensionAmount>
|
||||
<cac:Item>
|
||||
<cbc:Name>PATAT FRITES 10MM 10KG</cbc:Name>
|
||||
<cac:SellersItemIdentification>
|
||||
<cbc:ID>166022</cbc:ID>
|
||||
</cac:SellersItemIdentification>
|
||||
<cac:ClassifiedTaxCategory>
|
||||
<cbc:ID>S</cbc:ID>
|
||||
<cbc:Percent>6</cbc:Percent>
|
||||
<cac:TaxScheme>
|
||||
<cbc:ID>VAT</cbc:ID>
|
||||
</cac:TaxScheme>
|
||||
</cac:ClassifiedTaxCategory>
|
||||
</cac:Item>
|
||||
<cac:Price>
|
||||
<cbc:PriceAmount currencyID="EUR">9.95</cbc:PriceAmount>
|
||||
</cac:Price>
|
||||
</cac:InvoiceLine>
|
||||
<cac:InvoiceLine>
|
||||
<cbc:ID>2</cbc:ID>
|
||||
<cbc:InvoicedQuantity unitCode="EA">1</cbc:InvoicedQuantity>
|
||||
<cbc:LineExtensionAmount currencyID="EUR">9.85</cbc:LineExtensionAmount>
|
||||
<cac:Item>
|
||||
<cbc:Name>PKAAS 50PL. JONG BEL. 1KG</cbc:Name>
|
||||
<cac:SellersItemIdentification>
|
||||
<cbc:ID>661813</cbc:ID>
|
||||
</cac:SellersItemIdentification>
|
||||
<cac:ClassifiedTaxCategory>
|
||||
<cbc:ID>S</cbc:ID>
|
||||
<cbc:Percent>6</cbc:Percent>
|
||||
<cac:TaxScheme>
|
||||
<cbc:ID>VAT</cbc:ID>
|
||||
</cac:TaxScheme>
|
||||
</cac:ClassifiedTaxCategory>
|
||||
</cac:Item>
|
||||
<cac:Price>
|
||||
<cbc:PriceAmount currencyID="EUR">9.85</cbc:PriceAmount>
|
||||
</cac:Price>
|
||||
</cac:InvoiceLine>
|
||||
<cac:InvoiceLine>
|
||||
<cbc:ID>3</cbc:ID>
|
||||
<cbc:InvoicedQuantity unitCode="EA">1</cbc:InvoicedQuantity>
|
||||
<cbc:LineExtensionAmount currencyID="EUR">8.29</cbc:LineExtensionAmount>
|
||||
<cac:Item>
|
||||
<cbc:Name>POT KETCHUP 3 LT</cbc:Name>
|
||||
<cac:SellersItemIdentification>
|
||||
<cbc:ID>438146</cbc:ID>
|
||||
</cac:SellersItemIdentification>
|
||||
<cac:ClassifiedTaxCategory>
|
||||
<cbc:ID>S</cbc:ID>
|
||||
<cbc:Percent>6</cbc:Percent>
|
||||
<cac:TaxScheme>
|
||||
<cbc:ID>VAT</cbc:ID>
|
||||
</cac:TaxScheme>
|
||||
</cac:ClassifiedTaxCategory>
|
||||
</cac:Item>
|
||||
<cac:Price>
|
||||
<cbc:PriceAmount currencyID="EUR">8.29</cbc:PriceAmount>
|
||||
</cac:Price>
|
||||
</cac:InvoiceLine>
|
||||
<cac:InvoiceLine>
|
||||
<cbc:ID>4</cbc:ID>
|
||||
<cbc:InvoicedQuantity unitCode="EA">2</cbc:InvoicedQuantity>
|
||||
<cbc:LineExtensionAmount currencyID="EUR">14.46</cbc:LineExtensionAmount>
|
||||
<cac:Item>
|
||||
<cbc:Name>FRITESSAUS 3 LRR</cbc:Name>
|
||||
<cac:SellersItemIdentification>
|
||||
<cbc:ID>438103</cbc:ID>
|
||||
</cac:SellersItemIdentification>
|
||||
<cac:ClassifiedTaxCategory>
|
||||
<cbc:ID>S</cbc:ID>
|
||||
<cbc:Percent>6</cbc:Percent>
|
||||
<cac:TaxScheme>
|
||||
<cbc:ID>VAT</cbc:ID>
|
||||
</cac:TaxScheme>
|
||||
</cac:ClassifiedTaxCategory>
|
||||
</cac:Item>
|
||||
<cac:Price>
|
||||
<cbc:PriceAmount currencyID="EUR">7.23</cbc:PriceAmount>
|
||||
</cac:Price>
|
||||
</cac:InvoiceLine>
|
||||
<cac:InvoiceLine>
|
||||
<cbc:ID>5</cbc:ID>
|
||||
<cbc:InvoicedQuantity unitCode="EA">1</cbc:InvoicedQuantity>
|
||||
<cbc:LineExtensionAmount currencyID="EUR">35.00</cbc:LineExtensionAmount>
|
||||
<cac:Item>
|
||||
<cbc:Name>KOFFIE BLIK 3,5KG SNELF</cbc:Name>
|
||||
<cac:SellersItemIdentification>
|
||||
<cbc:ID>666955</cbc:ID>
|
||||
</cac:SellersItemIdentification>
|
||||
<cac:ClassifiedTaxCategory>
|
||||
<cbc:ID>S</cbc:ID>
|
||||
<cbc:Percent>6</cbc:Percent>
|
||||
<cac:TaxScheme>
|
||||
<cbc:ID>VAT</cbc:ID>
|
||||
</cac:TaxScheme>
|
||||
</cac:ClassifiedTaxCategory>
|
||||
</cac:Item>
|
||||
<cac:Price>
|
||||
<cbc:PriceAmount currencyID="EUR">35.00</cbc:PriceAmount>
|
||||
</cac:Price>
|
||||
</cac:InvoiceLine>
|
||||
<cac:InvoiceLine>
|
||||
<cbc:ID>6</cbc:ID>
|
||||
<cbc:InvoicedQuantity unitCode="EA">1</cbc:InvoicedQuantity>
|
||||
<cbc:LineExtensionAmount currencyID="EUR">35.00</cbc:LineExtensionAmount>
|
||||
<cac:Item>
|
||||
<cbc:Name>KOFFIE 3.5 KG BLIK STAND</cbc:Name>
|
||||
<cac:SellersItemIdentification>
|
||||
<cbc:ID>664871</cbc:ID>
|
||||
</cac:SellersItemIdentification>
|
||||
<cac:ClassifiedTaxCategory>
|
||||
<cbc:ID>S</cbc:ID>
|
||||
<cbc:Percent>6</cbc:Percent>
|
||||
<cac:TaxScheme>
|
||||
<cbc:ID>VAT</cbc:ID>
|
||||
</cac:TaxScheme>
|
||||
</cac:ClassifiedTaxCategory>
|
||||
</cac:Item>
|
||||
<cac:Price>
|
||||
<cbc:PriceAmount currencyID="EUR">35.00</cbc:PriceAmount>
|
||||
</cac:Price>
|
||||
</cac:InvoiceLine>
|
||||
<cac:InvoiceLine>
|
||||
<cbc:ID>7</cbc:ID>
|
||||
<cbc:InvoicedQuantity unitCode="EA">1</cbc:InvoicedQuantity>
|
||||
<cbc:LineExtensionAmount currencyID="EUR">10.65</cbc:LineExtensionAmount>
|
||||
<cac:Item>
|
||||
<cbc:Name>SUIKERKLONT</cbc:Name>
|
||||
<cac:SellersItemIdentification>
|
||||
<cbc:ID>350257</cbc:ID>
|
||||
</cac:SellersItemIdentification>
|
||||
<cac:ClassifiedTaxCategory>
|
||||
<cbc:ID>S</cbc:ID>
|
||||
<cbc:Percent>6</cbc:Percent>
|
||||
<cac:TaxScheme>
|
||||
<cbc:ID>VAT</cbc:ID>
|
||||
</cac:TaxScheme>
|
||||
</cac:ClassifiedTaxCategory>
|
||||
</cac:Item>
|
||||
<cac:Price>
|
||||
<cbc:PriceAmount currencyID="EUR">10.65</cbc:PriceAmount>
|
||||
</cac:Price>
|
||||
</cac:InvoiceLine>
|
||||
<cac:InvoiceLine>
|
||||
<cbc:ID>8</cbc:ID>
|
||||
<cbc:InvoicedQuantity unitCode="EA">1</cbc:InvoicedQuantity>
|
||||
<cbc:LineExtensionAmount currencyID="EUR">1.55</cbc:LineExtensionAmount>
|
||||
<cac:Item>
|
||||
<cbc:Name>1 KG UL BLOKJES</cbc:Name>
|
||||
<cac:SellersItemIdentification>
|
||||
<cbc:ID>350258</cbc:ID>
|
||||
</cac:SellersItemIdentification>
|
||||
<cac:ClassifiedTaxCategory>
|
||||
<cbc:ID>S</cbc:ID>
|
||||
<cbc:Percent>6</cbc:Percent>
|
||||
<cac:TaxScheme>
|
||||
<cbc:ID>VAT</cbc:ID>
|
||||
</cac:TaxScheme>
|
||||
</cac:ClassifiedTaxCategory>
|
||||
</cac:Item>
|
||||
<cac:Price>
|
||||
<cbc:PriceAmount currencyID="EUR">1.55</cbc:PriceAmount>
|
||||
</cac:Price>
|
||||
</cac:InvoiceLine>
|
||||
<cac:InvoiceLine>
|
||||
<cbc:ID>9</cbc:ID>
|
||||
<cbc:InvoicedQuantity unitCode="EA">3</cbc:InvoicedQuantity>
|
||||
<cbc:LineExtensionAmount currencyID="EUR">14.37</cbc:LineExtensionAmount>
|
||||
<cac:Item>
|
||||
<cbc:Name>BLOCKNOTE A5</cbc:Name>
|
||||
<cac:SellersItemIdentification>
|
||||
<cbc:ID>999998</cbc:ID>
|
||||
</cac:SellersItemIdentification>
|
||||
<cac:ClassifiedTaxCategory>
|
||||
<cbc:ID>S</cbc:ID>
|
||||
<cbc:Percent>6</cbc:Percent>
|
||||
<cac:TaxScheme>
|
||||
<cbc:ID>VAT</cbc:ID>
|
||||
</cac:TaxScheme>
|
||||
</cac:ClassifiedTaxCategory>
|
||||
</cac:Item>
|
||||
<cac:Price>
|
||||
<cbc:PriceAmount currencyID="EUR">4.79</cbc:PriceAmount>
|
||||
</cac:Price>
|
||||
</cac:InvoiceLine>
|
||||
<cac:InvoiceLine>
|
||||
<cbc:ID>10</cbc:ID>
|
||||
<cbc:InvoicedQuantity unitCode="EA">1</cbc:InvoicedQuantity>
|
||||
<cbc:LineExtensionAmount currencyID="EUR">8.29</cbc:LineExtensionAmount>
|
||||
<cac:Item>
|
||||
<cbc:Name>CHIPS NAT KLEIN ZAKJES</cbc:Name>
|
||||
<cac:SellersItemIdentification>
|
||||
<cbc:ID>740810</cbc:ID>
|
||||
</cac:SellersItemIdentification>
|
||||
<cac:ClassifiedTaxCategory>
|
||||
<cbc:ID>S</cbc:ID>
|
||||
<cbc:Percent>6</cbc:Percent>
|
||||
<cac:TaxScheme>
|
||||
<cbc:ID>VAT</cbc:ID>
|
||||
</cac:TaxScheme>
|
||||
</cac:ClassifiedTaxCategory>
|
||||
</cac:Item>
|
||||
<cac:Price>
|
||||
<cbc:PriceAmount currencyID="EUR">8.29</cbc:PriceAmount>
|
||||
</cac:Price>
|
||||
</cac:InvoiceLine>
|
||||
<cac:InvoiceLine>
|
||||
<cbc:ID>11</cbc:ID>
|
||||
<cbc:InvoicedQuantity unitCode="EA">2</cbc:InvoicedQuantity>
|
||||
<cbc:LineExtensionAmount currencyID="EUR">16.58</cbc:LineExtensionAmount>
|
||||
<cac:Item>
|
||||
<cbc:Name>CHIPS PAP KLEINE ZAKJES</cbc:Name>
|
||||
<cac:SellersItemIdentification>
|
||||
<cbc:ID>740829</cbc:ID>
|
||||
</cac:SellersItemIdentification>
|
||||
<cac:ClassifiedTaxCategory>
|
||||
<cbc:ID>S</cbc:ID>
|
||||
<cbc:Percent>6</cbc:Percent>
|
||||
<cac:TaxScheme>
|
||||
<cbc:ID>VAT</cbc:ID>
|
||||
</cac:TaxScheme>
|
||||
</cac:ClassifiedTaxCategory>
|
||||
</cac:Item>
|
||||
<cac:Price>
|
||||
<cbc:PriceAmount currencyID="EUR">8.29</cbc:PriceAmount>
|
||||
</cac:Price>
|
||||
</cac:InvoiceLine>
|
||||
<cac:InvoiceLine>
|
||||
<cbc:ID>12</cbc:ID>
|
||||
<cbc:InvoicedQuantity unitCode="EA">1</cbc:InvoicedQuantity>
|
||||
<cbc:LineExtensionAmount currencyID="EUR">9.95</cbc:LineExtensionAmount>
|
||||
<cac:Item>
|
||||
<cbc:Name>TR KL PAKJES APPELSAP</cbc:Name>
|
||||
<cac:SellersItemIdentification>
|
||||
<cbc:ID>740828</cbc:ID>
|
||||
</cac:SellersItemIdentification>
|
||||
<cac:ClassifiedTaxCategory>
|
||||
<cbc:ID>S</cbc:ID>
|
||||
<cbc:Percent>6</cbc:Percent>
|
||||
<cac:TaxScheme>
|
||||
<cbc:ID>VAT</cbc:ID>
|
||||
</cac:TaxScheme>
|
||||
</cac:ClassifiedTaxCategory>
|
||||
</cac:Item>
|
||||
<cac:Price>
|
||||
<cbc:PriceAmount currencyID="EUR">9.95</cbc:PriceAmount>
|
||||
</cac:Price>
|
||||
</cac:InvoiceLine>
|
||||
<cac:InvoiceLine>
|
||||
<cbc:ID>13</cbc:ID>
|
||||
<cbc:InvoicedQuantity unitCode="EA">2</cbc:InvoicedQuantity>
|
||||
<cbc:LineExtensionAmount currencyID="EUR">3.30</cbc:LineExtensionAmount>
|
||||
<cac:Item>
|
||||
<cbc:Name>PK CHOCOLADEMEL</cbc:Name>
|
||||
<cac:SellersItemIdentification>
|
||||
<cbc:ID>740827</cbc:ID>
|
||||
</cac:SellersItemIdentification>
|
||||
<cac:ClassifiedTaxCategory>
|
||||
<cbc:ID>S</cbc:ID>
|
||||
<cbc:Percent>6</cbc:Percent>
|
||||
<cac:TaxScheme>
|
||||
<cbc:ID>VAT</cbc:ID>
|
||||
</cac:TaxScheme>
|
||||
</cac:ClassifiedTaxCategory>
|
||||
</cac:Item>
|
||||
<cac:Price>
|
||||
<cbc:PriceAmount currencyID="EUR">1.65</cbc:PriceAmount>
|
||||
</cac:Price>
|
||||
</cac:InvoiceLine>
|
||||
<cac:InvoiceLine>
|
||||
<cbc:ID>14</cbc:ID>
|
||||
<cbc:InvoicedQuantity unitCode="EA">1</cbc:InvoicedQuantity>
|
||||
<cbc:LineExtensionAmount currencyID="EUR">10.80</cbc:LineExtensionAmount>
|
||||
<cac:Item>
|
||||
<cbc:Name>KRAT BIER</cbc:Name>
|
||||
<cac:SellersItemIdentification>
|
||||
<cbc:ID>999996</cbc:ID>
|
||||
</cac:SellersItemIdentification>
|
||||
<cac:ClassifiedTaxCategory>
|
||||
<cbc:ID>S</cbc:ID>
|
||||
<cbc:Percent>21</cbc:Percent>
|
||||
<cac:TaxScheme>
|
||||
<cbc:ID>VAT</cbc:ID>
|
||||
</cac:TaxScheme>
|
||||
</cac:ClassifiedTaxCategory>
|
||||
</cac:Item>
|
||||
<cac:Price>
|
||||
<cbc:PriceAmount currencyID="EUR">10.80</cbc:PriceAmount>
|
||||
</cac:Price>
|
||||
</cac:InvoiceLine>
|
||||
<cac:InvoiceLine>
|
||||
<cbc:ID>15</cbc:ID>
|
||||
<cbc:InvoicedQuantity unitCode="EA">1</cbc:InvoicedQuantity>
|
||||
<cbc:LineExtensionAmount currencyID="EUR">3.90</cbc:LineExtensionAmount>
|
||||
<cac:Item>
|
||||
<cbc:Name>STATIEGELD</cbc:Name>
|
||||
<cac:SellersItemIdentification>
|
||||
<cbc:ID>999995</cbc:ID>
|
||||
</cac:SellersItemIdentification>
|
||||
<cac:ClassifiedTaxCategory>
|
||||
<cbc:ID>S</cbc:ID>
|
||||
<cbc:Percent>6</cbc:Percent>
|
||||
<cac:TaxScheme>
|
||||
<cbc:ID>VAT</cbc:ID>
|
||||
</cac:TaxScheme>
|
||||
</cac:ClassifiedTaxCategory>
|
||||
</cac:Item>
|
||||
<cac:Price>
|
||||
<cbc:PriceAmount currencyID="EUR">3.90</cbc:PriceAmount>
|
||||
</cac:Price>
|
||||
</cac:InvoiceLine>
|
||||
<cac:InvoiceLine>
|
||||
<cbc:ID>16</cbc:ID>
|
||||
<cbc:InvoicedQuantity unitCode="EA">2</cbc:InvoicedQuantity>
|
||||
<cbc:LineExtensionAmount currencyID="EUR">7.60</cbc:LineExtensionAmount>
|
||||
<cac:Item>
|
||||
<cbc:Name>BLEEK 3 X 750 ML</cbc:Name>
|
||||
<cac:SellersItemIdentification>
|
||||
<cbc:ID>102172</cbc:ID>
|
||||
</cac:SellersItemIdentification>
|
||||
<cac:ClassifiedTaxCategory>
|
||||
<cbc:ID>S</cbc:ID>
|
||||
<cbc:Percent>21</cbc:Percent>
|
||||
<cac:TaxScheme>
|
||||
<cbc:ID>VAT</cbc:ID>
|
||||
</cac:TaxScheme>
|
||||
</cac:ClassifiedTaxCategory>
|
||||
</cac:Item>
|
||||
<cac:Price>
|
||||
<cbc:PriceAmount currencyID="EUR">3.80</cbc:PriceAmount>
|
||||
</cac:Price>
|
||||
</cac:InvoiceLine>
|
||||
<cac:InvoiceLine>
|
||||
<cbc:ID>17</cbc:ID>
|
||||
<cbc:InvoicedQuantity unitCode="EA">2</cbc:InvoicedQuantity>
|
||||
<cbc:LineExtensionAmount currencyID="EUR">9.34</cbc:LineExtensionAmount>
|
||||
<cac:Item>
|
||||
<cbc:Name>WC PAPIER</cbc:Name>
|
||||
<cac:SellersItemIdentification>
|
||||
<cbc:ID>999994</cbc:ID>
|
||||
</cac:SellersItemIdentification>
|
||||
<cac:ClassifiedTaxCategory>
|
||||
<cbc:ID>S</cbc:ID>
|
||||
<cbc:Percent>21</cbc:Percent>
|
||||
<cac:TaxScheme>
|
||||
<cbc:ID>VAT</cbc:ID>
|
||||
</cac:TaxScheme>
|
||||
</cac:ClassifiedTaxCategory>
|
||||
</cac:Item>
|
||||
<cac:Price>
|
||||
<cbc:PriceAmount currencyID="EUR">4.67</cbc:PriceAmount>
|
||||
</cac:Price>
|
||||
</cac:InvoiceLine>
|
||||
<cac:InvoiceLine>
|
||||
<cbc:ID>18</cbc:ID>
|
||||
<cbc:InvoicedQuantity unitCode="EA">1</cbc:InvoicedQuantity>
|
||||
<cbc:LineExtensionAmount currencyID="EUR">18.63</cbc:LineExtensionAmount>
|
||||
<cac:Item>
|
||||
<cbc:Name>BALPENNEN 50 ST BLAUW</cbc:Name>
|
||||
<cac:SellersItemIdentification>
|
||||
<cbc:ID>999993</cbc:ID>
|
||||
</cac:SellersItemIdentification>
|
||||
<cac:ClassifiedTaxCategory>
|
||||
<cbc:ID>S</cbc:ID>
|
||||
<cbc:Percent>21</cbc:Percent>
|
||||
<cac:TaxScheme>
|
||||
<cbc:ID>VAT</cbc:ID>
|
||||
</cac:TaxScheme>
|
||||
</cac:ClassifiedTaxCategory>
|
||||
</cac:Item>
|
||||
<cac:Price>
|
||||
<cbc:PriceAmount currencyID="EUR">18.63</cbc:PriceAmount>
|
||||
</cac:Price>
|
||||
</cac:InvoiceLine>
|
||||
<cac:InvoiceLine>
|
||||
<cbc:ID>19</cbc:ID>
|
||||
<cbc:InvoicedQuantity unitCode="EA">6</cbc:InvoicedQuantity>
|
||||
<cbc:LineExtensionAmount currencyID="EUR">102.12</cbc:LineExtensionAmount>
|
||||
<cac:Item>
|
||||
<cbc:Name>EM FRITUURVET</cbc:Name>
|
||||
<cac:SellersItemIdentification>
|
||||
<cbc:ID>999992</cbc:ID>
|
||||
</cac:SellersItemIdentification>
|
||||
<cac:ClassifiedTaxCategory>
|
||||
<cbc:ID>S</cbc:ID>
|
||||
<cbc:Percent>6</cbc:Percent>
|
||||
<cac:TaxScheme>
|
||||
<cbc:ID>VAT</cbc:ID>
|
||||
</cac:TaxScheme>
|
||||
</cac:ClassifiedTaxCategory>
|
||||
</cac:Item>
|
||||
<cac:Price>
|
||||
<cbc:PriceAmount currencyID="EUR">17.02</cbc:PriceAmount>
|
||||
</cac:Price>
|
||||
</cac:InvoiceLine>
|
||||
<cac:InvoiceLine>
|
||||
<cbc:ID>20</cbc:ID>
|
||||
<cbc:InvoicedQuantity unitCode="EA">6</cbc:InvoicedQuantity>
|
||||
<cbc:LineExtensionAmount currencyID="EUR">-109.98</cbc:LineExtensionAmount>
|
||||
<cac:Item>
|
||||
<cbc:Name>FRITUUR VET 10 KG RETOUR</cbc:Name>
|
||||
<cac:SellersItemIdentification>
|
||||
<cbc:ID>175137</cbc:ID>
|
||||
</cac:SellersItemIdentification>
|
||||
<cac:ClassifiedTaxCategory>
|
||||
<cbc:ID>S</cbc:ID>
|
||||
<cbc:Percent>6</cbc:Percent>
|
||||
<cac:TaxScheme>
|
||||
<cbc:ID>VAT</cbc:ID>
|
||||
</cac:TaxScheme>
|
||||
</cac:ClassifiedTaxCategory>
|
||||
</cac:Item>
|
||||
<cac:Price>
|
||||
<cbc:PriceAmount currencyID="EUR">18.33</cbc:PriceAmount>
|
||||
</cac:Price>
|
||||
</cac:InvoiceLine>
|
||||
</Invoice>
|
||||
542
src/test/resources/examples/assertions/ubl-0002.xml
Normal file
542
src/test/resources/examples/assertions/ubl-0002.xml
Normal file
|
|
@ -0,0 +1,542 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!--
|
||||
~ Licensed to the Koordinierungsstelle für IT-Standards (KoSIT) under
|
||||
~ one or more contributor license agreements. See the NOTICE file
|
||||
~ distributed with this work for additional information
|
||||
~ regarding copyright ownership. KoSIT licenses this file
|
||||
~ to you under the Apache License, Version 2.0 (the
|
||||
~ "License"); you may not use this file except in compliance
|
||||
~ with the License. You may obtain a copy of the License at
|
||||
~
|
||||
~ http://www.apache.org/licenses/LICENSE-2.0
|
||||
~
|
||||
~ Unless required by applicable law or agreed to in writing,
|
||||
~ software distributed under the License is distributed on an
|
||||
~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||
~ KIND, either express or implied. See the License for the
|
||||
~ specific language governing permissions and limitations
|
||||
~ under the License.
|
||||
-->
|
||||
|
||||
<Invoice xmlns:cac="urn:oasis:names:specification:ubl:schema:xsd:CommonAggregateComponents-2"
|
||||
xmlns:cbc="urn:oasis:names:specification:ubl:schema:xsd:CommonBasicComponents-2"
|
||||
xmlns="urn:oasis:names:specification:ubl:schema:xsd:Invoice-2">
|
||||
<cbc:CustomizationID>urn:cen.eu:en16931:2017</cbc:CustomizationID>
|
||||
<cbc:ID>12115118</cbc:ID>
|
||||
<cbc:IssueDate>2015-01-09</cbc:IssueDate>
|
||||
<cbc:DueDate>2015-01-09</cbc:DueDate>
|
||||
<cbc:InvoiceTypeCode>380</cbc:InvoiceTypeCode>
|
||||
<cbc:Note>Alle leveringen zijn franco. Alle prijzen zijn incl. BTW. Betalingstermijn: 14 dagen netto.
|
||||
Prijswijzigingen voorbehouden. Op al onze aanbiedingen, leveringen en overeenkomsten zijn van toepassing in de
|
||||
algemene verkoop en leveringsvoorwaarden. Gedeponeerd bij de K.v.K. te Amsterdam 25-04-'85##Delivery terms
|
||||
</cbc:Note>
|
||||
<cbc:DocumentCurrencyCode>EUR</cbc:DocumentCurrencyCode>
|
||||
<cac:AccountingSupplierParty>
|
||||
<cac:Party>
|
||||
<cac:PostalAddress>
|
||||
<cbc:StreetName>Postbus 7l</cbc:StreetName>
|
||||
<cbc:CityName>Velsen-Noord</cbc:CityName>
|
||||
<cbc:PostalZone>1950 AB</cbc:PostalZone>
|
||||
<cac:Country>
|
||||
<cbc:IdentificationCode>NL</cbc:IdentificationCode>
|
||||
</cac:Country>
|
||||
</cac:PostalAddress>
|
||||
<cac:PartyTaxScheme>
|
||||
<cbc:CompanyID>NL8200.98.395.B.01</cbc:CompanyID>
|
||||
<cac:TaxScheme>
|
||||
<cbc:ID>VAT</cbc:ID>
|
||||
</cac:TaxScheme>
|
||||
</cac:PartyTaxScheme>
|
||||
<cac:PartyLegalEntity>
|
||||
<cbc:RegistrationName>De Koksmaat</cbc:RegistrationName>
|
||||
<cbc:CompanyID>57151520</cbc:CompanyID>
|
||||
</cac:PartyLegalEntity>
|
||||
</cac:Party>
|
||||
</cac:AccountingSupplierParty>
|
||||
<cac:AccountingCustomerParty>
|
||||
<cac:Party>
|
||||
<cac:PartyIdentification>
|
||||
<cbc:ID>10202</cbc:ID>
|
||||
</cac:PartyIdentification>
|
||||
<cac:PostalAddress>
|
||||
<cbc:StreetName>POSTBUS 367</cbc:StreetName>
|
||||
<cbc:CityName>HEEMSKERK</cbc:CityName>
|
||||
<cbc:PostalZone>1960 AJ</cbc:PostalZone>
|
||||
<cac:Country>
|
||||
<cbc:IdentificationCode>NL</cbc:IdentificationCode>
|
||||
</cac:Country>
|
||||
</cac:PostalAddress>
|
||||
<cac:PartyLegalEntity>
|
||||
<cbc:RegistrationName>ODIN 59</cbc:RegistrationName>
|
||||
</cac:PartyLegalEntity>
|
||||
<cac:Contact>
|
||||
<cbc:Name>Dhr. J BLOKKER</cbc:Name>
|
||||
</cac:Contact>
|
||||
</cac:Party>
|
||||
</cac:AccountingCustomerParty>
|
||||
<cac:PaymentMeans>
|
||||
<cbc:PaymentMeansCode>30</cbc:PaymentMeansCode>
|
||||
<cbc:PaymentID>Deb. 10202 / Fact. 12115118</cbc:PaymentID>
|
||||
<cac:PayeeFinancialAccount>
|
||||
<cbc:ID>NL57 RABO 0107307510</cbc:ID>
|
||||
</cac:PayeeFinancialAccount>
|
||||
</cac:PaymentMeans>
|
||||
<cac:PaymentMeans>
|
||||
<cbc:PaymentMeansCode>30</cbc:PaymentMeansCode>
|
||||
<cbc:PaymentID>Deb. 10202 / Fact. 12115118</cbc:PaymentID>
|
||||
<cac:PayeeFinancialAccount>
|
||||
<cbc:ID>NL03 INGB 0004489902</cbc:ID>
|
||||
</cac:PayeeFinancialAccount>
|
||||
</cac:PaymentMeans>
|
||||
<cac:TaxTotal>
|
||||
<cbc:TaxAmount currencyID="EUR">20.73</cbc:TaxAmount>
|
||||
<cac:TaxSubtotal>
|
||||
<cbc:TaxableAmount currencyID="EUR">183.23</cbc:TaxableAmount>
|
||||
<cbc:TaxAmount currencyID="EUR">10.99</cbc:TaxAmount>
|
||||
<cac:TaxCategory>
|
||||
<cbc:ID>S</cbc:ID>
|
||||
<cbc:Percent>6</cbc:Percent>
|
||||
<cac:TaxScheme>
|
||||
<cbc:ID>VAT</cbc:ID>
|
||||
</cac:TaxScheme>
|
||||
</cac:TaxCategory>
|
||||
</cac:TaxSubtotal>
|
||||
<cac:TaxSubtotal>
|
||||
<cbc:TaxableAmount currencyID="EUR">46.37</cbc:TaxableAmount>
|
||||
<cbc:TaxAmount currencyID="EUR">9.74</cbc:TaxAmount>
|
||||
<cac:TaxCategory>
|
||||
<cbc:ID>S</cbc:ID>
|
||||
<cbc:Percent>21</cbc:Percent>
|
||||
<cac:TaxScheme>
|
||||
<cbc:ID>VAT</cbc:ID>
|
||||
</cac:TaxScheme>
|
||||
</cac:TaxCategory>
|
||||
</cac:TaxSubtotal>
|
||||
</cac:TaxTotal>
|
||||
<cac:LegalMonetaryTotal>
|
||||
<cbc:LineExtensionAmount currencyID="EUR">229.60</cbc:LineExtensionAmount>
|
||||
<cbc:TaxExclusiveAmount currencyID="EUR">229.60</cbc:TaxExclusiveAmount>
|
||||
<cbc:TaxInclusiveAmount currencyID="EUR">250.33</cbc:TaxInclusiveAmount>
|
||||
<cbc:PayableAmount currencyID="EUR">250.33</cbc:PayableAmount>
|
||||
</cac:LegalMonetaryTotal>
|
||||
<cac:InvoiceLine>
|
||||
<cbc:ID>1</cbc:ID>
|
||||
<cbc:InvoicedQuantity unitCode="EA">2</cbc:InvoicedQuantity>
|
||||
<cbc:LineExtensionAmount currencyID="EUR">19.90</cbc:LineExtensionAmount>
|
||||
<cac:Item>
|
||||
<cbc:Name>PATAT FRITES 10MM 10KG</cbc:Name>
|
||||
<cac:SellersItemIdentification>
|
||||
<cbc:ID>166022</cbc:ID>
|
||||
</cac:SellersItemIdentification>
|
||||
<cac:ClassifiedTaxCategory>
|
||||
<cbc:ID>S</cbc:ID>
|
||||
<cbc:Percent>6</cbc:Percent>
|
||||
<cac:TaxScheme>
|
||||
<cbc:ID>VAT</cbc:ID>
|
||||
</cac:TaxScheme>
|
||||
</cac:ClassifiedTaxCategory>
|
||||
</cac:Item>
|
||||
<cac:Price>
|
||||
<cbc:PriceAmount currencyID="EUR">9.95</cbc:PriceAmount>
|
||||
</cac:Price>
|
||||
</cac:InvoiceLine>
|
||||
<cac:InvoiceLine>
|
||||
<cbc:ID>2</cbc:ID>
|
||||
<cbc:InvoicedQuantity unitCode="EA">1</cbc:InvoicedQuantity>
|
||||
<cbc:LineExtensionAmount currencyID="EUR">9.85</cbc:LineExtensionAmount>
|
||||
<cac:Item>
|
||||
<cbc:Name>PKAAS 50PL. JONG BEL. 1KG</cbc:Name>
|
||||
<cac:SellersItemIdentification>
|
||||
<cbc:ID>661813</cbc:ID>
|
||||
</cac:SellersItemIdentification>
|
||||
<cac:ClassifiedTaxCategory>
|
||||
<cbc:ID>S</cbc:ID>
|
||||
<cbc:Percent>6</cbc:Percent>
|
||||
<cac:TaxScheme>
|
||||
<cbc:ID>VAT</cbc:ID>
|
||||
</cac:TaxScheme>
|
||||
</cac:ClassifiedTaxCategory>
|
||||
</cac:Item>
|
||||
<cac:Price>
|
||||
<cbc:PriceAmount currencyID="EUR">9.85</cbc:PriceAmount>
|
||||
</cac:Price>
|
||||
</cac:InvoiceLine>
|
||||
<cac:InvoiceLine>
|
||||
<cbc:ID>3</cbc:ID>
|
||||
<cbc:InvoicedQuantity unitCode="EA">1</cbc:InvoicedQuantity>
|
||||
<cbc:LineExtensionAmount currencyID="EUR">8.29</cbc:LineExtensionAmount>
|
||||
<cac:Item>
|
||||
<cbc:Name>POT KETCHUP 3 LT</cbc:Name>
|
||||
<cac:SellersItemIdentification>
|
||||
<cbc:ID>438146</cbc:ID>
|
||||
</cac:SellersItemIdentification>
|
||||
<cac:ClassifiedTaxCategory>
|
||||
<cbc:ID>S</cbc:ID>
|
||||
<cbc:Percent>6</cbc:Percent>
|
||||
<cac:TaxScheme>
|
||||
<cbc:ID>VAT</cbc:ID>
|
||||
</cac:TaxScheme>
|
||||
</cac:ClassifiedTaxCategory>
|
||||
</cac:Item>
|
||||
<cac:Price>
|
||||
<cbc:PriceAmount currencyID="EUR">8.29</cbc:PriceAmount>
|
||||
</cac:Price>
|
||||
</cac:InvoiceLine>
|
||||
<cac:InvoiceLine>
|
||||
<cbc:ID>4</cbc:ID>
|
||||
<cbc:InvoicedQuantity unitCode="EA">2</cbc:InvoicedQuantity>
|
||||
<cbc:LineExtensionAmount currencyID="EUR">14.46</cbc:LineExtensionAmount>
|
||||
<cac:Item>
|
||||
<cbc:Name>FRITESSAUS 3 LRR</cbc:Name>
|
||||
<cac:SellersItemIdentification>
|
||||
<cbc:ID>438103</cbc:ID>
|
||||
</cac:SellersItemIdentification>
|
||||
<cac:ClassifiedTaxCategory>
|
||||
<cbc:ID>S</cbc:ID>
|
||||
<cbc:Percent>6</cbc:Percent>
|
||||
<cac:TaxScheme>
|
||||
<cbc:ID>VAT</cbc:ID>
|
||||
</cac:TaxScheme>
|
||||
</cac:ClassifiedTaxCategory>
|
||||
</cac:Item>
|
||||
<cac:Price>
|
||||
<cbc:PriceAmount currencyID="EUR">7.23</cbc:PriceAmount>
|
||||
</cac:Price>
|
||||
</cac:InvoiceLine>
|
||||
<cac:InvoiceLine>
|
||||
<cbc:ID>5</cbc:ID>
|
||||
<cbc:InvoicedQuantity unitCode="EA">1</cbc:InvoicedQuantity>
|
||||
<cbc:LineExtensionAmount currencyID="EUR">35.00</cbc:LineExtensionAmount>
|
||||
<cac:Item>
|
||||
<cbc:Name>KOFFIE BLIK 3,5KG SNELF</cbc:Name>
|
||||
<cac:SellersItemIdentification>
|
||||
<cbc:ID>666955</cbc:ID>
|
||||
</cac:SellersItemIdentification>
|
||||
<cac:ClassifiedTaxCategory>
|
||||
<cbc:ID>S</cbc:ID>
|
||||
<cbc:Percent>6</cbc:Percent>
|
||||
<cac:TaxScheme>
|
||||
<cbc:ID>VAT</cbc:ID>
|
||||
</cac:TaxScheme>
|
||||
</cac:ClassifiedTaxCategory>
|
||||
</cac:Item>
|
||||
<cac:Price>
|
||||
<cbc:PriceAmount currencyID="EUR">35.00</cbc:PriceAmount>
|
||||
</cac:Price>
|
||||
</cac:InvoiceLine>
|
||||
<cac:InvoiceLine>
|
||||
<cbc:ID>6</cbc:ID>
|
||||
<cbc:InvoicedQuantity unitCode="EA">1</cbc:InvoicedQuantity>
|
||||
<cbc:LineExtensionAmount currencyID="EUR">35.00</cbc:LineExtensionAmount>
|
||||
<cac:Item>
|
||||
<cbc:Name>KOFFIE 3.5 KG BLIK STAND</cbc:Name>
|
||||
<cac:SellersItemIdentification>
|
||||
<cbc:ID>664871</cbc:ID>
|
||||
</cac:SellersItemIdentification>
|
||||
<cac:ClassifiedTaxCategory>
|
||||
<cbc:ID>S</cbc:ID>
|
||||
<cbc:Percent>6</cbc:Percent>
|
||||
<cac:TaxScheme>
|
||||
<cbc:ID>VAT</cbc:ID>
|
||||
</cac:TaxScheme>
|
||||
</cac:ClassifiedTaxCategory>
|
||||
</cac:Item>
|
||||
<cac:Price>
|
||||
<cbc:PriceAmount currencyID="EUR">35.00</cbc:PriceAmount>
|
||||
</cac:Price>
|
||||
</cac:InvoiceLine>
|
||||
<cac:InvoiceLine>
|
||||
<cbc:ID>7</cbc:ID>
|
||||
<cbc:InvoicedQuantity unitCode="EA">1</cbc:InvoicedQuantity>
|
||||
<cbc:LineExtensionAmount currencyID="EUR">10.65</cbc:LineExtensionAmount>
|
||||
<cac:Item>
|
||||
<cbc:Name>SUIKERKLONT</cbc:Name>
|
||||
<cac:SellersItemIdentification>
|
||||
<cbc:ID>350257</cbc:ID>
|
||||
</cac:SellersItemIdentification>
|
||||
<cac:ClassifiedTaxCategory>
|
||||
<cbc:ID>S</cbc:ID>
|
||||
<cbc:Percent>6</cbc:Percent>
|
||||
<cac:TaxScheme>
|
||||
<cbc:ID>VAT</cbc:ID>
|
||||
</cac:TaxScheme>
|
||||
</cac:ClassifiedTaxCategory>
|
||||
</cac:Item>
|
||||
<cac:Price>
|
||||
<cbc:PriceAmount currencyID="EUR">10.65</cbc:PriceAmount>
|
||||
</cac:Price>
|
||||
</cac:InvoiceLine>
|
||||
<cac:InvoiceLine>
|
||||
<cbc:ID>8</cbc:ID>
|
||||
<cbc:InvoicedQuantity unitCode="EA">1</cbc:InvoicedQuantity>
|
||||
<cbc:LineExtensionAmount currencyID="EUR">1.55</cbc:LineExtensionAmount>
|
||||
<cac:Item>
|
||||
<cbc:Name>1 KG UL BLOKJES</cbc:Name>
|
||||
<cac:SellersItemIdentification>
|
||||
<cbc:ID>350258</cbc:ID>
|
||||
</cac:SellersItemIdentification>
|
||||
<cac:ClassifiedTaxCategory>
|
||||
<cbc:ID>S</cbc:ID>
|
||||
<cbc:Percent>6</cbc:Percent>
|
||||
<cac:TaxScheme>
|
||||
<cbc:ID>VAT</cbc:ID>
|
||||
</cac:TaxScheme>
|
||||
</cac:ClassifiedTaxCategory>
|
||||
</cac:Item>
|
||||
<cac:Price>
|
||||
<cbc:PriceAmount currencyID="EUR">1.55</cbc:PriceAmount>
|
||||
</cac:Price>
|
||||
</cac:InvoiceLine>
|
||||
<cac:InvoiceLine>
|
||||
<cbc:ID>9</cbc:ID>
|
||||
<cbc:InvoicedQuantity unitCode="EA">3</cbc:InvoicedQuantity>
|
||||
<cbc:LineExtensionAmount currencyID="EUR">14.37</cbc:LineExtensionAmount>
|
||||
<cac:Item>
|
||||
<cbc:Name>BLOCKNOTE A5</cbc:Name>
|
||||
<cac:SellersItemIdentification>
|
||||
<cbc:ID>999998</cbc:ID>
|
||||
</cac:SellersItemIdentification>
|
||||
<cac:ClassifiedTaxCategory>
|
||||
<cbc:ID>S</cbc:ID>
|
||||
<cbc:Percent>6</cbc:Percent>
|
||||
<cac:TaxScheme>
|
||||
<cbc:ID>VAT</cbc:ID>
|
||||
</cac:TaxScheme>
|
||||
</cac:ClassifiedTaxCategory>
|
||||
</cac:Item>
|
||||
<cac:Price>
|
||||
<cbc:PriceAmount currencyID="EUR">4.79</cbc:PriceAmount>
|
||||
</cac:Price>
|
||||
</cac:InvoiceLine>
|
||||
<cac:InvoiceLine>
|
||||
<cbc:ID>10</cbc:ID>
|
||||
<cbc:InvoicedQuantity unitCode="EA">1</cbc:InvoicedQuantity>
|
||||
<cbc:LineExtensionAmount currencyID="EUR">8.29</cbc:LineExtensionAmount>
|
||||
<cac:Item>
|
||||
<cbc:Name>CHIPS NAT KLEIN ZAKJES</cbc:Name>
|
||||
<cac:SellersItemIdentification>
|
||||
<cbc:ID>740810</cbc:ID>
|
||||
</cac:SellersItemIdentification>
|
||||
<cac:ClassifiedTaxCategory>
|
||||
<cbc:ID>S</cbc:ID>
|
||||
<cbc:Percent>6</cbc:Percent>
|
||||
<cac:TaxScheme>
|
||||
<cbc:ID>VAT</cbc:ID>
|
||||
</cac:TaxScheme>
|
||||
</cac:ClassifiedTaxCategory>
|
||||
</cac:Item>
|
||||
<cac:Price>
|
||||
<cbc:PriceAmount currencyID="EUR">8.29</cbc:PriceAmount>
|
||||
</cac:Price>
|
||||
</cac:InvoiceLine>
|
||||
<cac:InvoiceLine>
|
||||
<cbc:ID>11</cbc:ID>
|
||||
<cbc:InvoicedQuantity unitCode="EA">2</cbc:InvoicedQuantity>
|
||||
<cbc:LineExtensionAmount currencyID="EUR">16.58</cbc:LineExtensionAmount>
|
||||
<cac:Item>
|
||||
<cbc:Name>CHIPS PAP KLEINE ZAKJES</cbc:Name>
|
||||
<cac:SellersItemIdentification>
|
||||
<cbc:ID>740829</cbc:ID>
|
||||
</cac:SellersItemIdentification>
|
||||
<cac:ClassifiedTaxCategory>
|
||||
<cbc:ID>S</cbc:ID>
|
||||
<cbc:Percent>6</cbc:Percent>
|
||||
<cac:TaxScheme>
|
||||
<cbc:ID>VAT</cbc:ID>
|
||||
</cac:TaxScheme>
|
||||
</cac:ClassifiedTaxCategory>
|
||||
</cac:Item>
|
||||
<cac:Price>
|
||||
<cbc:PriceAmount currencyID="EUR">8.29</cbc:PriceAmount>
|
||||
</cac:Price>
|
||||
</cac:InvoiceLine>
|
||||
<cac:InvoiceLine>
|
||||
<cbc:ID>12</cbc:ID>
|
||||
<cbc:InvoicedQuantity unitCode="EA">1</cbc:InvoicedQuantity>
|
||||
<cbc:LineExtensionAmount currencyID="EUR">9.95</cbc:LineExtensionAmount>
|
||||
<cac:Item>
|
||||
<cbc:Name>TR KL PAKJES APPELSAP</cbc:Name>
|
||||
<cac:SellersItemIdentification>
|
||||
<cbc:ID>740828</cbc:ID>
|
||||
</cac:SellersItemIdentification>
|
||||
<cac:ClassifiedTaxCategory>
|
||||
<cbc:ID>S</cbc:ID>
|
||||
<cbc:Percent>6</cbc:Percent>
|
||||
<cac:TaxScheme>
|
||||
<cbc:ID>VAT</cbc:ID>
|
||||
</cac:TaxScheme>
|
||||
</cac:ClassifiedTaxCategory>
|
||||
</cac:Item>
|
||||
<cac:Price>
|
||||
<cbc:PriceAmount currencyID="EUR">9.95</cbc:PriceAmount>
|
||||
</cac:Price>
|
||||
</cac:InvoiceLine>
|
||||
<cac:InvoiceLine>
|
||||
<cbc:ID>13</cbc:ID>
|
||||
<cbc:InvoicedQuantity unitCode="EA">2</cbc:InvoicedQuantity>
|
||||
<cbc:LineExtensionAmount currencyID="EUR">3.30</cbc:LineExtensionAmount>
|
||||
<cac:Item>
|
||||
<cbc:Name>PK CHOCOLADEMEL</cbc:Name>
|
||||
<cac:SellersItemIdentification>
|
||||
<cbc:ID>740827</cbc:ID>
|
||||
</cac:SellersItemIdentification>
|
||||
<cac:ClassifiedTaxCategory>
|
||||
<cbc:ID>S</cbc:ID>
|
||||
<cbc:Percent>6</cbc:Percent>
|
||||
<cac:TaxScheme>
|
||||
<cbc:ID>VAT</cbc:ID>
|
||||
</cac:TaxScheme>
|
||||
</cac:ClassifiedTaxCategory>
|
||||
</cac:Item>
|
||||
<cac:Price>
|
||||
<cbc:PriceAmount currencyID="EUR">1.65</cbc:PriceAmount>
|
||||
</cac:Price>
|
||||
</cac:InvoiceLine>
|
||||
<cac:InvoiceLine>
|
||||
<cbc:ID>14</cbc:ID>
|
||||
<cbc:InvoicedQuantity unitCode="EA">1</cbc:InvoicedQuantity>
|
||||
<cbc:LineExtensionAmount currencyID="EUR">10.80</cbc:LineExtensionAmount>
|
||||
<cac:Item>
|
||||
<cbc:Name>KRAT BIER</cbc:Name>
|
||||
<cac:SellersItemIdentification>
|
||||
<cbc:ID>999996</cbc:ID>
|
||||
</cac:SellersItemIdentification>
|
||||
<cac:ClassifiedTaxCategory>
|
||||
<cbc:ID>S</cbc:ID>
|
||||
<cbc:Percent>21</cbc:Percent>
|
||||
<cac:TaxScheme>
|
||||
<cbc:ID>VAT</cbc:ID>
|
||||
</cac:TaxScheme>
|
||||
</cac:ClassifiedTaxCategory>
|
||||
</cac:Item>
|
||||
<cac:Price>
|
||||
<cbc:PriceAmount currencyID="EUR">10.80</cbc:PriceAmount>
|
||||
</cac:Price>
|
||||
</cac:InvoiceLine>
|
||||
<cac:InvoiceLine>
|
||||
<cbc:ID>15</cbc:ID>
|
||||
<cbc:InvoicedQuantity unitCode="EA">1</cbc:InvoicedQuantity>
|
||||
<cbc:LineExtensionAmount currencyID="EUR">3.90</cbc:LineExtensionAmount>
|
||||
<cac:Item>
|
||||
<cbc:Name>STATIEGELD</cbc:Name>
|
||||
<cac:SellersItemIdentification>
|
||||
<cbc:ID>999995</cbc:ID>
|
||||
</cac:SellersItemIdentification>
|
||||
<cac:ClassifiedTaxCategory>
|
||||
<cbc:ID>S</cbc:ID>
|
||||
<cbc:Percent>6</cbc:Percent>
|
||||
<cac:TaxScheme>
|
||||
<cbc:ID>VAT</cbc:ID>
|
||||
</cac:TaxScheme>
|
||||
</cac:ClassifiedTaxCategory>
|
||||
</cac:Item>
|
||||
<cac:Price>
|
||||
<cbc:PriceAmount currencyID="EUR">3.90</cbc:PriceAmount>
|
||||
</cac:Price>
|
||||
</cac:InvoiceLine>
|
||||
<cac:InvoiceLine>
|
||||
<cbc:ID>16</cbc:ID>
|
||||
<cbc:InvoicedQuantity unitCode="EA">2</cbc:InvoicedQuantity>
|
||||
<cbc:LineExtensionAmount currencyID="EUR">7.60</cbc:LineExtensionAmount>
|
||||
<cac:Item>
|
||||
<cbc:Name>BLEEK 3 X 750 ML</cbc:Name>
|
||||
<cac:SellersItemIdentification>
|
||||
<cbc:ID>102172</cbc:ID>
|
||||
</cac:SellersItemIdentification>
|
||||
<cac:ClassifiedTaxCategory>
|
||||
<cbc:ID>S</cbc:ID>
|
||||
<cbc:Percent>21</cbc:Percent>
|
||||
<cac:TaxScheme>
|
||||
<cbc:ID>VAT</cbc:ID>
|
||||
</cac:TaxScheme>
|
||||
</cac:ClassifiedTaxCategory>
|
||||
</cac:Item>
|
||||
<cac:Price>
|
||||
<cbc:PriceAmount currencyID="EUR">3.80</cbc:PriceAmount>
|
||||
</cac:Price>
|
||||
</cac:InvoiceLine>
|
||||
<cac:InvoiceLine>
|
||||
<cbc:ID>17</cbc:ID>
|
||||
<cbc:InvoicedQuantity unitCode="EA">2</cbc:InvoicedQuantity>
|
||||
<cbc:LineExtensionAmount currencyID="EUR">9.34</cbc:LineExtensionAmount>
|
||||
<cac:Item>
|
||||
<cbc:Name>WC PAPIER</cbc:Name>
|
||||
<cac:SellersItemIdentification>
|
||||
<cbc:ID>999994</cbc:ID>
|
||||
</cac:SellersItemIdentification>
|
||||
<cac:ClassifiedTaxCategory>
|
||||
<cbc:ID>S</cbc:ID>
|
||||
<cbc:Percent>21</cbc:Percent>
|
||||
<cac:TaxScheme>
|
||||
<cbc:ID>VAT</cbc:ID>
|
||||
</cac:TaxScheme>
|
||||
</cac:ClassifiedTaxCategory>
|
||||
</cac:Item>
|
||||
<cac:Price>
|
||||
<cbc:PriceAmount currencyID="EUR">4.67</cbc:PriceAmount>
|
||||
</cac:Price>
|
||||
</cac:InvoiceLine>
|
||||
<cac:InvoiceLine>
|
||||
<cbc:ID>18</cbc:ID>
|
||||
<cbc:InvoicedQuantity unitCode="EA">1</cbc:InvoicedQuantity>
|
||||
<cbc:LineExtensionAmount currencyID="EUR">18.63</cbc:LineExtensionAmount>
|
||||
<cac:Item>
|
||||
<cbc:Name>BALPENNEN 50 ST BLAUW</cbc:Name>
|
||||
<cac:SellersItemIdentification>
|
||||
<cbc:ID>999993</cbc:ID>
|
||||
</cac:SellersItemIdentification>
|
||||
<cac:ClassifiedTaxCategory>
|
||||
<cbc:ID>S</cbc:ID>
|
||||
<cbc:Percent>21</cbc:Percent>
|
||||
<cac:TaxScheme>
|
||||
<cbc:ID>VAT</cbc:ID>
|
||||
</cac:TaxScheme>
|
||||
</cac:ClassifiedTaxCategory>
|
||||
</cac:Item>
|
||||
<cac:Price>
|
||||
<cbc:PriceAmount currencyID="EUR">18.63</cbc:PriceAmount>
|
||||
</cac:Price>
|
||||
</cac:InvoiceLine>
|
||||
<cac:InvoiceLine>
|
||||
<cbc:ID>19</cbc:ID>
|
||||
<cbc:InvoicedQuantity unitCode="EA">6</cbc:InvoicedQuantity>
|
||||
<cbc:LineExtensionAmount currencyID="EUR">102.12</cbc:LineExtensionAmount>
|
||||
<cac:Item>
|
||||
<cbc:Name>EM FRITUURVET</cbc:Name>
|
||||
<cac:SellersItemIdentification>
|
||||
<cbc:ID>999992</cbc:ID>
|
||||
</cac:SellersItemIdentification>
|
||||
<cac:ClassifiedTaxCategory>
|
||||
<cbc:ID>S</cbc:ID>
|
||||
<cbc:Percent>6</cbc:Percent>
|
||||
<cac:TaxScheme>
|
||||
<cbc:ID>VAT</cbc:ID>
|
||||
</cac:TaxScheme>
|
||||
</cac:ClassifiedTaxCategory>
|
||||
</cac:Item>
|
||||
<cac:Price>
|
||||
<cbc:PriceAmount currencyID="EUR">17.02</cbc:PriceAmount>
|
||||
</cac:Price>
|
||||
</cac:InvoiceLine>
|
||||
<cac:InvoiceLine>
|
||||
<cbc:ID>20</cbc:ID>
|
||||
<cbc:InvoicedQuantity unitCode="EA">6</cbc:InvoicedQuantity>
|
||||
<cbc:LineExtensionAmount currencyID="EUR">-109.98</cbc:LineExtensionAmount>
|
||||
<cac:Item>
|
||||
<cbc:Name>FRITUUR VET 10 KG RETOUR</cbc:Name>
|
||||
<cac:SellersItemIdentification>
|
||||
<cbc:ID>175137</cbc:ID>
|
||||
</cac:SellersItemIdentification>
|
||||
<cac:ClassifiedTaxCategory>
|
||||
<cbc:ID>S</cbc:ID>
|
||||
<cbc:Percent>6</cbc:Percent>
|
||||
<cac:TaxScheme>
|
||||
<cbc:ID>VAT</cbc:ID>
|
||||
</cac:TaxScheme>
|
||||
</cac:ClassifiedTaxCategory>
|
||||
</cac:Item>
|
||||
<cac:Price>
|
||||
<cbc:PriceAmount currencyID="EUR">18.33</cbc:PriceAmount>
|
||||
</cac:Price>
|
||||
</cac:InvoiceLine>
|
||||
</Invoice>
|
||||
|
|
@ -0,0 +1,769 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!--
|
||||
~ Licensed to the Koordinierungsstelle für IT-Standards (KoSIT) under
|
||||
~ one or more contributor license agreements. See the NOTICE file
|
||||
~ distributed with this work for additional information
|
||||
~ regarding copyright ownership. KoSIT licenses this file
|
||||
~ to you under the Apache License, Version 2.0 (the
|
||||
~ "License"); you may not use this file except in compliance
|
||||
~ with the License. You may obtain a copy of the License at
|
||||
~
|
||||
~ http://www.apache.org/licenses/LICENSE-2.0
|
||||
~
|
||||
~ Unless required by applicable law or agreed to in writing,
|
||||
~ software distributed under the License is distributed on an
|
||||
~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||
~ KIND, either express or implied. See the License for the
|
||||
~ specific language governing permissions and limitations
|
||||
~ under the License.
|
||||
-->
|
||||
|
||||
<!-- ====================================================================== -->
|
||||
<!-- ===== CCTS Core Component Type Schema Module ===== -->
|
||||
<!-- ====================================================================== -->
|
||||
|
||||
<xsd:schema xmlns:ccts="urn:un:unece:uncefact:documentation:2"
|
||||
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
|
||||
targetNamespace="urn:un:unece:uncefact:data:specification:CoreComponentTypeSchemaModule:2"
|
||||
elementFormDefault="qualified"
|
||||
attributeFormDefault="unqualified">
|
||||
<!-- ===== Type Definitions ===== -->
|
||||
<!-- =================================================================== -->
|
||||
<!-- ===== CCT: AmountType ===== -->
|
||||
<!-- =================================================================== -->
|
||||
<xsd:complexType name="AmountType">
|
||||
<xsd:annotation>
|
||||
<xsd:documentation xml:lang="en">
|
||||
<ccts:UniqueID>UNDT000001</ccts:UniqueID>
|
||||
<ccts:CategoryCode>CCT</ccts:CategoryCode>
|
||||
<ccts:DictionaryEntryName>Amount. Type</ccts:DictionaryEntryName>
|
||||
<ccts:VersionID>1.0</ccts:VersionID>
|
||||
<ccts:Definition>A number of monetary units specified in a currency where the unit of the currency is
|
||||
explicit or implied.
|
||||
</ccts:Definition>
|
||||
<ccts:RepresentationTermName>Amount</ccts:RepresentationTermName>
|
||||
<ccts:PrimitiveType>decimal</ccts:PrimitiveType>
|
||||
</xsd:documentation>
|
||||
</xsd:annotation>
|
||||
<xsd:simpleContent>
|
||||
<xsd:extension base="xsd:decimal">
|
||||
<xsd:attribute name="currencyID" type="xsd:normalizedString" use="optional">
|
||||
<xsd:annotation>
|
||||
<xsd:documentation xml:lang="en">
|
||||
<ccts:UniqueID>UNDT000001-SC2</ccts:UniqueID>
|
||||
<ccts:CategoryCode>SC</ccts:CategoryCode>
|
||||
<ccts:DictionaryEntryName>Amount Currency. Identifier</ccts:DictionaryEntryName>
|
||||
<ccts:Definition>The currency of the amount.</ccts:Definition>
|
||||
<ccts:ObjectClass>Amount Currency</ccts:ObjectClass>
|
||||
<ccts:PropertyTermName>Identification</ccts:PropertyTermName>
|
||||
<ccts:RepresentationTermName>Identifier</ccts:RepresentationTermName>
|
||||
<ccts:PrimitiveType>string</ccts:PrimitiveType>
|
||||
<ccts:UsageRule>Reference UNECE Rec 9, using 3-letter alphabetic codes.</ccts:UsageRule>
|
||||
</xsd:documentation>
|
||||
</xsd:annotation>
|
||||
</xsd:attribute>
|
||||
<xsd:attribute name="currencyCodeListVersionID" type="xsd:normalizedString" use="optional">
|
||||
<xsd:annotation>
|
||||
<xsd:documentation xml:lang="en">
|
||||
<ccts:UniqueID>UNDT000001-SC3</ccts:UniqueID>
|
||||
<ccts:CategoryCode>SC</ccts:CategoryCode>
|
||||
<ccts:DictionaryEntryName>Amount Currency. Code List Version. Identifier
|
||||
</ccts:DictionaryEntryName>
|
||||
<ccts:Definition>The VersionID of the UN/ECE Rec9 code list.</ccts:Definition>
|
||||
<ccts:ObjectClass>Amount Currency</ccts:ObjectClass>
|
||||
<ccts:PropertyTermName>Code List Version</ccts:PropertyTermName>
|
||||
<ccts:RepresentationTermName>Identifier</ccts:RepresentationTermName>
|
||||
<ccts:PrimitiveType>string</ccts:PrimitiveType>
|
||||
</xsd:documentation>
|
||||
</xsd:annotation>
|
||||
</xsd:attribute>
|
||||
</xsd:extension>
|
||||
</xsd:simpleContent>
|
||||
</xsd:complexType>
|
||||
<!-- ===== CCT: BinaryObjectType ===== -->
|
||||
<!-- =================================================================== -->
|
||||
<xsd:complexType name="BinaryObjectType">
|
||||
<xsd:annotation>
|
||||
<xsd:documentation xml:lang="en">
|
||||
<ccts:UniqueID>UNDT000002</ccts:UniqueID>
|
||||
<ccts:CategoryCode>CCT</ccts:CategoryCode>
|
||||
<ccts:DictionaryEntryName>Binary Object. Type</ccts:DictionaryEntryName>
|
||||
<ccts:VersionID>1.0</ccts:VersionID>
|
||||
<ccts:Definition>A set of finite-length sequences of binary octets.</ccts:Definition>
|
||||
<ccts:RepresentationTermName>Binary Object</ccts:RepresentationTermName>
|
||||
<ccts:PrimitiveType>binary</ccts:PrimitiveType>
|
||||
</xsd:documentation>
|
||||
</xsd:annotation>
|
||||
<xsd:simpleContent>
|
||||
<xsd:extension base="xsd:base64Binary">
|
||||
<xsd:attribute name="format" type="xsd:string" use="optional">
|
||||
<xsd:annotation>
|
||||
<xsd:documentation xml:lang="en">
|
||||
<ccts:UniqueID>UNDT000002-SC2</ccts:UniqueID>
|
||||
<ccts:CategoryCode>SC</ccts:CategoryCode>
|
||||
<ccts:DictionaryEntryName>Binary Object. Format. Text</ccts:DictionaryEntryName>
|
||||
<ccts:Definition>The format of the binary content.</ccts:Definition>
|
||||
<ccts:ObjectClass>Binary Object</ccts:ObjectClass>
|
||||
<ccts:PropertyTermName>Format</ccts:PropertyTermName>
|
||||
<ccts:RepresentationTermName>Text</ccts:RepresentationTermName>
|
||||
<ccts:PrimitiveType>string</ccts:PrimitiveType>
|
||||
</xsd:documentation>
|
||||
</xsd:annotation>
|
||||
</xsd:attribute>
|
||||
<xsd:attribute name="mimeCode" type="xsd:normalizedString" use="optional">
|
||||
<xsd:annotation>
|
||||
<xsd:documentation xml:lang="en">
|
||||
<ccts:UniqueID>UNDT000002-SC3</ccts:UniqueID>
|
||||
<ccts:CategoryCode>SC</ccts:CategoryCode>
|
||||
<ccts:DictionaryEntryName>Binary Object. Mime. Code</ccts:DictionaryEntryName>
|
||||
<ccts:Definition>The mime type of the binary object.</ccts:Definition>
|
||||
<ccts:ObjectClass>Binary Object</ccts:ObjectClass>
|
||||
<ccts:PropertyTermName>Mime</ccts:PropertyTermName>
|
||||
<ccts:RepresentationTermName>Code</ccts:RepresentationTermName>
|
||||
<ccts:PrimitiveType>string</ccts:PrimitiveType>
|
||||
</xsd:documentation>
|
||||
</xsd:annotation>
|
||||
</xsd:attribute>
|
||||
<xsd:attribute name="encodingCode" type="xsd:normalizedString" use="optional">
|
||||
<xsd:annotation>
|
||||
<xsd:documentation xml:lang="en">
|
||||
<ccts:UniqueID>UNDT000002-SC4</ccts:UniqueID>
|
||||
<ccts:CategoryCode>SC</ccts:CategoryCode>
|
||||
<ccts:DictionaryEntryName>Binary Object. Encoding. Code</ccts:DictionaryEntryName>
|
||||
<ccts:Definition>Specifies the decoding algorithm of the binary object.</ccts:Definition>
|
||||
<ccts:ObjectClass>Binary Object</ccts:ObjectClass>
|
||||
<ccts:PropertyTermName>Encoding</ccts:PropertyTermName>
|
||||
<ccts:RepresentationTermName>Code</ccts:RepresentationTermName>
|
||||
<ccts:PrimitiveType>string</ccts:PrimitiveType>
|
||||
</xsd:documentation>
|
||||
</xsd:annotation>
|
||||
</xsd:attribute>
|
||||
<xsd:attribute name="characterSetCode" type="xsd:normalizedString" use="optional">
|
||||
<xsd:annotation>
|
||||
<xsd:documentation xml:lang="en">
|
||||
<ccts:UniqueID>UNDT000002-SC5</ccts:UniqueID>
|
||||
<ccts:CategoryCode>SC</ccts:CategoryCode>
|
||||
<ccts:DictionaryEntryName>Binary Object. Character Set. Code</ccts:DictionaryEntryName>
|
||||
<ccts:Definition>The character set of the binary object if the mime type is text.
|
||||
</ccts:Definition>
|
||||
<ccts:ObjectClass>Binary Object</ccts:ObjectClass>
|
||||
<ccts:PropertyTermName>Character Set</ccts:PropertyTermName>
|
||||
<ccts:RepresentationTermName>Code</ccts:RepresentationTermName>
|
||||
<ccts:PrimitiveType>string</ccts:PrimitiveType>
|
||||
</xsd:documentation>
|
||||
</xsd:annotation>
|
||||
</xsd:attribute>
|
||||
<xsd:attribute name="uri" type="xsd:anyURI" use="optional">
|
||||
<xsd:annotation>
|
||||
<xsd:documentation xml:lang="en">
|
||||
<ccts:UniqueID>UNDT000002-SC6</ccts:UniqueID>
|
||||
<ccts:CategoryCode>SC</ccts:CategoryCode>
|
||||
<ccts:DictionaryEntryName>Binary Object. Uniform Resource. Identifier
|
||||
</ccts:DictionaryEntryName>
|
||||
<ccts:Definition>The Uniform Resource Identifier that identifies where the binary object is
|
||||
located.
|
||||
</ccts:Definition>
|
||||
<ccts:ObjectClass>Binary Object</ccts:ObjectClass>
|
||||
<ccts:PropertyTermName>Uniform Resource Identifier</ccts:PropertyTermName>
|
||||
<ccts:RepresentationTermName>Identifier</ccts:RepresentationTermName>
|
||||
<ccts:PrimitiveType>string</ccts:PrimitiveType>
|
||||
</xsd:documentation>
|
||||
</xsd:annotation>
|
||||
</xsd:attribute>
|
||||
<xsd:attribute name="filename" type="xsd:string" use="optional">
|
||||
<xsd:annotation>
|
||||
<xsd:documentation xml:lang="en">
|
||||
<ccts:UniqueID>UNDT000002-SC7</ccts:UniqueID>
|
||||
<ccts:CategoryCode>SC</ccts:CategoryCode>
|
||||
<ccts:DictionaryEntryName>Binary Object. Filename.Text</ccts:DictionaryEntryName>
|
||||
<ccts:Definition>The filename of the binary object.</ccts:Definition>
|
||||
<ccts:ObjectClass>Binary Object</ccts:ObjectClass>
|
||||
<ccts:PropertyTermName>Filename</ccts:PropertyTermName>
|
||||
<ccts:RepresentationTermName>Text</ccts:RepresentationTermName>
|
||||
<ccts:PrimitiveType>string</ccts:PrimitiveType>
|
||||
</xsd:documentation>
|
||||
</xsd:annotation>
|
||||
</xsd:attribute>
|
||||
</xsd:extension>
|
||||
</xsd:simpleContent>
|
||||
</xsd:complexType>
|
||||
<!-- ===== CCT: CodeType ===== -->
|
||||
<!-- =================================================================== -->
|
||||
<xsd:complexType name="CodeType">
|
||||
<xsd:annotation>
|
||||
<xsd:documentation xml:lang="en">
|
||||
<ccts:UniqueID>UNDT000007</ccts:UniqueID>
|
||||
<ccts:CategoryCode>CCT</ccts:CategoryCode>
|
||||
<ccts:DictionaryEntryName>Code. Type</ccts:DictionaryEntryName>
|
||||
<ccts:VersionID>1.0</ccts:VersionID>
|
||||
<ccts:Definition>A character string (letters, figures, or symbols) that for brevity and/or languange
|
||||
independence may be used to represent or replace a definitive value or text of an attribute together
|
||||
with relevant supplementary information.
|
||||
</ccts:Definition>
|
||||
<ccts:RepresentationTermName>Code</ccts:RepresentationTermName>
|
||||
<ccts:PrimitiveType>string</ccts:PrimitiveType>
|
||||
<ccts:UsageRule>Should not be used if the character string identifies an instance of an object class or
|
||||
an object in the real world, in which case the Identifier. Type should be used.
|
||||
</ccts:UsageRule>
|
||||
</xsd:documentation>
|
||||
</xsd:annotation>
|
||||
<xsd:simpleContent>
|
||||
<xsd:extension base="xsd:normalizedString">
|
||||
<xsd:attribute name="listID" type="xsd:normalizedString" use="optional">
|
||||
<xsd:annotation>
|
||||
<xsd:documentation xml:lang="en">
|
||||
<ccts:UniqueID>UNDT000007-SC2</ccts:UniqueID>
|
||||
<ccts:CategoryCode>SC</ccts:CategoryCode>
|
||||
<ccts:DictionaryEntryName>Code List. Identifier</ccts:DictionaryEntryName>
|
||||
<ccts:Definition>The identification of a list of codes.</ccts:Definition>
|
||||
<ccts:ObjectClass>Code List</ccts:ObjectClass>
|
||||
<ccts:PropertyTermName>Identification</ccts:PropertyTermName>
|
||||
<ccts:RepresentationTermName>Identifier</ccts:RepresentationTermName>
|
||||
<ccts:PrimitiveType>string</ccts:PrimitiveType>
|
||||
</xsd:documentation>
|
||||
</xsd:annotation>
|
||||
</xsd:attribute>
|
||||
<xsd:attribute name="listAgencyID" type="xsd:normalizedString" use="optional">
|
||||
<xsd:annotation>
|
||||
<xsd:documentation xml:lang="en">
|
||||
<ccts:UniqueID>UNDT000007-SC3</ccts:UniqueID>
|
||||
<ccts:CategoryCode>SC</ccts:CategoryCode>
|
||||
<ccts:DictionaryEntryName>Code List. Agency. Identifier</ccts:DictionaryEntryName>
|
||||
<ccts:Definition>An agency that maintains one or more lists of codes.</ccts:Definition>
|
||||
<ccts:ObjectClass>Code List</ccts:ObjectClass>
|
||||
<ccts:PropertyTermName>Agency</ccts:PropertyTermName>
|
||||
<ccts:RepresentationTermName>Identifier</ccts:RepresentationTermName>
|
||||
<ccts:PrimitiveType>string</ccts:PrimitiveType>
|
||||
<ccts:UsageRule>Defaults to the UN/EDIFACT data element 3055 code list.</ccts:UsageRule>
|
||||
</xsd:documentation>
|
||||
</xsd:annotation>
|
||||
</xsd:attribute>
|
||||
<xsd:attribute name="listAgencyName" type="xsd:string" use="optional">
|
||||
<xsd:annotation>
|
||||
<xsd:documentation xml:lang="en">
|
||||
<ccts:UniqueID>UNDT000007-SC4</ccts:UniqueID>
|
||||
<ccts:CategoryCode>SC</ccts:CategoryCode>
|
||||
<ccts:DictionaryEntryName>Code List. Agency Name. Text</ccts:DictionaryEntryName>
|
||||
<ccts:Definition>The name of the agency that maintains the list of codes.</ccts:Definition>
|
||||
<ccts:ObjectClass>Code List</ccts:ObjectClass>
|
||||
<ccts:PropertyTermName>Agency Name</ccts:PropertyTermName>
|
||||
<ccts:RepresentationTermName>Text</ccts:RepresentationTermName>
|
||||
<ccts:PrimitiveType>string</ccts:PrimitiveType>
|
||||
</xsd:documentation>
|
||||
</xsd:annotation>
|
||||
</xsd:attribute>
|
||||
<xsd:attribute name="listName" type="xsd:string" use="optional">
|
||||
<xsd:annotation>
|
||||
<xsd:documentation xml:lang="en">
|
||||
<ccts:UniqueID>UNDT000007-SC5</ccts:UniqueID>
|
||||
<ccts:CategoryCode>SC</ccts:CategoryCode>
|
||||
<ccts:DictionaryEntryName>Code List. Name. Text</ccts:DictionaryEntryName>
|
||||
<ccts:Definition>The name of a list of codes.</ccts:Definition>
|
||||
<ccts:ObjectClass>Code List</ccts:ObjectClass>
|
||||
<ccts:PropertyTermName>Name</ccts:PropertyTermName>
|
||||
<ccts:RepresentationTermName>Text</ccts:RepresentationTermName>
|
||||
<ccts:PrimitiveType>string</ccts:PrimitiveType>
|
||||
</xsd:documentation>
|
||||
</xsd:annotation>
|
||||
</xsd:attribute>
|
||||
<xsd:attribute name="listVersionID" type="xsd:normalizedString" use="optional">
|
||||
<xsd:annotation>
|
||||
<xsd:documentation xml:lang="en">
|
||||
<ccts:UniqueID>UNDT000007-SC6</ccts:UniqueID>
|
||||
<ccts:CategoryCode>SC</ccts:CategoryCode>
|
||||
<ccts:DictionaryEntryName>Code List. Version. Identifier</ccts:DictionaryEntryName>
|
||||
<ccts:Definition>The version of the list of codes.</ccts:Definition>
|
||||
<ccts:ObjectClass>Code List</ccts:ObjectClass>
|
||||
<ccts:PropertyTermName>Version</ccts:PropertyTermName>
|
||||
<ccts:RepresentationTermName>Identifier</ccts:RepresentationTermName>
|
||||
<ccts:PrimitiveType>string</ccts:PrimitiveType>
|
||||
</xsd:documentation>
|
||||
</xsd:annotation>
|
||||
</xsd:attribute>
|
||||
<xsd:attribute name="name" type="xsd:string" use="optional">
|
||||
<xsd:annotation>
|
||||
<xsd:documentation xml:lang="en">
|
||||
<ccts:UniqueID>UNDT000007-SC7</ccts:UniqueID>
|
||||
<ccts:CategoryCode>SC</ccts:CategoryCode>
|
||||
<ccts:DictionaryEntryName>Code. Name. Text</ccts:DictionaryEntryName>
|
||||
<ccts:Definition>The textual equivalent of the code content component.</ccts:Definition>
|
||||
<ccts:ObjectClass>Code</ccts:ObjectClass>
|
||||
<ccts:PropertyTermName>Name</ccts:PropertyTermName>
|
||||
<ccts:RepresentationTermName>Text</ccts:RepresentationTermName>
|
||||
<ccts:PrimitiveType>string</ccts:PrimitiveType>
|
||||
</xsd:documentation>
|
||||
</xsd:annotation>
|
||||
</xsd:attribute>
|
||||
<xsd:attribute name="languageID" type="xsd:language" use="optional">
|
||||
<xsd:annotation>
|
||||
<xsd:documentation xml:lang="en">
|
||||
<ccts:UniqueID>UNDT000007-SC8</ccts:UniqueID>
|
||||
<ccts:CategoryCode>SC</ccts:CategoryCode>
|
||||
<ccts:DictionaryEntryName>Language. Identifier</ccts:DictionaryEntryName>
|
||||
<ccts:Definition>The identifier of the language used in the code name.</ccts:Definition>
|
||||
<ccts:ObjectClass>Language</ccts:ObjectClass>
|
||||
<ccts:PropertyTermName>Identification</ccts:PropertyTermName>
|
||||
<ccts:RepresentationTermName>Identifier</ccts:RepresentationTermName>
|
||||
<ccts:PrimitiveType>string</ccts:PrimitiveType>
|
||||
</xsd:documentation>
|
||||
</xsd:annotation>
|
||||
</xsd:attribute>
|
||||
<xsd:attribute name="listURI" type="xsd:anyURI" use="optional">
|
||||
<xsd:annotation>
|
||||
<xsd:documentation xml:lang="en">
|
||||
<ccts:UniqueID>UNDT000007-SC9</ccts:UniqueID>
|
||||
<ccts:CategoryCode>SC</ccts:CategoryCode>
|
||||
<ccts:DictionaryEntryName>Code List. Uniform Resource. Identifier</ccts:DictionaryEntryName>
|
||||
<ccts:Definition>The Uniform Resource Identifier that identifies where the code list is
|
||||
located.
|
||||
</ccts:Definition>
|
||||
<ccts:ObjectClass>Code List</ccts:ObjectClass>
|
||||
<ccts:PropertyTermName>Uniform Resource Identifier</ccts:PropertyTermName>
|
||||
<ccts:RepresentationTermName>Identifier</ccts:RepresentationTermName>
|
||||
<ccts:PrimitiveType>string</ccts:PrimitiveType>
|
||||
</xsd:documentation>
|
||||
</xsd:annotation>
|
||||
</xsd:attribute>
|
||||
<xsd:attribute name="listSchemeURI" type="xsd:anyURI" use="optional">
|
||||
<xsd:annotation>
|
||||
<xsd:documentation xml:lang="en">
|
||||
<ccts:UniqueID>UNDT000007-SC10</ccts:UniqueID>
|
||||
<ccts:CategoryCode>SC</ccts:CategoryCode>
|
||||
<ccts:DictionaryEntryName>Code List Scheme. Uniform Resource. Identifier
|
||||
</ccts:DictionaryEntryName>
|
||||
<ccts:Definition>The Uniform Resource Identifier that identifies where the code list scheme
|
||||
is located.
|
||||
</ccts:Definition>
|
||||
<ccts:ObjectClass>Code List Scheme</ccts:ObjectClass>
|
||||
<ccts:PropertyTermName>Uniform Resource Identifier</ccts:PropertyTermName>
|
||||
<ccts:RepresentationTermName>Identifier</ccts:RepresentationTermName>
|
||||
<ccts:PrimitiveType>string</ccts:PrimitiveType>
|
||||
</xsd:documentation>
|
||||
</xsd:annotation>
|
||||
</xsd:attribute>
|
||||
</xsd:extension>
|
||||
</xsd:simpleContent>
|
||||
</xsd:complexType>
|
||||
<!-- ===== CCT: DateTimeType ===== -->
|
||||
<!-- =================================================================== -->
|
||||
<xsd:complexType name="DateTimeType">
|
||||
<xsd:annotation>
|
||||
<xsd:documentation xml:lang="en">
|
||||
<ccts:UniqueID>UNDT000008</ccts:UniqueID>
|
||||
<ccts:CategoryCode>CCT</ccts:CategoryCode>
|
||||
<ccts:DictionaryEntryName>Date Time. Type</ccts:DictionaryEntryName>
|
||||
<ccts:VersionID>1.0</ccts:VersionID>
|
||||
<ccts:Definition>A particular point in the progression of time together with the relevant supplementary
|
||||
information.
|
||||
</ccts:Definition>
|
||||
<ccts:RepresentationTermName>Date Time</ccts:RepresentationTermName>
|
||||
<ccts:PrimitiveType>string</ccts:PrimitiveType>
|
||||
<ccts:UsageRule>Can be used for a date and/or time.</ccts:UsageRule>
|
||||
</xsd:documentation>
|
||||
</xsd:annotation>
|
||||
<xsd:simpleContent>
|
||||
<xsd:extension base="xsd:string">
|
||||
<xsd:attribute name="format" type="xsd:string" use="optional">
|
||||
<xsd:annotation>
|
||||
<xsd:documentation xml:lang="en">
|
||||
<ccts:UniqueID>UNDT000008-SC1</ccts:UniqueID>
|
||||
<ccts:CategoryCode>SC</ccts:CategoryCode>
|
||||
<ccts:DictionaryEntryName>Date Time. Format. Text</ccts:DictionaryEntryName>
|
||||
<ccts:Definition>The format of the date time content</ccts:Definition>
|
||||
<ccts:ObjectClass>Date Time</ccts:ObjectClass>
|
||||
<ccts:PropertyTermName>Format</ccts:PropertyTermName>
|
||||
<ccts:RepresentationTermName>Text</ccts:RepresentationTermName>
|
||||
<ccts:PrimitiveType>string</ccts:PrimitiveType>
|
||||
</xsd:documentation>
|
||||
</xsd:annotation>
|
||||
</xsd:attribute>
|
||||
</xsd:extension>
|
||||
</xsd:simpleContent>
|
||||
</xsd:complexType>
|
||||
<!-- ===== CCT: IdentifierType ===== -->
|
||||
<!-- =================================================================== -->
|
||||
<xsd:complexType name="IdentifierType">
|
||||
<xsd:annotation>
|
||||
<xsd:documentation xml:lang="en">
|
||||
<ccts:UniqueID>UNDT000011</ccts:UniqueID>
|
||||
<ccts:CategoryCode>CCT</ccts:CategoryCode>
|
||||
<ccts:DictionaryEntryName>Identifier. Type</ccts:DictionaryEntryName>
|
||||
<ccts:VersionID>1.0</ccts:VersionID>
|
||||
<ccts:Definition>A character string to identify and distinguish uniquely, one instance of an object in
|
||||
an identification scheme from all other objects in the same scheme together with relevant
|
||||
supplementary information.
|
||||
</ccts:Definition>
|
||||
<ccts:RepresentationTermName>Identifier</ccts:RepresentationTermName>
|
||||
<ccts:PrimitiveType>string</ccts:PrimitiveType>
|
||||
</xsd:documentation>
|
||||
</xsd:annotation>
|
||||
<xsd:simpleContent>
|
||||
<xsd:extension base="xsd:normalizedString">
|
||||
<xsd:attribute name="schemeID" type="xsd:normalizedString" use="optional">
|
||||
<xsd:annotation>
|
||||
<xsd:documentation xml:lang="en">
|
||||
<ccts:UniqueID>UNDT000011-SC2</ccts:UniqueID>
|
||||
<ccts:CategoryCode>SC</ccts:CategoryCode>
|
||||
<ccts:DictionaryEntryName>Identification Scheme. Identifier</ccts:DictionaryEntryName>
|
||||
<ccts:Definition>The identification of the identification scheme.</ccts:Definition>
|
||||
<ccts:ObjectClass>Identification Scheme</ccts:ObjectClass>
|
||||
<ccts:PropertyTermName>Identification</ccts:PropertyTermName>
|
||||
<ccts:RepresentationTermName>Identifier</ccts:RepresentationTermName>
|
||||
<ccts:PrimitiveType>string</ccts:PrimitiveType>
|
||||
</xsd:documentation>
|
||||
</xsd:annotation>
|
||||
</xsd:attribute>
|
||||
<xsd:attribute name="schemeName" type="xsd:string" use="optional">
|
||||
<xsd:annotation>
|
||||
<xsd:documentation xml:lang="en">
|
||||
<ccts:UniqueID>UNDT000011-SC3</ccts:UniqueID>
|
||||
<ccts:CategoryCode>SC</ccts:CategoryCode>
|
||||
<ccts:DictionaryEntryName>Identification Scheme. Name. Text</ccts:DictionaryEntryName>
|
||||
<ccts:Definition>The name of the identification scheme.</ccts:Definition>
|
||||
<ccts:ObjectClass>Identification Scheme</ccts:ObjectClass>
|
||||
<ccts:PropertyTermName>Name</ccts:PropertyTermName>
|
||||
<ccts:RepresentationTermName>Text</ccts:RepresentationTermName>
|
||||
<ccts:PrimitiveType>string</ccts:PrimitiveType>
|
||||
</xsd:documentation>
|
||||
</xsd:annotation>
|
||||
</xsd:attribute>
|
||||
<xsd:attribute name="schemeAgencyID" type="xsd:normalizedString" use="optional">
|
||||
<xsd:annotation>
|
||||
<xsd:documentation xml:lang="en">
|
||||
<ccts:UniqueID>UNDT000011-SC4</ccts:UniqueID>
|
||||
<ccts:CategoryCode>SC</ccts:CategoryCode>
|
||||
<ccts:DictionaryEntryName>Identification Scheme Agency. Identifier
|
||||
</ccts:DictionaryEntryName>
|
||||
<ccts:Definition>The identification of the agency that maintains the identification
|
||||
scheme.
|
||||
</ccts:Definition>
|
||||
<ccts:ObjectClass>Identification Scheme Agency</ccts:ObjectClass>
|
||||
<ccts:PropertyTermName>Identification</ccts:PropertyTermName>
|
||||
<ccts:RepresentationTermName>Identifier</ccts:RepresentationTermName>
|
||||
<ccts:PrimitiveType>string</ccts:PrimitiveType>
|
||||
<ccts:UsageRule>Defaults to the UN/EDIFACT data element 3055 code list.</ccts:UsageRule>
|
||||
</xsd:documentation>
|
||||
</xsd:annotation>
|
||||
</xsd:attribute>
|
||||
<xsd:attribute name="schemeAgencyName" type="xsd:string" use="optional">
|
||||
<xsd:annotation>
|
||||
<xsd:documentation xml:lang="en">
|
||||
<ccts:UniqueID>UNDT000011-SC5</ccts:UniqueID>
|
||||
<ccts:CategoryCode>SC</ccts:CategoryCode>
|
||||
<ccts:DictionaryEntryName>Identification Scheme Agency. Name. Text
|
||||
</ccts:DictionaryEntryName>
|
||||
<ccts:Definition>The name of the agency that maintains the identification scheme.
|
||||
</ccts:Definition>
|
||||
<ccts:ObjectClass>Identification Scheme Agency</ccts:ObjectClass>
|
||||
<ccts:PropertyTermName>Agency Name</ccts:PropertyTermName>
|
||||
<ccts:RepresentationTermName>Text</ccts:RepresentationTermName>
|
||||
<ccts:PrimitiveType>string</ccts:PrimitiveType>
|
||||
</xsd:documentation>
|
||||
</xsd:annotation>
|
||||
</xsd:attribute>
|
||||
<xsd:attribute name="schemeVersionID" type="xsd:normalizedString" use="optional">
|
||||
<xsd:annotation>
|
||||
<xsd:documentation xml:lang="en">
|
||||
<ccts:UniqueID>UNDT000011-SC6</ccts:UniqueID>
|
||||
<ccts:CategoryCode>SC</ccts:CategoryCode>
|
||||
<ccts:DictionaryEntryName>Identification Scheme. Version. Identifier
|
||||
</ccts:DictionaryEntryName>
|
||||
<ccts:Definition>The version of the identification scheme.</ccts:Definition>
|
||||
<ccts:ObjectClass>Identification Scheme</ccts:ObjectClass>
|
||||
<ccts:PropertyTermName>Version</ccts:PropertyTermName>
|
||||
<ccts:RepresentationTermName>Identifier</ccts:RepresentationTermName>
|
||||
<ccts:PrimitiveType>string</ccts:PrimitiveType>
|
||||
</xsd:documentation>
|
||||
</xsd:annotation>
|
||||
</xsd:attribute>
|
||||
<xsd:attribute name="schemeDataURI" type="xsd:anyURI" use="optional">
|
||||
<xsd:annotation>
|
||||
<xsd:documentation xml:lang="en">
|
||||
<ccts:UniqueID>UNDT000011-SC7</ccts:UniqueID>
|
||||
<ccts:CategoryCode>SC</ccts:CategoryCode>
|
||||
<ccts:DictionaryEntryName>Identification Scheme Data. Uniform Resource. Identifier
|
||||
</ccts:DictionaryEntryName>
|
||||
<ccts:Definition>The Uniform Resource Identifier that identifies where the identification
|
||||
scheme data is located.
|
||||
</ccts:Definition>
|
||||
<ccts:ObjectClass>Identification Scheme Data</ccts:ObjectClass>
|
||||
<ccts:PropertyTermName>Uniform Resource Identifier</ccts:PropertyTermName>
|
||||
<ccts:RepresentationTermName>Identifier</ccts:RepresentationTermName>
|
||||
<ccts:PrimitiveType>string</ccts:PrimitiveType>
|
||||
</xsd:documentation>
|
||||
</xsd:annotation>
|
||||
</xsd:attribute>
|
||||
<xsd:attribute name="schemeURI" type="xsd:anyURI" use="optional">
|
||||
<xsd:annotation>
|
||||
<xsd:documentation xml:lang="en">
|
||||
<ccts:UniqueID>UNDT000011-SC8</ccts:UniqueID>
|
||||
<ccts:CategoryCode>SC</ccts:CategoryCode>
|
||||
<ccts:DictionaryEntryName>Identification Scheme. Uniform Resource. Identifier
|
||||
</ccts:DictionaryEntryName>
|
||||
<ccts:Definition>The Uniform Resource Identifier that identifies where the identification
|
||||
scheme is located.
|
||||
</ccts:Definition>
|
||||
<ccts:ObjectClass>Identification Scheme</ccts:ObjectClass>
|
||||
<ccts:PropertyTermName>Uniform Resource Identifier</ccts:PropertyTermName>
|
||||
<ccts:RepresentationTermName>Identifier</ccts:RepresentationTermName>
|
||||
<ccts:PrimitiveType>string</ccts:PrimitiveType>
|
||||
</xsd:documentation>
|
||||
</xsd:annotation>
|
||||
</xsd:attribute>
|
||||
</xsd:extension>
|
||||
</xsd:simpleContent>
|
||||
</xsd:complexType>
|
||||
<!-- ===== CCT: IndicatorType ===== -->
|
||||
<!-- =================================================================== -->
|
||||
<xsd:complexType name="IndicatorType">
|
||||
<xsd:annotation>
|
||||
<xsd:documentation xml:lang="en">
|
||||
<ccts:UniqueID>UNDT000012</ccts:UniqueID>
|
||||
<ccts:CategoryCode>CCT</ccts:CategoryCode>
|
||||
<ccts:DictionaryEntryName>Indicator. Type</ccts:DictionaryEntryName>
|
||||
<ccts:VersionID>1.0</ccts:VersionID>
|
||||
<ccts:Definition>A list of two mutually exclusive Boolean values that express the only possible states
|
||||
of a Property.
|
||||
</ccts:Definition>
|
||||
<ccts:RepresentationTermName>Indicator</ccts:RepresentationTermName>
|
||||
<ccts:PrimitiveType>string</ccts:PrimitiveType>
|
||||
</xsd:documentation>
|
||||
</xsd:annotation>
|
||||
<xsd:simpleContent>
|
||||
<xsd:extension base="xsd:string">
|
||||
<xsd:attribute name="format" type="xsd:string" use="optional">
|
||||
<xsd:annotation>
|
||||
<xsd:documentation xml:lang="en">
|
||||
<ccts:UniqueID>UNDT000012-SC2</ccts:UniqueID>
|
||||
<ccts:CategoryCode>SC</ccts:CategoryCode>
|
||||
<ccts:DictionaryEntryName>Indicator. Format. Text</ccts:DictionaryEntryName>
|
||||
<ccts:Definition>Whether the indicator is numeric, textual or binary.</ccts:Definition>
|
||||
<ccts:ObjectClass>Indicator</ccts:ObjectClass>
|
||||
<ccts:PropertyTermName>Format</ccts:PropertyTermName>
|
||||
<ccts:RepresentationTermName>Text</ccts:RepresentationTermName>
|
||||
<ccts:PrimitiveType>string</ccts:PrimitiveType>
|
||||
</xsd:documentation>
|
||||
</xsd:annotation>
|
||||
</xsd:attribute>
|
||||
</xsd:extension>
|
||||
</xsd:simpleContent>
|
||||
</xsd:complexType>
|
||||
<!-- ===== CCT: MeasureType ===== -->
|
||||
<!-- =================================================================== -->
|
||||
<xsd:complexType name="MeasureType">
|
||||
<xsd:annotation>
|
||||
<xsd:documentation xml:lang="en">
|
||||
<ccts:UniqueID>UNDT000013</ccts:UniqueID>
|
||||
<ccts:CategoryCode>CCT</ccts:CategoryCode>
|
||||
<ccts:DictionaryEntryName>Measure. Type</ccts:DictionaryEntryName>
|
||||
<ccts:VersionID>1.0</ccts:VersionID>
|
||||
<ccts:Definition>A numeric value determined by measuring an object along with the specified unit of
|
||||
measure.
|
||||
</ccts:Definition>
|
||||
<ccts:RepresentationTermName>Measure</ccts:RepresentationTermName>
|
||||
<ccts:PrimitiveType>decimal</ccts:PrimitiveType>
|
||||
</xsd:documentation>
|
||||
</xsd:annotation>
|
||||
<xsd:simpleContent>
|
||||
<xsd:extension base="xsd:decimal">
|
||||
<xsd:attribute name="unitCode" type="xsd:normalizedString" use="optional">
|
||||
<xsd:annotation>
|
||||
<xsd:documentation xml:lang="en">
|
||||
<ccts:UniqueID>UNDT000013-SC2</ccts:UniqueID>
|
||||
<ccts:CategoryCode>SC</ccts:CategoryCode>
|
||||
<ccts:DictionaryEntryName>Measure Unit. Code</ccts:DictionaryEntryName>
|
||||
<ccts:Definition>The type of unit of measure.</ccts:Definition>
|
||||
<ccts:ObjectClass>Measure Unit</ccts:ObjectClass>
|
||||
<ccts:PropertyTermName>Code</ccts:PropertyTermName>
|
||||
<ccts:RepresentationTermName>Code</ccts:RepresentationTermName>
|
||||
<ccts:PrimitiveType>string</ccts:PrimitiveType>
|
||||
<ccts:UsageRule>Reference UNECE Rec. 20 and X12 355</ccts:UsageRule>
|
||||
</xsd:documentation>
|
||||
</xsd:annotation>
|
||||
</xsd:attribute>
|
||||
<xsd:attribute name="unitCodeListVersionID" type="xsd:normalizedString" use="optional">
|
||||
<xsd:annotation>
|
||||
<xsd:documentation xml:lang="en">
|
||||
<ccts:UniqueID>UNDT000013-SC3</ccts:UniqueID>
|
||||
<ccts:CategoryCode>SC</ccts:CategoryCode>
|
||||
<ccts:DictionaryEntryName>Measure Unit. Code List Version. Identifier
|
||||
</ccts:DictionaryEntryName>
|
||||
<ccts:Definition>The version of the measure unit code list.</ccts:Definition>
|
||||
<ccts:ObjectClass>Measure Unit</ccts:ObjectClass>
|
||||
<ccts:PropertyTermName>Code List Version</ccts:PropertyTermName>
|
||||
<ccts:RepresentationTermName>Identifier</ccts:RepresentationTermName>
|
||||
<ccts:PrimitiveType>string</ccts:PrimitiveType>
|
||||
</xsd:documentation>
|
||||
</xsd:annotation>
|
||||
</xsd:attribute>
|
||||
</xsd:extension>
|
||||
</xsd:simpleContent>
|
||||
</xsd:complexType>
|
||||
<!-- ===== CCT: NumericType ===== -->
|
||||
<!-- =================================================================== -->
|
||||
<xsd:complexType name="NumericType">
|
||||
<xsd:annotation>
|
||||
<xsd:documentation xml:lang="en">
|
||||
<ccts:UniqueID>UNDT000014</ccts:UniqueID>
|
||||
<ccts:CategoryCode>CCT</ccts:CategoryCode>
|
||||
<ccts:DictionaryEntryName>Numeric. Type</ccts:DictionaryEntryName>
|
||||
<ccts:VersionID>1.0</ccts:VersionID>
|
||||
<ccts:Definition>Numeric information that is assigned or is determined by calculation, counting, or
|
||||
sequencing. It does not require a unit of quantity or unit of measure.
|
||||
</ccts:Definition>
|
||||
<ccts:RepresentationTermName>Numeric</ccts:RepresentationTermName>
|
||||
<ccts:PrimitiveType>string</ccts:PrimitiveType>
|
||||
</xsd:documentation>
|
||||
</xsd:annotation>
|
||||
<xsd:simpleContent>
|
||||
<xsd:extension base="xsd:decimal">
|
||||
<xsd:attribute name="format" type="xsd:string" use="optional">
|
||||
<xsd:annotation>
|
||||
<xsd:documentation xml:lang="en">
|
||||
<ccts:UniqueID>UNDT000014-SC2</ccts:UniqueID>
|
||||
<ccts:CategoryCode>SC</ccts:CategoryCode>
|
||||
<ccts:DictionaryEntryName>Numeric. Format. Text</ccts:DictionaryEntryName>
|
||||
<ccts:Definition>Whether the number is an integer, decimal, real number or percentage.
|
||||
</ccts:Definition>
|
||||
<ccts:ObjectClass>Numeric</ccts:ObjectClass>
|
||||
<ccts:PropertyTermName>Format</ccts:PropertyTermName>
|
||||
<ccts:RepresentationTermName>Text</ccts:RepresentationTermName>
|
||||
<ccts:PrimitiveType>string</ccts:PrimitiveType>
|
||||
</xsd:documentation>
|
||||
</xsd:annotation>
|
||||
</xsd:attribute>
|
||||
</xsd:extension>
|
||||
</xsd:simpleContent>
|
||||
</xsd:complexType>
|
||||
<!-- ===== CCT: QuantityType ===== -->
|
||||
<!-- =================================================================== -->
|
||||
<xsd:complexType name="QuantityType">
|
||||
<xsd:annotation>
|
||||
<xsd:documentation xml:lang="en">
|
||||
<ccts:UniqueID>UNDT000018</ccts:UniqueID>
|
||||
<ccts:CategoryCode>CCT</ccts:CategoryCode>
|
||||
<ccts:DictionaryEntryName>Quantity. Type</ccts:DictionaryEntryName>
|
||||
<ccts:VersionID>1.0</ccts:VersionID>
|
||||
<ccts:Definition>A counted number of non-monetary units possibly including fractions.</ccts:Definition>
|
||||
<ccts:RepresentationTermName>Quantity</ccts:RepresentationTermName>
|
||||
<ccts:PrimitiveType>decimal</ccts:PrimitiveType>
|
||||
</xsd:documentation>
|
||||
</xsd:annotation>
|
||||
<xsd:simpleContent>
|
||||
<xsd:extension base="xsd:decimal">
|
||||
<xsd:attribute name="unitCode" type="xsd:normalizedString" use="optional">
|
||||
<xsd:annotation>
|
||||
<xsd:documentation xml:lang="en">
|
||||
<ccts:UniqueID>UNDT000018-SC2</ccts:UniqueID>
|
||||
<ccts:CategoryCode>SC</ccts:CategoryCode>
|
||||
<ccts:DictionaryEntryName>Quantity. Unit. Code</ccts:DictionaryEntryName>
|
||||
<ccts:Definition>The unit of the quantity</ccts:Definition>
|
||||
<ccts:ObjectClass>Quantity</ccts:ObjectClass>
|
||||
<ccts:PropertyTermName>Unit Code</ccts:PropertyTermName>
|
||||
<ccts:RepresentationTermName>Code</ccts:RepresentationTermName>
|
||||
<ccts:PrimitiveType>string</ccts:PrimitiveType>
|
||||
</xsd:documentation>
|
||||
</xsd:annotation>
|
||||
</xsd:attribute>
|
||||
<xsd:attribute name="unitCodeListID" type="xsd:normalizedString" use="optional">
|
||||
<xsd:annotation>
|
||||
<xsd:documentation xml:lang="en">
|
||||
<ccts:UniqueID>UNDT000018-SC3</ccts:UniqueID>
|
||||
<ccts:CategoryCode>SC</ccts:CategoryCode>
|
||||
<ccts:DictionaryEntryName>Quantity Unit. Code List. Identifier</ccts:DictionaryEntryName>
|
||||
<ccts:Definition>The quantity unit code list.</ccts:Definition>
|
||||
<ccts:ObjectClass>Quantity Unit</ccts:ObjectClass>
|
||||
<ccts:PropertyTermName>Code List</ccts:PropertyTermName>
|
||||
<ccts:RepresentationTermName>Identifier</ccts:RepresentationTermName>
|
||||
<ccts:PrimitiveType>string</ccts:PrimitiveType>
|
||||
</xsd:documentation>
|
||||
</xsd:annotation>
|
||||
</xsd:attribute>
|
||||
<xsd:attribute name="unitCodeListAgencyID" type="xsd:normalizedString" use="optional">
|
||||
<xsd:annotation>
|
||||
<xsd:documentation xml:lang="en">
|
||||
<ccts:UniqueID>UNDT000018-SC4</ccts:UniqueID>
|
||||
<ccts:CategoryCode>SC</ccts:CategoryCode>
|
||||
<ccts:DictionaryEntryName>Quantity Unit. Code List Agency. Identifier
|
||||
</ccts:DictionaryEntryName>
|
||||
<ccts:Definition>The identification of the agency that maintains the quantity unit code
|
||||
list
|
||||
</ccts:Definition>
|
||||
<ccts:ObjectClass>Quantity Unit</ccts:ObjectClass>
|
||||
<ccts:PropertyTermName>Code List Agency</ccts:PropertyTermName>
|
||||
<ccts:RepresentationTermName>Identifier</ccts:RepresentationTermName>
|
||||
<ccts:PrimitiveType>string</ccts:PrimitiveType>
|
||||
<ccts:UsageRule>Defaults to the UN/EDIFACT data element 3055 code list.</ccts:UsageRule>
|
||||
</xsd:documentation>
|
||||
</xsd:annotation>
|
||||
</xsd:attribute>
|
||||
<xsd:attribute name="unitCodeListAgencyName" type="xsd:string" use="optional">
|
||||
<xsd:annotation>
|
||||
<xsd:documentation xml:lang="en">
|
||||
<ccts:UniqueID>UNDT000018-SC5</ccts:UniqueID>
|
||||
<ccts:CategoryCode>SC</ccts:CategoryCode>
|
||||
<ccts:DictionaryEntryName>Quantity Unit. Code List Agency Name. Text
|
||||
</ccts:DictionaryEntryName>
|
||||
<ccts:Definition>The name of the agency which maintains the quantity unit code list.
|
||||
</ccts:Definition>
|
||||
<ccts:ObjectClass>Quantity Unit</ccts:ObjectClass>
|
||||
<ccts:PropertyTermName>Code List Agency Name</ccts:PropertyTermName>
|
||||
<ccts:RepresentationTermName>Text</ccts:RepresentationTermName>
|
||||
<ccts:PrimitiveType>string</ccts:PrimitiveType>
|
||||
</xsd:documentation>
|
||||
</xsd:annotation>
|
||||
</xsd:attribute>
|
||||
</xsd:extension>
|
||||
</xsd:simpleContent>
|
||||
</xsd:complexType>
|
||||
<!-- ===== CCT: TextType ===== -->
|
||||
<!-- =================================================================== -->
|
||||
<xsd:complexType name="TextType">
|
||||
<xsd:annotation>
|
||||
<xsd:documentation xml:lang="en">
|
||||
<ccts:UniqueID>UNDT000019</ccts:UniqueID>
|
||||
<ccts:CategoryCode>CCT</ccts:CategoryCode>
|
||||
<ccts:DictionaryEntryName>Text. Type</ccts:DictionaryEntryName>
|
||||
<ccts:VersionID>1.0</ccts:VersionID>
|
||||
<ccts:Definition>A character string (i.e. a finite set of characters) generally in the form of words of
|
||||
a language.
|
||||
</ccts:Definition>
|
||||
<ccts:RepresentationTermName>Text</ccts:RepresentationTermName>
|
||||
<ccts:PrimitiveType>string</ccts:PrimitiveType>
|
||||
</xsd:documentation>
|
||||
</xsd:annotation>
|
||||
<xsd:simpleContent>
|
||||
<xsd:extension base="xsd:string">
|
||||
<xsd:attribute name="languageID" type="xsd:language" use="optional">
|
||||
<xsd:annotation>
|
||||
<xsd:documentation xml:lang="en">
|
||||
<ccts:UniqueID>UNDT000019-SC2</ccts:UniqueID>
|
||||
<ccts:CategoryCode>SC</ccts:CategoryCode>
|
||||
<ccts:DictionaryEntryName>Language. Identifier</ccts:DictionaryEntryName>
|
||||
<ccts:Definition>The identifier of the language used in the content component.
|
||||
</ccts:Definition>
|
||||
<ccts:ObjectClass>Language</ccts:ObjectClass>
|
||||
<ccts:PropertyTermName>Identification</ccts:PropertyTermName>
|
||||
<ccts:RepresentationTermName>Identifier</ccts:RepresentationTermName>
|
||||
<ccts:PrimitiveType>string</ccts:PrimitiveType>
|
||||
</xsd:documentation>
|
||||
</xsd:annotation>
|
||||
</xsd:attribute>
|
||||
<xsd:attribute name="languageLocaleID" type="xsd:normalizedString" use="optional">
|
||||
<xsd:annotation>
|
||||
<xsd:documentation xml:lang="en">
|
||||
<ccts:UniqueID>UNDT000019-SC3</ccts:UniqueID>
|
||||
<ccts:CategoryCode>SC</ccts:CategoryCode>
|
||||
<ccts:DictionaryEntryName>Language. Locale. Identifier</ccts:DictionaryEntryName>
|
||||
<ccts:Definition>The identification of the locale of the language.</ccts:Definition>
|
||||
<ccts:ObjectClass>Language</ccts:ObjectClass>
|
||||
<ccts:PropertyTermName>Locale</ccts:PropertyTermName>
|
||||
<ccts:RepresentationTermName>Identifier</ccts:RepresentationTermName>
|
||||
<ccts:PrimitiveType>string</ccts:PrimitiveType>
|
||||
</xsd:documentation>
|
||||
</xsd:annotation>
|
||||
</xsd:attribute>
|
||||
</xsd:extension>
|
||||
</xsd:simpleContent>
|
||||
</xsd:complexType>
|
||||
</xsd:schema>
|
||||
File diff suppressed because it is too large
Load diff
File diff suppressed because it is too large
Load diff
|
|
@ -0,0 +1,235 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!--
|
||||
~ Licensed to the Koordinierungsstelle für IT-Standards (KoSIT) under
|
||||
~ one or more contributor license agreements. See the NOTICE file
|
||||
~ distributed with this work for additional information
|
||||
~ regarding copyright ownership. KoSIT licenses this file
|
||||
~ to you under the Apache License, Version 2.0 (the
|
||||
~ "License"); you may not use this file except in compliance
|
||||
~ with the License. You may obtain a copy of the License at
|
||||
~
|
||||
~ http://www.apache.org/licenses/LICENSE-2.0
|
||||
~
|
||||
~ Unless required by applicable law or agreed to in writing,
|
||||
~ software distributed under the License is distributed on an
|
||||
~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||
~ KIND, either express or implied. See the License for the
|
||||
~ specific language governing permissions and limitations
|
||||
~ under the License.
|
||||
-->
|
||||
<xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema"
|
||||
xmlns:cbc="urn:oasis:names:specification:ubl:schema:xsd:CommonBasicComponents-2"
|
||||
xmlns:udt="urn:oasis:names:specification:ubl:schema:xsd:UnqualifiedDataTypes-2"
|
||||
xmlns="urn:oasis:names:specification:ubl:schema:xsd:CommonExtensionComponents-2"
|
||||
targetNamespace="urn:oasis:names:specification:ubl:schema:xsd:CommonExtensionComponents-2"
|
||||
elementFormDefault="qualified" attributeFormDefault="unqualified"
|
||||
version="2.1">
|
||||
<!-- ===== Imports ===== -->
|
||||
<xsd:import namespace="urn:oasis:names:specification:ubl:schema:xsd:UnqualifiedDataTypes-2"
|
||||
schemaLocation="UBL-UnqualifiedDataTypes-2.1.xsd"/>
|
||||
<xsd:import namespace="urn:oasis:names:specification:ubl:schema:xsd:CommonBasicComponents-2"
|
||||
schemaLocation="UBL-CommonBasicComponents-2.1.xsd"/>
|
||||
<!-- ===== Includes ===== -->
|
||||
<xsd:include schemaLocation="UBL-ExtensionContentDataType-2.1.xsd"/>
|
||||
<!-- ===== Aggregate Element and Type Declarations ===== -->
|
||||
<xsd:element name="UBLExtensions" type="UBLExtensionsType">
|
||||
<xsd:annotation>
|
||||
<xsd:documentation>
|
||||
A container for all extensions present in the document.
|
||||
</xsd:documentation>
|
||||
</xsd:annotation>
|
||||
</xsd:element>
|
||||
<xsd:complexType name="UBLExtensionsType">
|
||||
<xsd:annotation>
|
||||
<xsd:documentation>
|
||||
A container for all extensions present in the document.
|
||||
</xsd:documentation>
|
||||
</xsd:annotation>
|
||||
<xsd:sequence>
|
||||
<xsd:element ref="UBLExtension" minOccurs="1" maxOccurs="unbounded">
|
||||
<xsd:annotation>
|
||||
<xsd:documentation>
|
||||
A single extension for private use.
|
||||
</xsd:documentation>
|
||||
</xsd:annotation>
|
||||
</xsd:element>
|
||||
</xsd:sequence>
|
||||
</xsd:complexType>
|
||||
<xsd:element name="UBLExtension" type="UBLExtensionType">
|
||||
<xsd:annotation>
|
||||
<xsd:documentation>
|
||||
A single extension for private use.
|
||||
</xsd:documentation>
|
||||
</xsd:annotation>
|
||||
</xsd:element>
|
||||
<xsd:complexType name="UBLExtensionType">
|
||||
<xsd:annotation>
|
||||
<xsd:documentation>
|
||||
A single extension for private use.
|
||||
</xsd:documentation>
|
||||
</xsd:annotation>
|
||||
<xsd:sequence>
|
||||
<xsd:element ref="cbc:ID" minOccurs="0" maxOccurs="1">
|
||||
<xsd:annotation>
|
||||
<xsd:documentation>
|
||||
An identifier for the Extension assigned by the creator of the extension.
|
||||
</xsd:documentation>
|
||||
</xsd:annotation>
|
||||
</xsd:element>
|
||||
<xsd:element ref="cbc:Name" minOccurs="0" maxOccurs="1">
|
||||
<xsd:annotation>
|
||||
<xsd:documentation>
|
||||
A name for the Extension assigned by the creator of the extension.
|
||||
</xsd:documentation>
|
||||
</xsd:annotation>
|
||||
</xsd:element>
|
||||
<xsd:element ref="ExtensionAgencyID" minOccurs="0" maxOccurs="1">
|
||||
<xsd:annotation>
|
||||
<xsd:documentation>
|
||||
An agency that maintains one or more Extensions.
|
||||
</xsd:documentation>
|
||||
</xsd:annotation>
|
||||
</xsd:element>
|
||||
<xsd:element ref="ExtensionAgencyName" minOccurs="0" maxOccurs="1">
|
||||
<xsd:annotation>
|
||||
<xsd:documentation>
|
||||
The name of the agency that maintains the Extension.
|
||||
</xsd:documentation>
|
||||
</xsd:annotation>
|
||||
</xsd:element>
|
||||
<xsd:element ref="ExtensionVersionID" minOccurs="0" maxOccurs="1">
|
||||
<xsd:annotation>
|
||||
<xsd:documentation>
|
||||
The version of the Extension.
|
||||
</xsd:documentation>
|
||||
</xsd:annotation>
|
||||
</xsd:element>
|
||||
<xsd:element ref="ExtensionAgencyURI" minOccurs="0" maxOccurs="1">
|
||||
<xsd:annotation>
|
||||
<xsd:documentation>
|
||||
A URI for the Agency that maintains the Extension.
|
||||
</xsd:documentation>
|
||||
</xsd:annotation>
|
||||
</xsd:element>
|
||||
<xsd:element ref="ExtensionURI" minOccurs="0" maxOccurs="1">
|
||||
<xsd:annotation>
|
||||
<xsd:documentation>
|
||||
A URI for the Extension.
|
||||
</xsd:documentation>
|
||||
</xsd:annotation>
|
||||
</xsd:element>
|
||||
<xsd:element ref="ExtensionReasonCode" minOccurs="0" maxOccurs="1">
|
||||
<xsd:annotation>
|
||||
<xsd:documentation>
|
||||
A code for reason the Extension is being included.
|
||||
</xsd:documentation>
|
||||
</xsd:annotation>
|
||||
</xsd:element>
|
||||
<xsd:element ref="ExtensionReason" minOccurs="0" maxOccurs="1">
|
||||
<xsd:annotation>
|
||||
<xsd:documentation>
|
||||
A description of the reason for the Extension.
|
||||
</xsd:documentation>
|
||||
</xsd:annotation>
|
||||
</xsd:element>
|
||||
<xsd:element ref="ExtensionContent" minOccurs="1" maxOccurs="1">
|
||||
<xsd:annotation>
|
||||
<xsd:documentation>
|
||||
The definition of the extension content.
|
||||
</xsd:documentation>
|
||||
</xsd:annotation>
|
||||
</xsd:element>
|
||||
</xsd:sequence>
|
||||
</xsd:complexType>
|
||||
<!-- ===== Basic Element and Type Declarations ===== -->
|
||||
<xsd:element name="ExtensionAgencyID" type="ExtensionAgencyIDType"/>
|
||||
<xsd:element name="ExtensionAgencyName" type="ExtensionAgencyNameType"/>
|
||||
<xsd:element name="ExtensionAgencyURI" type="ExtensionAgencyURIType"/>
|
||||
<xsd:element name="ExtensionContent" type="ExtensionContentType"/>
|
||||
<xsd:element name="ExtensionReason" type="ExtensionReasonType"/>
|
||||
<xsd:element name="ExtensionReasonCode" type="ExtensionReasonCodeType"/>
|
||||
<xsd:element name="ExtensionURI" type="ExtensionURIType"/>
|
||||
<xsd:element name="ExtensionVersionID" type="ExtensionVersionIDType"/>
|
||||
<xsd:complexType name="ExtensionAgencyIDType">
|
||||
<xsd:simpleContent>
|
||||
<xsd:extension base="udt:IdentifierType"/>
|
||||
</xsd:simpleContent>
|
||||
</xsd:complexType>
|
||||
<xsd:complexType name="ExtensionAgencyNameType">
|
||||
<xsd:simpleContent>
|
||||
<xsd:extension base="udt:TextType"/>
|
||||
</xsd:simpleContent>
|
||||
</xsd:complexType>
|
||||
<xsd:complexType name="ExtensionAgencyURIType">
|
||||
<xsd:simpleContent>
|
||||
<xsd:extension base="udt:IdentifierType"/>
|
||||
</xsd:simpleContent>
|
||||
</xsd:complexType>
|
||||
<xsd:complexType name="ExtensionReasonType">
|
||||
<xsd:simpleContent>
|
||||
<xsd:extension base="udt:TextType"/>
|
||||
</xsd:simpleContent>
|
||||
</xsd:complexType>
|
||||
<xsd:complexType name="ExtensionReasonCodeType">
|
||||
<xsd:simpleContent>
|
||||
<xsd:extension base="udt:CodeType"/>
|
||||
</xsd:simpleContent>
|
||||
</xsd:complexType>
|
||||
<xsd:complexType name="ExtensionURIType">
|
||||
<xsd:simpleContent>
|
||||
<xsd:extension base="udt:IdentifierType"/>
|
||||
</xsd:simpleContent>
|
||||
</xsd:complexType>
|
||||
<xsd:complexType name="ExtensionVersionIDType">
|
||||
<xsd:simpleContent>
|
||||
<xsd:extension base="udt:IdentifierType"/>
|
||||
</xsd:simpleContent>
|
||||
</xsd:complexType>
|
||||
</xsd:schema>
|
||||
<!-- ===== Copyright Notice ===== -->
|
||||
<!--
|
||||
OASIS takes no position regarding the validity or scope of any
|
||||
intellectual property or other rights that might be claimed to pertain
|
||||
to the implementation or use of the technology described in this
|
||||
document or the extent to which any license under such rights
|
||||
might or might not be available; neither does it represent that it has
|
||||
made any effort to identify any such rights. Information on OASIS's
|
||||
procedures with respect to rights in OASIS specifications can be
|
||||
found at the OASIS website. Copies of claims of rights made
|
||||
available for publication and any assurances of licenses to be made
|
||||
available, or the result of an attempt made to obtain a general
|
||||
license or permission for the use of such proprietary rights by
|
||||
implementors or users of this specification, can be obtained from
|
||||
the OASIS Executive Director.
|
||||
|
||||
OASIS invites any interested party to bring to its attention any
|
||||
copyrights, patents or patent applications, or other proprietary
|
||||
rights which may cover technology that may be required to
|
||||
implement this specification. Please address the information to the
|
||||
OASIS Executive Director.
|
||||
|
||||
This document and translations of it may be copied and furnished to
|
||||
others, and derivative works that comment on or otherwise explain
|
||||
it or assist in its implementation may be prepared, copied,
|
||||
published and distributed, in whole or in part, without restriction of
|
||||
any kind, provided that the above copyright notice and this
|
||||
paragraph are included on all such copies and derivative works.
|
||||
However, this document itself may not be modified in any way,
|
||||
such as by removing the copyright notice or references to OASIS,
|
||||
except as needed for the purpose of developing OASIS
|
||||
specifications, in which case the procedures for copyrights defined
|
||||
in the OASIS Intellectual Property Rights document must be
|
||||
followed, or as required to translate it into languages other than
|
||||
English.
|
||||
|
||||
The limited permissions granted above are perpetual and will not be
|
||||
revoked by OASIS or its successors or assigns.
|
||||
|
||||
This document and the information contained herein is provided on
|
||||
an "AS IS" basis and OASIS DISCLAIMS ALL WARRANTIES,
|
||||
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY
|
||||
WARRANTY THAT THE USE OF THE INFORMATION HEREIN
|
||||
WILL NOT INFRINGE ANY RIGHTS OR ANY IMPLIED
|
||||
WARRANTIES OF MERCHANTABILITY OR FITNESS FOR A
|
||||
PARTICULAR PURPOSE.
|
||||
-->
|
||||
|
|
@ -0,0 +1,81 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!--
|
||||
~ Licensed to the Koordinierungsstelle für IT-Standards (KoSIT) under
|
||||
~ one or more contributor license agreements. See the NOTICE file
|
||||
~ distributed with this work for additional information
|
||||
~ regarding copyright ownership. KoSIT licenses this file
|
||||
~ to you under the Apache License, Version 2.0 (the
|
||||
~ "License"); you may not use this file except in compliance
|
||||
~ with the License. You may obtain a copy of the License at
|
||||
~
|
||||
~ http://www.apache.org/licenses/LICENSE-2.0
|
||||
~
|
||||
~ Unless required by applicable law or agreed to in writing,
|
||||
~ software distributed under the License is distributed on an
|
||||
~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||
~ KIND, either express or implied. See the License for the
|
||||
~ specific language governing permissions and limitations
|
||||
~ under the License.
|
||||
-->
|
||||
<xsd:schema xmlns:sac="urn:oasis:names:specification:ubl:schema:xsd:SignatureAggregateComponents-2"
|
||||
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
|
||||
xmlns="urn:oasis:names:specification:ubl:schema:xsd:CommonSignatureComponents-2"
|
||||
targetNamespace="urn:oasis:names:specification:ubl:schema:xsd:CommonSignatureComponents-2"
|
||||
elementFormDefault="qualified"
|
||||
attributeFormDefault="unqualified"
|
||||
version="2.1">
|
||||
<xsd:import namespace="urn:oasis:names:specification:ubl:schema:xsd:SignatureAggregateComponents-2"
|
||||
schemaLocation="UBL-SignatureAggregateComponents-2.1.xsd"/>
|
||||
<xsd:element name="UBLDocumentSignatures" type="UBLDocumentSignaturesType"/>
|
||||
<xsd:complexType name="UBLDocumentSignaturesType">
|
||||
<xsd:sequence>
|
||||
<xsd:element ref="sac:SignatureInformation" minOccurs="1" maxOccurs="unbounded"/>
|
||||
</xsd:sequence>
|
||||
</xsd:complexType>
|
||||
</xsd:schema>
|
||||
<!-- ===== Copyright Notice ===== --><!--
|
||||
OASIS takes no position regarding the validity or scope of any
|
||||
intellectual property or other rights that might be claimed to pertain
|
||||
to the implementation or use of the technology described in this
|
||||
document or the extent to which any license under such rights
|
||||
might or might not be available; neither does it represent that it has
|
||||
made any effort to identify any such rights. Information on OASIS's
|
||||
procedures with respect to rights in OASIS specifications can be
|
||||
found at the OASIS website. Copies of claims of rights made
|
||||
available for publication and any assurances of licenses to be made
|
||||
available, or the result of an attempt made to obtain a general
|
||||
license or permission for the use of such proprietary rights by
|
||||
implementors or users of this specification, can be obtained from
|
||||
the OASIS Executive Director.
|
||||
|
||||
OASIS invites any interested party to bring to its attention any
|
||||
copyrights, patents or patent applications, or other proprietary
|
||||
rights which may cover technology that may be required to
|
||||
implement this specification. Please address the information to the
|
||||
OASIS Executive Director.
|
||||
|
||||
This document and translations of it may be copied and furnished to
|
||||
others, and derivative works that comment on or otherwise explain
|
||||
it or assist in its implementation may be prepared, copied,
|
||||
published and distributed, in whole or in part, without restriction of
|
||||
any kind, provided that the above copyright notice and this
|
||||
paragraph are included on all such copies and derivative works.
|
||||
However, this document itself may not be modified in any way,
|
||||
such as by removing the copyright notice or references to OASIS,
|
||||
except as needed for the purpose of developing OASIS
|
||||
specifications, in which case the procedures for copyrights defined
|
||||
in the OASIS Intellectual Property Rights document must be
|
||||
followed, or as required to translate it into languages other than
|
||||
English.
|
||||
|
||||
The limited permissions granted above are perpetual and will not be
|
||||
revoked by OASIS or its successors or assigns.
|
||||
|
||||
This document and the information contained herein is provided on
|
||||
an "AS IS" basis and OASIS DISCLAIMS ALL WARRANTIES,
|
||||
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY
|
||||
WARRANTY THAT THE USE OF THE INFORMATION HEREIN
|
||||
WILL NOT INFRINGE ANY RIGHTS OR ANY IMPLIED
|
||||
WARRANTIES OF MERCHANTABILITY OR FITNESS FOR A
|
||||
PARTICULAR PURPOSE.
|
||||
-->
|
||||
|
|
@ -0,0 +1,73 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!--
|
||||
~ Licensed to the Koordinierungsstelle für IT-Standards (KoSIT) under
|
||||
~ one or more contributor license agreements. See the NOTICE file
|
||||
~ distributed with this work for additional information
|
||||
~ regarding copyright ownership. KoSIT licenses this file
|
||||
~ to you under the Apache License, Version 2.0 (the
|
||||
~ "License"); you may not use this file except in compliance
|
||||
~ with the License. You may obtain a copy of the License at
|
||||
~
|
||||
~ http://www.apache.org/licenses/LICENSE-2.0
|
||||
~
|
||||
~ Unless required by applicable law or agreed to in writing,
|
||||
~ software distributed under the License is distributed on an
|
||||
~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||
~ KIND, either express or implied. See the License for the
|
||||
~ specific language governing permissions and limitations
|
||||
~ under the License.
|
||||
-->
|
||||
<xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema"
|
||||
targetNamespace="urn:un:unece:uncefact:documentation:2"
|
||||
xmlns="urn:un:unece:uncefact:documentation:2"
|
||||
elementFormDefault="qualified"
|
||||
attributeFormDefault="unqualified"
|
||||
version="2.1">
|
||||
</xsd:schema>
|
||||
<!-- ===== Copyright Notice ===== -->
|
||||
<!--
|
||||
OASIS takes no position regarding the validity or scope of any
|
||||
intellectual property or other rights that might be claimed to pertain
|
||||
to the implementation or use of the technology described in this
|
||||
document or the extent to which any license under such rights
|
||||
might or might not be available; neither does it represent that it has
|
||||
made any effort to identify any such rights. Information on OASIS's
|
||||
procedures with respect to rights in OASIS specifications can be
|
||||
found at the OASIS website. Copies of claims of rights made
|
||||
available for publication and any assurances of licenses to be made
|
||||
available, or the result of an attempt made to obtain a general
|
||||
license or permission for the use of such proprietary rights by
|
||||
implementors or users of this specification, can be obtained from
|
||||
the OASIS Executive Director.
|
||||
|
||||
OASIS invites any interested party to bring to its attention any
|
||||
copyrights, patents or patent applications, or other proprietary
|
||||
rights which may cover technology that may be required to
|
||||
implement this specification. Please address the information to the
|
||||
OASIS Executive Director.
|
||||
|
||||
This document and translations of it may be copied and furnished to
|
||||
others, and derivative works that comment on or otherwise explain
|
||||
it or assist in its implementation may be prepared, copied,
|
||||
published and distributed, in whole or in part, without restriction of
|
||||
any kind, provided that the above copyright notice and this
|
||||
paragraph are included on all such copies and derivative works.
|
||||
However, this document itself may not be modified in any way,
|
||||
such as by removing the copyright notice or references to OASIS,
|
||||
except as needed for the purpose of developing OASIS
|
||||
specifications, in which case the procedures for copyrights defined
|
||||
in the OASIS Intellectual Property Rights document must be
|
||||
followed, or as required to translate it into languages other than
|
||||
English.
|
||||
|
||||
The limited permissions granted above are perpetual and will not be
|
||||
revoked by OASIS or its successors or assigns.
|
||||
|
||||
This document and the information contained herein is provided on
|
||||
an "AS IS" basis and OASIS DISCLAIMS ALL WARRANTIES,
|
||||
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY
|
||||
WARRANTY THAT THE USE OF THE INFORMATION HEREIN
|
||||
WILL NOT INFRINGE ANY RIGHTS OR ANY IMPLIED
|
||||
WARRANTIES OF MERCHANTABILITY OR FITNESS FOR A
|
||||
PARTICULAR PURPOSE.
|
||||
-->
|
||||
|
|
@ -0,0 +1,99 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!--
|
||||
~ Licensed to the Koordinierungsstelle für IT-Standards (KoSIT) under
|
||||
~ one or more contributor license agreements. See the NOTICE file
|
||||
~ distributed with this work for additional information
|
||||
~ regarding copyright ownership. KoSIT licenses this file
|
||||
~ to you under the Apache License, Version 2.0 (the
|
||||
~ "License"); you may not use this file except in compliance
|
||||
~ with the License. You may obtain a copy of the License at
|
||||
~
|
||||
~ http://www.apache.org/licenses/LICENSE-2.0
|
||||
~
|
||||
~ Unless required by applicable law or agreed to in writing,
|
||||
~ software distributed under the License is distributed on an
|
||||
~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||
~ KIND, either express or implied. See the License for the
|
||||
~ specific language governing permissions and limitations
|
||||
~ under the License.
|
||||
-->
|
||||
<xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns=
|
||||
"urn:oasis:names:specification:ubl:schema:xsd:CommonExtensionComponents-2"
|
||||
targetNamespace=
|
||||
"urn:oasis:names:specification:ubl:schema:xsd:CommonExtensionComponents-2"
|
||||
elementFormDefault="qualified"
|
||||
attributeFormDefault="unqualified"
|
||||
version="2.1">
|
||||
|
||||
<!--import here all extension schemas-->
|
||||
<xsd:import namespace=
|
||||
"urn:oasis:names:specification:ubl:schema:xsd:CommonSignatureComponents-2"
|
||||
schemaLocation="UBL-CommonSignatureComponents-2.1.xsd"/>
|
||||
|
||||
<!-- ===== Type Declaration ===== -->
|
||||
<xsd:complexType name="ExtensionContentType">
|
||||
<xsd:sequence>
|
||||
<xsd:any namespace="##other" processContents="lax"
|
||||
minOccurs="1" maxOccurs="1">
|
||||
<xsd:annotation>
|
||||
<xsd:documentation>
|
||||
Any element in any namespace other than the UBL extension
|
||||
namespace is allowed to be the apex element of an extension.
|
||||
Only those elements found in the UBL schemas and in the
|
||||
trees of schemas imported in this module are validated.
|
||||
Any element for which there is no schema declaration in any
|
||||
of the trees of schemas passes validation and is not
|
||||
treated as a schema constraint violation.
|
||||
</xsd:documentation>
|
||||
</xsd:annotation>
|
||||
</xsd:any>
|
||||
</xsd:sequence>
|
||||
</xsd:complexType>
|
||||
</xsd:schema>
|
||||
<!-- ===== Copyright Notice ===== -->
|
||||
<!--
|
||||
OASIS takes no position regarding the validity or scope of any
|
||||
intellectual property or other rights that might be claimed to pertain
|
||||
to the implementation or use of the technology described in this
|
||||
document or the extent to which any license under such rights
|
||||
might or might not be available; neither does it represent that it has
|
||||
made any effort to identify any such rights. Information on OASIS's
|
||||
procedures with respect to rights in OASIS specifications can be
|
||||
found at the OASIS website. Copies of claims of rights made
|
||||
available for publication and any assurances of licenses to be made
|
||||
available, or the result of an attempt made to obtain a general
|
||||
license or permission for the use of such proprietary rights by
|
||||
implementors or users of this specification, can be obtained from
|
||||
the OASIS Executive Director.
|
||||
|
||||
OASIS invites any interested party to bring to its attention any
|
||||
copyrights, patents or patent applications, or other proprietary
|
||||
rights which may cover technology that may be required to
|
||||
implement this specification. Please address the information to the
|
||||
OASIS Executive Director.
|
||||
|
||||
This document and translations of it may be copied and furnished to
|
||||
others, and derivative works that comment on or otherwise explain
|
||||
it or assist in its implementation may be prepared, copied,
|
||||
published and distributed, in whole or in part, without restriction of
|
||||
any kind, provided that the above copyright notice and this
|
||||
paragraph are included on all such copies and derivative works.
|
||||
However, this document itself may not be modified in any way,
|
||||
such as by removing the copyright notice or references to OASIS,
|
||||
except as needed for the purpose of developing OASIS
|
||||
specifications, in which case the procedures for copyrights defined
|
||||
in the OASIS Intellectual Property Rights document must be
|
||||
followed, or as required to translate it into languages other than
|
||||
English.
|
||||
|
||||
The limited permissions granted above are perpetual and will not be
|
||||
revoked by OASIS or its successors or assigns.
|
||||
|
||||
This document and the information contained herein is provided on
|
||||
an "AS IS" basis and OASIS DISCLAIMS ALL WARRANTIES,
|
||||
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY
|
||||
WARRANTY THAT THE USE OF THE INFORMATION HEREIN
|
||||
WILL NOT INFRINGE ANY RIGHTS OR ANY IMPLIED
|
||||
WARRANTIES OF MERCHANTABILITY OR FITNESS FOR A
|
||||
PARTICULAR PURPOSE.
|
||||
-->
|
||||
|
|
@ -0,0 +1,78 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!--
|
||||
~ Licensed to the Koordinierungsstelle für IT-Standards (KoSIT) under
|
||||
~ one or more contributor license agreements. See the NOTICE file
|
||||
~ distributed with this work for additional information
|
||||
~ regarding copyright ownership. KoSIT licenses this file
|
||||
~ to you under the Apache License, Version 2.0 (the
|
||||
~ "License"); you may not use this file except in compliance
|
||||
~ with the License. You may obtain a copy of the License at
|
||||
~
|
||||
~ http://www.apache.org/licenses/LICENSE-2.0
|
||||
~
|
||||
~ Unless required by applicable law or agreed to in writing,
|
||||
~ software distributed under the License is distributed on an
|
||||
~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||
~ KIND, either express or implied. See the License for the
|
||||
~ specific language governing permissions and limitations
|
||||
~ under the License.
|
||||
-->
|
||||
<xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema"
|
||||
targetNamespace="urn:oasis:names:specification:ubl:schema:xsd:QualifiedDataTypes-2"
|
||||
xmlns="urn:oasis:names:specification:ubl:schema:xsd:QualifiedDataTypes-2"
|
||||
elementFormDefault="qualified"
|
||||
attributeFormDefault="unqualified"
|
||||
version="2.1">
|
||||
<!-- ===== Imports ===== -->
|
||||
<xsd:import namespace="urn:oasis:names:specification:ubl:schema:xsd:UnqualifiedDataTypes-2"
|
||||
schemaLocation="UBL-UnqualifiedDataTypes-2.1.xsd"/>
|
||||
<!-- ===== Type Definitions ===== -->
|
||||
<!--no qualified data types defined at this time-->
|
||||
</xsd:schema>
|
||||
<!-- ===== Copyright Notice ===== -->
|
||||
<!--
|
||||
OASIS takes no position regarding the validity or scope of any
|
||||
intellectual property or other rights that might be claimed to pertain
|
||||
to the implementation or use of the technology described in this
|
||||
document or the extent to which any license under such rights
|
||||
might or might not be available; neither does it represent that it has
|
||||
made any effort to identify any such rights. Information on OASIS's
|
||||
procedures with respect to rights in OASIS specifications can be
|
||||
found at the OASIS website. Copies of claims of rights made
|
||||
available for publication and any assurances of licenses to be made
|
||||
available, or the result of an attempt made to obtain a general
|
||||
license or permission for the use of such proprietary rights by
|
||||
implementors or users of this specification, can be obtained from
|
||||
the OASIS Executive Director.
|
||||
|
||||
OASIS invites any interested party to bring to its attention any
|
||||
copyrights, patents or patent applications, or other proprietary
|
||||
rights which may cover technology that may be required to
|
||||
implement this specification. Please address the information to the
|
||||
OASIS Executive Director.
|
||||
|
||||
This document and translations of it may be copied and furnished to
|
||||
others, and derivative works that comment on or otherwise explain
|
||||
it or assist in its implementation may be prepared, copied,
|
||||
published and distributed, in whole or in part, without restriction of
|
||||
any kind, provided that the above copyright notice and this
|
||||
paragraph are included on all such copies and derivative works.
|
||||
However, this document itself may not be modified in any way,
|
||||
such as by removing the copyright notice or references to OASIS,
|
||||
except as needed for the purpose of developing OASIS
|
||||
specifications, in which case the procedures for copyrights defined
|
||||
in the OASIS Intellectual Property Rights document must be
|
||||
followed, or as required to translate it into languages other than
|
||||
English.
|
||||
|
||||
The limited permissions granted above are perpetual and will not be
|
||||
revoked by OASIS or its successors or assigns.
|
||||
|
||||
This document and the information contained herein is provided on
|
||||
an "AS IS" basis and OASIS DISCLAIMS ALL WARRANTIES,
|
||||
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY
|
||||
WARRANTY THAT THE USE OF THE INFORMATION HEREIN
|
||||
WILL NOT INFRINGE ANY RIGHTS OR ANY IMPLIED
|
||||
WARRANTIES OF MERCHANTABILITY OR FITNESS FOR A
|
||||
PARTICULAR PURPOSE.
|
||||
-->
|
||||
|
|
@ -0,0 +1,102 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!--
|
||||
~ Licensed to the Koordinierungsstelle für IT-Standards (KoSIT) under
|
||||
~ one or more contributor license agreements. See the NOTICE file
|
||||
~ distributed with this work for additional information
|
||||
~ regarding copyright ownership. KoSIT licenses this file
|
||||
~ to you under the Apache License, Version 2.0 (the
|
||||
~ "License"); you may not use this file except in compliance
|
||||
~ with the License. You may obtain a copy of the License at
|
||||
~
|
||||
~ http://www.apache.org/licenses/LICENSE-2.0
|
||||
~
|
||||
~ Unless required by applicable law or agreed to in writing,
|
||||
~ software distributed under the License is distributed on an
|
||||
~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||
~ KIND, either express or implied. See the License for the
|
||||
~ specific language governing permissions and limitations
|
||||
~ under the License.
|
||||
-->
|
||||
<xsd:schema xmlns:sbc="urn:oasis:names:specification:ubl:schema:xsd:SignatureBasicComponents-2"
|
||||
xmlns:cbc="urn:oasis:names:specification:ubl:schema:xsd:CommonBasicComponents-2"
|
||||
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
|
||||
xmlns:ds="http://www.w3.org/2000/09/xmldsig#"
|
||||
xmlns="urn:oasis:names:specification:ubl:schema:xsd:SignatureAggregateComponents-2"
|
||||
targetNamespace="urn:oasis:names:specification:ubl:schema:xsd:SignatureAggregateComponents-2"
|
||||
elementFormDefault="qualified"
|
||||
attributeFormDefault="unqualified"
|
||||
version="2.1">
|
||||
<xsd:import namespace="urn:oasis:names:specification:ubl:schema:xsd:SignatureBasicComponents-2"
|
||||
schemaLocation="UBL-SignatureBasicComponents-2.1.xsd"/>
|
||||
<xsd:import namespace="urn:oasis:names:specification:ubl:schema:xsd:CommonBasicComponents-2"
|
||||
schemaLocation="UBL-CommonBasicComponents-2.1.xsd"/>
|
||||
|
||||
<!-- ===== Incorporate W3C signature specification-->
|
||||
<xsd:import namespace="http://www.w3.org/2000/09/xmldsig#"
|
||||
schemaLocation="UBL-xmldsig-core-schema-2.1.xsd"/>
|
||||
|
||||
<!-- ===== Incorporate ETSI signature specifications-->
|
||||
<xsd:import namespace="http://uri.etsi.org/01903/v1.3.2#"
|
||||
schemaLocation="UBL-XAdESv132-2.1.xsd"/>
|
||||
<xsd:import namespace="http://uri.etsi.org/01903/v1.4.1#"
|
||||
schemaLocation="UBL-XAdESv141-2.1.xsd"/>
|
||||
<xsd:element name="SignatureInformation" type="SignatureInformationType"/>
|
||||
<xsd:complexType name="SignatureInformationType">
|
||||
<xsd:sequence>
|
||||
<xsd:element ref="cbc:ID" minOccurs="0" maxOccurs="1"/>
|
||||
<xsd:element ref="sbc:ReferencedSignatureID" minOccurs="0" maxOccurs="1"/>
|
||||
<xsd:element ref="ds:Signature" minOccurs="0" maxOccurs="1">
|
||||
<xsd:annotation>
|
||||
<xsd:documentation>This is a single digital signature as defined by the W3C specification.
|
||||
</xsd:documentation>
|
||||
</xsd:annotation>
|
||||
</xsd:element>
|
||||
</xsd:sequence>
|
||||
</xsd:complexType>
|
||||
</xsd:schema>
|
||||
<!-- ===== Copyright Notice ===== --><!--
|
||||
OASIS takes no position regarding the validity or scope of any
|
||||
intellectual property or other rights that might be claimed to pertain
|
||||
to the implementation or use of the technology described in this
|
||||
document or the extent to which any license under such rights
|
||||
might or might not be available; neither does it represent that it has
|
||||
made any effort to identify any such rights. Information on OASIS's
|
||||
procedures with respect to rights in OASIS specifications can be
|
||||
found at the OASIS website. Copies of claims of rights made
|
||||
available for publication and any assurances of licenses to be made
|
||||
available, or the result of an attempt made to obtain a general
|
||||
license or permission for the use of such proprietary rights by
|
||||
implementors or users of this specification, can be obtained from
|
||||
the OASIS Executive Director.
|
||||
|
||||
OASIS invites any interested party to bring to its attention any
|
||||
copyrights, patents or patent applications, or other proprietary
|
||||
rights which may cover technology that may be required to
|
||||
implement this specification. Please address the information to the
|
||||
OASIS Executive Director.
|
||||
|
||||
This document and translations of it may be copied and furnished to
|
||||
others, and derivative works that comment on or otherwise explain
|
||||
it or assist in its implementation may be prepared, copied,
|
||||
published and distributed, in whole or in part, without restriction of
|
||||
any kind, provided that the above copyright notice and this
|
||||
paragraph are included on all such copies and derivative works.
|
||||
However, this document itself may not be modified in any way,
|
||||
such as by removing the copyright notice or references to OASIS,
|
||||
except as needed for the purpose of developing OASIS
|
||||
specifications, in which case the procedures for copyrights defined
|
||||
in the OASIS Intellectual Property Rights document must be
|
||||
followed, or as required to translate it into languages other than
|
||||
English.
|
||||
|
||||
The limited permissions granted above are perpetual and will not be
|
||||
revoked by OASIS or its successors or assigns.
|
||||
|
||||
This document and the information contained herein is provided on
|
||||
an "AS IS" basis and OASIS DISCLAIMS ALL WARRANTIES,
|
||||
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY
|
||||
WARRANTY THAT THE USE OF THE INFORMATION HEREIN
|
||||
WILL NOT INFRINGE ANY RIGHTS OR ANY IMPLIED
|
||||
WARRANTIES OF MERCHANTABILITY OR FITNESS FOR A
|
||||
PARTICULAR PURPOSE.
|
||||
-->
|
||||
|
|
@ -0,0 +1,83 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!--
|
||||
~ Licensed to the Koordinierungsstelle für IT-Standards (KoSIT) under
|
||||
~ one or more contributor license agreements. See the NOTICE file
|
||||
~ distributed with this work for additional information
|
||||
~ regarding copyright ownership. KoSIT licenses this file
|
||||
~ to you under the Apache License, Version 2.0 (the
|
||||
~ "License"); you may not use this file except in compliance
|
||||
~ with the License. You may obtain a copy of the License at
|
||||
~
|
||||
~ http://www.apache.org/licenses/LICENSE-2.0
|
||||
~
|
||||
~ Unless required by applicable law or agreed to in writing,
|
||||
~ software distributed under the License is distributed on an
|
||||
~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||
~ KIND, either express or implied. See the License for the
|
||||
~ specific language governing permissions and limitations
|
||||
~ under the License.
|
||||
-->
|
||||
<xsd:schema xmlns:udt="urn:oasis:names:specification:ubl:schema:xsd:UnqualifiedDataTypes-2"
|
||||
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
|
||||
xmlns="urn:oasis:names:specification:ubl:schema:xsd:SignatureBasicComponents-2"
|
||||
targetNamespace="urn:oasis:names:specification:ubl:schema:xsd:SignatureBasicComponents-2"
|
||||
elementFormDefault="qualified"
|
||||
attributeFormDefault="unqualified"
|
||||
version="2.1">
|
||||
<xsd:import namespace="urn:oasis:names:specification:ubl:schema:xsd:QualifiedDataTypes-2"
|
||||
schemaLocation="UBL-QualifiedDataTypes-2.1.xsd"/>
|
||||
<xsd:import namespace="urn:oasis:names:specification:ubl:schema:xsd:UnqualifiedDataTypes-2"
|
||||
schemaLocation="UBL-UnqualifiedDataTypes-2.1.xsd"/>
|
||||
<xsd:element name="ReferencedSignatureID" type="ReferencedSignatureIDType"/>
|
||||
<xsd:complexType name="ReferencedSignatureIDType">
|
||||
<xsd:simpleContent>
|
||||
<xsd:extension base="udt:IdentifierType"/>
|
||||
</xsd:simpleContent>
|
||||
</xsd:complexType>
|
||||
</xsd:schema>
|
||||
<!-- ===== Copyright Notice ===== --><!--
|
||||
OASIS takes no position regarding the validity or scope of any
|
||||
intellectual property or other rights that might be claimed to pertain
|
||||
to the implementation or use of the technology described in this
|
||||
document or the extent to which any license under such rights
|
||||
might or might not be available; neither does it represent that it has
|
||||
made any effort to identify any such rights. Information on OASIS's
|
||||
procedures with respect to rights in OASIS specifications can be
|
||||
found at the OASIS website. Copies of claims of rights made
|
||||
available for publication and any assurances of licenses to be made
|
||||
available, or the result of an attempt made to obtain a general
|
||||
license or permission for the use of such proprietary rights by
|
||||
implementors or users of this specification, can be obtained from
|
||||
the OASIS Executive Director.
|
||||
|
||||
OASIS invites any interested party to bring to its attention any
|
||||
copyrights, patents or patent applications, or other proprietary
|
||||
rights which may cover technology that may be required to
|
||||
implement this specification. Please address the information to the
|
||||
OASIS Executive Director.
|
||||
|
||||
This document and translations of it may be copied and furnished to
|
||||
others, and derivative works that comment on or otherwise explain
|
||||
it or assist in its implementation may be prepared, copied,
|
||||
published and distributed, in whole or in part, without restriction of
|
||||
any kind, provided that the above copyright notice and this
|
||||
paragraph are included on all such copies and derivative works.
|
||||
However, this document itself may not be modified in any way,
|
||||
such as by removing the copyright notice or references to OASIS,
|
||||
except as needed for the purpose of developing OASIS
|
||||
specifications, in which case the procedures for copyrights defined
|
||||
in the OASIS Intellectual Property Rights document must be
|
||||
followed, or as required to translate it into languages other than
|
||||
English.
|
||||
|
||||
The limited permissions granted above are perpetual and will not be
|
||||
revoked by OASIS or its successors or assigns.
|
||||
|
||||
This document and the information contained herein is provided on
|
||||
an "AS IS" basis and OASIS DISCLAIMS ALL WARRANTIES,
|
||||
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY
|
||||
WARRANTY THAT THE USE OF THE INFORMATION HEREIN
|
||||
WILL NOT INFRINGE ANY RIGHTS OR ANY IMPLIED
|
||||
WARRANTIES OF MERCHANTABILITY OR FITNESS FOR A
|
||||
PARTICULAR PURPOSE.
|
||||
-->
|
||||
|
|
@ -0,0 +1,554 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!--
|
||||
~ Licensed to the Koordinierungsstelle für IT-Standards (KoSIT) under
|
||||
~ one or more contributor license agreements. See the NOTICE file
|
||||
~ distributed with this work for additional information
|
||||
~ regarding copyright ownership. KoSIT licenses this file
|
||||
~ to you under the Apache License, Version 2.0 (the
|
||||
~ "License"); you may not use this file except in compliance
|
||||
~ with the License. You may obtain a copy of the License at
|
||||
~
|
||||
~ http://www.apache.org/licenses/LICENSE-2.0
|
||||
~
|
||||
~ Unless required by applicable law or agreed to in writing,
|
||||
~ software distributed under the License is distributed on an
|
||||
~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||
~ KIND, either express or implied. See the License for the
|
||||
~ specific language governing permissions and limitations
|
||||
~ under the License.
|
||||
-->
|
||||
<xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema"
|
||||
xmlns:ccts-cct="urn:un:unece:uncefact:data:specification:CoreComponentTypeSchemaModule:2"
|
||||
xmlns:ccts="urn:un:unece:uncefact:documentation:2"
|
||||
targetNamespace="urn:oasis:names:specification:ubl:schema:xsd:UnqualifiedDataTypes-2"
|
||||
elementFormDefault="qualified"
|
||||
attributeFormDefault="unqualified"
|
||||
version="2.1">
|
||||
<!-- ===== Imports ===== -->
|
||||
<xsd:import schemaLocation="CCTS_CCT_SchemaModule-2.1.xsd"
|
||||
namespace="urn:un:unece:uncefact:data:specification:CoreComponentTypeSchemaModule:2"/>
|
||||
<!-- ===== Type Definitions ===== -->
|
||||
<xsd:complexType name="AmountType">
|
||||
<xsd:annotation>
|
||||
<xsd:documentation xml:lang="en">
|
||||
<ccts:UniqueID>UBLUDT000001</ccts:UniqueID>
|
||||
<ccts:CategoryCode>UDT</ccts:CategoryCode>
|
||||
<ccts:DictionaryEntryName>Amount. Type</ccts:DictionaryEntryName>
|
||||
<ccts:VersionID>1.0</ccts:VersionID>
|
||||
<ccts:Definition>A number of monetary units specified using a given unit of currency.</ccts:Definition>
|
||||
<ccts:RepresentationTermName>Amount</ccts:RepresentationTermName>
|
||||
</xsd:documentation>
|
||||
</xsd:annotation>
|
||||
<xsd:simpleContent>
|
||||
<xsd:restriction base="ccts-cct:AmountType">
|
||||
<xsd:attribute name="currencyID" type="xsd:normalizedString" use="required">
|
||||
<xsd:annotation>
|
||||
<xsd:documentation xml:lang="en">
|
||||
<ccts:UniqueID>UNDT000001-SC2</ccts:UniqueID>
|
||||
<ccts:CategoryCode>SC</ccts:CategoryCode>
|
||||
<ccts:DictionaryEntryName>Amount. Currency. Identifier</ccts:DictionaryEntryName>
|
||||
<ccts:Definition>The currency of the amount.</ccts:Definition>
|
||||
<ccts:ObjectClass>Amount Currency</ccts:ObjectClass>
|
||||
<ccts:PropertyTermName>Identification</ccts:PropertyTermName>
|
||||
<ccts:RepresentationTermName>Identifier</ccts:RepresentationTermName>
|
||||
<ccts:PrimitiveType>string</ccts:PrimitiveType>
|
||||
<ccts:UsageRule>Reference UNECE Rec 9, using 3-letter alphabetic codes.</ccts:UsageRule>
|
||||
</xsd:documentation>
|
||||
</xsd:annotation>
|
||||
</xsd:attribute>
|
||||
</xsd:restriction>
|
||||
</xsd:simpleContent>
|
||||
</xsd:complexType>
|
||||
|
||||
<xsd:complexType name="BinaryObjectType">
|
||||
<xsd:annotation>
|
||||
<xsd:documentation xml:lang="en">
|
||||
<ccts:UniqueID>UBLUDT000002</ccts:UniqueID>
|
||||
<ccts:CategoryCode>UDT</ccts:CategoryCode>
|
||||
<ccts:DictionaryEntryName>Binary Object. Type</ccts:DictionaryEntryName>
|
||||
<ccts:VersionID>1.0</ccts:VersionID>
|
||||
<ccts:Definition>A set of finite-length sequences of binary octets.</ccts:Definition>
|
||||
<ccts:RepresentationTermName>Binary Object</ccts:RepresentationTermName>
|
||||
<ccts:PrimitiveType>binary</ccts:PrimitiveType>
|
||||
</xsd:documentation>
|
||||
</xsd:annotation>
|
||||
<xsd:simpleContent>
|
||||
<xsd:restriction base="ccts-cct:BinaryObjectType">
|
||||
<xsd:attribute name="mimeCode" type="xsd:normalizedString" use="required">
|
||||
<xsd:annotation>
|
||||
<xsd:documentation xml:lang="en">
|
||||
<ccts:UniqueID>UNDT000002-SC3</ccts:UniqueID>
|
||||
<ccts:CategoryCode>SC</ccts:CategoryCode>
|
||||
<ccts:DictionaryEntryName>Binary Object. Mime. Code</ccts:DictionaryEntryName>
|
||||
<ccts:Definition>The mime type of the binary object.</ccts:Definition>
|
||||
<ccts:ObjectClass>Binary Object</ccts:ObjectClass>
|
||||
<ccts:PropertyTermName>Mime</ccts:PropertyTermName>
|
||||
<ccts:RepresentationTermName>Code</ccts:RepresentationTermName>
|
||||
<ccts:PrimitiveType>string</ccts:PrimitiveType>
|
||||
</xsd:documentation>
|
||||
</xsd:annotation>
|
||||
</xsd:attribute>
|
||||
</xsd:restriction>
|
||||
</xsd:simpleContent>
|
||||
</xsd:complexType>
|
||||
|
||||
<xsd:complexType name="GraphicType">
|
||||
<xsd:annotation>
|
||||
<xsd:documentation xml:lang="en">
|
||||
<ccts:UniqueID>UBLUDT000003</ccts:UniqueID>
|
||||
<ccts:CategoryCode>UDT</ccts:CategoryCode>
|
||||
<ccts:DictionaryEntryName>Graphic. Type</ccts:DictionaryEntryName>
|
||||
<ccts:VersionID>1.0</ccts:VersionID>
|
||||
<ccts:Definition>A diagram, graph, mathematical curve, or similar representation.</ccts:Definition>
|
||||
<ccts:RepresentationTermName>Graphic</ccts:RepresentationTermName>
|
||||
<ccts:PrimitiveType>binary</ccts:PrimitiveType>
|
||||
</xsd:documentation>
|
||||
</xsd:annotation>
|
||||
<xsd:simpleContent>
|
||||
<xsd:restriction base="ccts-cct:BinaryObjectType">
|
||||
<xsd:attribute name="mimeCode" type="xsd:normalizedString" use="required">
|
||||
<xsd:annotation>
|
||||
<xsd:documentation xml:lang="en">
|
||||
<ccts:UniqueID>UNDT000003-SC3</ccts:UniqueID>
|
||||
<ccts:CategoryCode>SC</ccts:CategoryCode>
|
||||
<ccts:DictionaryEntryName>Graphic. Mime. Code</ccts:DictionaryEntryName>
|
||||
<ccts:Definition>The mime type of the graphic object.</ccts:Definition>
|
||||
<ccts:ObjectClass>Graphic</ccts:ObjectClass>
|
||||
<ccts:PropertyTermName>Mime</ccts:PropertyTermName>
|
||||
<ccts:RepresentationTermName>Code</ccts:RepresentationTermName>
|
||||
<ccts:PrimitiveType>normalizedString</ccts:PrimitiveType>
|
||||
</xsd:documentation>
|
||||
</xsd:annotation>
|
||||
</xsd:attribute>
|
||||
</xsd:restriction>
|
||||
</xsd:simpleContent>
|
||||
</xsd:complexType>
|
||||
|
||||
<xsd:complexType name="PictureType">
|
||||
<xsd:annotation>
|
||||
<xsd:documentation xml:lang="en">
|
||||
<ccts:UniqueID>UBLUDT000004</ccts:UniqueID>
|
||||
<ccts:CategoryCode>UDT</ccts:CategoryCode>
|
||||
<ccts:DictionaryEntryName>Picture. Type</ccts:DictionaryEntryName>
|
||||
<ccts:VersionID>1.0</ccts:VersionID>
|
||||
<ccts:Definition>A diagram, graph, mathematical curve, or similar representation.</ccts:Definition>
|
||||
<ccts:RepresentationTermName>Picture</ccts:RepresentationTermName>
|
||||
<ccts:PrimitiveType>binary</ccts:PrimitiveType>
|
||||
</xsd:documentation>
|
||||
</xsd:annotation>
|
||||
<xsd:simpleContent>
|
||||
<xsd:restriction base="ccts-cct:BinaryObjectType">
|
||||
<xsd:attribute name="mimeCode" type="xsd:normalizedString" use="required">
|
||||
<xsd:annotation>
|
||||
<xsd:documentation xml:lang="en">
|
||||
<ccts:UniqueID>UNDT000004-SC3</ccts:UniqueID>
|
||||
<ccts:CategoryCode>SC</ccts:CategoryCode>
|
||||
<ccts:DictionaryEntryName>Picture. Mime. Code</ccts:DictionaryEntryName>
|
||||
<ccts:Definition>The mime type of the picture object.</ccts:Definition>
|
||||
<ccts:ObjectClass>Picture</ccts:ObjectClass>
|
||||
<ccts:PropertyTermName>Mime</ccts:PropertyTermName>
|
||||
<ccts:RepresentationTermName>Code</ccts:RepresentationTermName>
|
||||
<ccts:PrimitiveType>normalizedString</ccts:PrimitiveType>
|
||||
</xsd:documentation>
|
||||
</xsd:annotation>
|
||||
</xsd:attribute>
|
||||
</xsd:restriction>
|
||||
</xsd:simpleContent>
|
||||
</xsd:complexType>
|
||||
|
||||
<xsd:complexType name="SoundType">
|
||||
<xsd:annotation>
|
||||
<xsd:documentation xml:lang="en">
|
||||
<ccts:UniqueID>UBLUDT000005</ccts:UniqueID>
|
||||
<ccts:CategoryCode>UDT</ccts:CategoryCode>
|
||||
<ccts:DictionaryEntryName>Sound. Type</ccts:DictionaryEntryName>
|
||||
<ccts:VersionID>1.0</ccts:VersionID>
|
||||
<ccts:Definition>An audio representation.</ccts:Definition>
|
||||
<ccts:RepresentationTermName>Sound</ccts:RepresentationTermName>
|
||||
<ccts:PrimitiveType>binary</ccts:PrimitiveType>
|
||||
</xsd:documentation>
|
||||
</xsd:annotation>
|
||||
<xsd:simpleContent>
|
||||
<xsd:restriction base="ccts-cct:BinaryObjectType">
|
||||
<xsd:attribute name="mimeCode" type="xsd:normalizedString" use="required">
|
||||
<xsd:annotation>
|
||||
<xsd:documentation xml:lang="en">
|
||||
<ccts:UniqueID>UNDT000005-SC3</ccts:UniqueID>
|
||||
<ccts:CategoryCode>SC</ccts:CategoryCode>
|
||||
<ccts:DictionaryEntryName>Sound. Mime. Code</ccts:DictionaryEntryName>
|
||||
<ccts:Definition>The mime type of the sound object.</ccts:Definition>
|
||||
<ccts:ObjectClass>Sound</ccts:ObjectClass>
|
||||
<ccts:PropertyTermName>Mime</ccts:PropertyTermName>
|
||||
<ccts:RepresentationTermName>Code</ccts:RepresentationTermName>
|
||||
<ccts:PrimitiveType>normalizedString</ccts:PrimitiveType>
|
||||
</xsd:documentation>
|
||||
</xsd:annotation>
|
||||
</xsd:attribute>
|
||||
</xsd:restriction>
|
||||
</xsd:simpleContent>
|
||||
</xsd:complexType>
|
||||
|
||||
<xsd:complexType name="VideoType">
|
||||
<xsd:annotation>
|
||||
<xsd:documentation xml:lang="en">
|
||||
<ccts:UniqueID>UBLUDT000006</ccts:UniqueID>
|
||||
<ccts:CategoryCode>UDT</ccts:CategoryCode>
|
||||
<ccts:DictionaryEntryName>Video. Type</ccts:DictionaryEntryName>
|
||||
<ccts:VersionID>1.0</ccts:VersionID>
|
||||
<ccts:Definition>A video representation.</ccts:Definition>
|
||||
<ccts:RepresentationTermName>Video</ccts:RepresentationTermName>
|
||||
<ccts:PrimitiveType>binary</ccts:PrimitiveType>
|
||||
</xsd:documentation>
|
||||
</xsd:annotation>
|
||||
<xsd:simpleContent>
|
||||
<xsd:restriction base="ccts-cct:BinaryObjectType">
|
||||
<xsd:attribute name="mimeCode" type="xsd:normalizedString" use="required">
|
||||
<xsd:annotation>
|
||||
<xsd:documentation xml:lang="en">
|
||||
<ccts:UniqueID>UNDT000006-SC3</ccts:UniqueID>
|
||||
<ccts:CategoryCode>SC</ccts:CategoryCode>
|
||||
<ccts:DictionaryEntryName>Video. Mime. Code</ccts:DictionaryEntryName>
|
||||
<ccts:Definition>The mime type of the video object.</ccts:Definition>
|
||||
<ccts:ObjectClass>Video</ccts:ObjectClass>
|
||||
<ccts:PropertyTermName>Mime</ccts:PropertyTermName>
|
||||
<ccts:RepresentationTermName>Code</ccts:RepresentationTermName>
|
||||
<ccts:PrimitiveType>normalizedString</ccts:PrimitiveType>
|
||||
</xsd:documentation>
|
||||
</xsd:annotation>
|
||||
</xsd:attribute>
|
||||
</xsd:restriction>
|
||||
</xsd:simpleContent>
|
||||
</xsd:complexType>
|
||||
|
||||
<xsd:complexType name="CodeType">
|
||||
<xsd:annotation>
|
||||
<xsd:documentation xml:lang="en">
|
||||
<ccts:UniqueID>UBLUDT000007</ccts:UniqueID>
|
||||
<ccts:CategoryCode>UDT</ccts:CategoryCode>
|
||||
<ccts:DictionaryEntryName>Code. Type</ccts:DictionaryEntryName>
|
||||
<ccts:VersionID>1.0</ccts:VersionID>
|
||||
<ccts:Definition>A character string (letters, figures, or symbols) that for brevity and/or language
|
||||
independence may be used to represent or replace a definitive value or text of an attribute,
|
||||
together with relevant supplementary information.
|
||||
</ccts:Definition>
|
||||
<ccts:RepresentationTermName>Code</ccts:RepresentationTermName>
|
||||
<ccts:PrimitiveType>string</ccts:PrimitiveType>
|
||||
<ccts:UsageRule>Other supplementary components in the CCT are captured as part of the token and name for
|
||||
the schema module containing the code list and thus, are not declared as attributes.
|
||||
</ccts:UsageRule>
|
||||
</xsd:documentation>
|
||||
</xsd:annotation>
|
||||
<xsd:simpleContent>
|
||||
<xsd:extension base="ccts-cct:CodeType"/>
|
||||
</xsd:simpleContent>
|
||||
</xsd:complexType>
|
||||
|
||||
<xsd:complexType name="DateTimeType">
|
||||
<xsd:annotation>
|
||||
<xsd:documentation xml:lang="en">
|
||||
<ccts:UniqueID>UBLUDT000008</ccts:UniqueID>
|
||||
<ccts:CategoryCode>UDT</ccts:CategoryCode>
|
||||
<ccts:DictionaryEntryName>Date Time. Type</ccts:DictionaryEntryName>
|
||||
<ccts:VersionID>1.0</ccts:VersionID>
|
||||
<ccts:Definition>A particular point in the progression of time, together with relevant supplementary
|
||||
information.
|
||||
</ccts:Definition>
|
||||
<ccts:RepresentationTermName>Date Time</ccts:RepresentationTermName>
|
||||
<ccts:PrimitiveType>string</ccts:PrimitiveType>
|
||||
<ccts:UsageRule>Can be used for a date and/or time.</ccts:UsageRule>
|
||||
</xsd:documentation>
|
||||
</xsd:annotation>
|
||||
<xsd:simpleContent>
|
||||
<xsd:extension base="xsd:dateTime"/>
|
||||
</xsd:simpleContent>
|
||||
</xsd:complexType>
|
||||
|
||||
<xsd:complexType name="DateType">
|
||||
<xsd:annotation>
|
||||
<xsd:documentation xml:lang="en">
|
||||
<ccts:UniqueID>UBLUDT000009</ccts:UniqueID>
|
||||
<ccts:CategoryCode>UDT</ccts:CategoryCode>
|
||||
<ccts:DictionaryEntryName>Date. Type</ccts:DictionaryEntryName>
|
||||
<ccts:VersionID>1.0</ccts:VersionID>
|
||||
<ccts:Definition>One calendar day according the Gregorian calendar.</ccts:Definition>
|
||||
<ccts:RepresentationTermName>Date</ccts:RepresentationTermName>
|
||||
<ccts:PrimitiveType>string</ccts:PrimitiveType>
|
||||
</xsd:documentation>
|
||||
</xsd:annotation>
|
||||
<xsd:simpleContent>
|
||||
<xsd:extension base="xsd:date"/>
|
||||
</xsd:simpleContent>
|
||||
</xsd:complexType>
|
||||
|
||||
<xsd:complexType name="TimeType">
|
||||
<xsd:annotation>
|
||||
<xsd:documentation xml:lang="en">
|
||||
<ccts:UniqueID>UBLUDT0000010</ccts:UniqueID>
|
||||
<ccts:CategoryCode>UDT</ccts:CategoryCode>
|
||||
<ccts:DictionaryEntryName>Time. Type</ccts:DictionaryEntryName>
|
||||
<ccts:VersionID>1.0</ccts:VersionID>
|
||||
<ccts:Definition>An instance of time that occurs every day.</ccts:Definition>
|
||||
<ccts:RepresentationTermName>Time</ccts:RepresentationTermName>
|
||||
<ccts:PrimitiveType>string</ccts:PrimitiveType>
|
||||
</xsd:documentation>
|
||||
</xsd:annotation>
|
||||
<xsd:simpleContent>
|
||||
<xsd:extension base="xsd:time"/>
|
||||
</xsd:simpleContent>
|
||||
</xsd:complexType>
|
||||
|
||||
<xsd:complexType name="IdentifierType">
|
||||
<xsd:annotation>
|
||||
<xsd:documentation xml:lang="en">
|
||||
<ccts:UniqueID>UBLUDT0000011</ccts:UniqueID>
|
||||
<ccts:CategoryCode>UDT</ccts:CategoryCode>
|
||||
<ccts:DictionaryEntryName>Identifier. Type</ccts:DictionaryEntryName>
|
||||
<ccts:VersionID>1.0</ccts:VersionID>
|
||||
<ccts:Definition>A character string to identify and uniquely distinguish one instance of an object in an
|
||||
identification scheme from all other objects in the same scheme, together with relevant
|
||||
supplementary information.
|
||||
</ccts:Definition>
|
||||
<ccts:RepresentationTermName>Identifier</ccts:RepresentationTermName>
|
||||
<ccts:PrimitiveType>string</ccts:PrimitiveType>
|
||||
<ccts:UsageRule>Other supplementary components in the CCT are captured as part of the token and name for
|
||||
the schema module containing the identifier list and thus, are not declared as attributes.
|
||||
</ccts:UsageRule>
|
||||
</xsd:documentation>
|
||||
</xsd:annotation>
|
||||
<xsd:simpleContent>
|
||||
<xsd:extension base="ccts-cct:IdentifierType"/>
|
||||
</xsd:simpleContent>
|
||||
</xsd:complexType>
|
||||
|
||||
<xsd:complexType name="IndicatorType">
|
||||
<xsd:annotation>
|
||||
<xsd:documentation xml:lang="en">
|
||||
<ccts:UniqueID>UBLUDT0000012</ccts:UniqueID>
|
||||
<ccts:CategoryCode>UDT</ccts:CategoryCode>
|
||||
<ccts:DictionaryEntryName>Indicator. Type</ccts:DictionaryEntryName>
|
||||
<ccts:VersionID>1.0</ccts:VersionID>
|
||||
<ccts:Definition>A list of two mutually exclusive Boolean values that express the only possible states
|
||||
of a property.
|
||||
</ccts:Definition>
|
||||
<ccts:RepresentationTermName>Indicator</ccts:RepresentationTermName>
|
||||
<ccts:PrimitiveType>string</ccts:PrimitiveType>
|
||||
</xsd:documentation>
|
||||
</xsd:annotation>
|
||||
<xsd:simpleContent>
|
||||
<xsd:extension base="xsd:boolean"/>
|
||||
</xsd:simpleContent>
|
||||
</xsd:complexType>
|
||||
|
||||
<xsd:complexType name="MeasureType">
|
||||
<xsd:annotation>
|
||||
<xsd:documentation xml:lang="en">
|
||||
<ccts:UniqueID>UBLUDT0000013</ccts:UniqueID>
|
||||
<ccts:CategoryCode>UDT</ccts:CategoryCode>
|
||||
<ccts:DictionaryEntryName>Measure. Type</ccts:DictionaryEntryName>
|
||||
<ccts:VersionID>1.0</ccts:VersionID>
|
||||
<ccts:Definition>A numeric value determined by measuring an object using a specified unit of measure.
|
||||
</ccts:Definition>
|
||||
<ccts:RepresentationTermName>Measure</ccts:RepresentationTermName>
|
||||
<ccts:PropertyTermName>Type</ccts:PropertyTermName>
|
||||
<ccts:PrimitiveType>decimal</ccts:PrimitiveType>
|
||||
</xsd:documentation>
|
||||
</xsd:annotation>
|
||||
<xsd:simpleContent>
|
||||
<xsd:restriction base="ccts-cct:MeasureType">
|
||||
<xsd:attribute name="unitCode" type="xsd:normalizedString" use="required">
|
||||
<xsd:annotation>
|
||||
<xsd:documentation xml:lang="en">
|
||||
<ccts:UniqueID>UNDT000013-SC2</ccts:UniqueID>
|
||||
<ccts:CategoryCode>SC</ccts:CategoryCode>
|
||||
<ccts:DictionaryEntryName>Measure. Unit. Code</ccts:DictionaryEntryName>
|
||||
<ccts:Definition>The type of unit of measure.</ccts:Definition>
|
||||
<ccts:ObjectClass>Measure Unit</ccts:ObjectClass>
|
||||
<ccts:PropertyTermName>Code</ccts:PropertyTermName>
|
||||
<ccts:RepresentationTermName>Code</ccts:RepresentationTermName>
|
||||
<ccts:PrimitiveType>normalizedString</ccts:PrimitiveType>
|
||||
<ccts:UsageRule>Reference UNECE Rec. 20 and X12 355</ccts:UsageRule>
|
||||
</xsd:documentation>
|
||||
</xsd:annotation>
|
||||
</xsd:attribute>
|
||||
</xsd:restriction>
|
||||
</xsd:simpleContent>
|
||||
</xsd:complexType>
|
||||
|
||||
<xsd:complexType name="NumericType">
|
||||
<xsd:annotation>
|
||||
<xsd:documentation xml:lang="en">
|
||||
<ccts:UniqueID>UBLUDT0000014</ccts:UniqueID>
|
||||
<ccts:CategoryCode>UDT</ccts:CategoryCode>
|
||||
<ccts:DictionaryEntryName>Numeric. Type</ccts:DictionaryEntryName>
|
||||
<ccts:VersionID>1.0</ccts:VersionID>
|
||||
<ccts:Definition>Numeric information that is assigned or is determined by calculation, counting, or
|
||||
sequencing. It does not require a unit of quantity or unit of measure.
|
||||
</ccts:Definition>
|
||||
<ccts:RepresentationTermName>Numeric</ccts:RepresentationTermName>
|
||||
<ccts:PrimitiveType>string</ccts:PrimitiveType>
|
||||
</xsd:documentation>
|
||||
</xsd:annotation>
|
||||
<xsd:simpleContent>
|
||||
<xsd:extension base="ccts-cct:NumericType"/>
|
||||
</xsd:simpleContent>
|
||||
</xsd:complexType>
|
||||
|
||||
<xsd:complexType name="ValueType">
|
||||
<xsd:annotation>
|
||||
<xsd:documentation xml:lang="en">
|
||||
<ccts:UniqueID>UBLUDT0000015</ccts:UniqueID>
|
||||
<ccts:CategoryCode>UDT</ccts:CategoryCode>
|
||||
<ccts:VersionID>1.0</ccts:VersionID>
|
||||
<ccts:DictionaryEntryName>Value. Type</ccts:DictionaryEntryName>
|
||||
<ccts:Definition>Numeric information that is assigned or is determined by calculation, counting, or
|
||||
sequencing. It does not require a unit of quantity or unit of measure.
|
||||
</ccts:Definition>
|
||||
<ccts:RepresentationTermName>Value</ccts:RepresentationTermName>
|
||||
<ccts:PrimitiveType>string</ccts:PrimitiveType>
|
||||
</xsd:documentation>
|
||||
</xsd:annotation>
|
||||
<xsd:simpleContent>
|
||||
<xsd:extension base="ccts-cct:NumericType"/>
|
||||
</xsd:simpleContent>
|
||||
</xsd:complexType>
|
||||
|
||||
<xsd:complexType name="PercentType">
|
||||
<xsd:annotation>
|
||||
<xsd:documentation xml:lang="en">
|
||||
<ccts:UniqueID>UBLUDT0000016</ccts:UniqueID>
|
||||
<ccts:CategoryCode>UDT</ccts:CategoryCode>
|
||||
<ccts:VersionID>1.0</ccts:VersionID>
|
||||
<ccts:DictionaryEntryName>Percent. Type</ccts:DictionaryEntryName>
|
||||
<ccts:Definition>Numeric information that is assigned or is determined by calculation, counting, or
|
||||
sequencing and is expressed as a percentage. It does not require a unit of quantity or unit of
|
||||
measure.
|
||||
</ccts:Definition>
|
||||
<ccts:RepresentationTermName>Percent</ccts:RepresentationTermName>
|
||||
<ccts:PrimitiveType>string</ccts:PrimitiveType>
|
||||
</xsd:documentation>
|
||||
</xsd:annotation>
|
||||
<xsd:simpleContent>
|
||||
<xsd:extension base="ccts-cct:NumericType"/>
|
||||
</xsd:simpleContent>
|
||||
</xsd:complexType>
|
||||
|
||||
<xsd:complexType name="RateType">
|
||||
<xsd:annotation>
|
||||
<xsd:documentation xml:lang="en">
|
||||
<ccts:UniqueID>UBLUDT0000017</ccts:UniqueID>
|
||||
<ccts:CategoryCode>UDT</ccts:CategoryCode>
|
||||
<ccts:VersionID>1.0</ccts:VersionID>
|
||||
<ccts:DictionaryEntryName>Rate. Type</ccts:DictionaryEntryName>
|
||||
<ccts:Definition>A numeric expression of a rate that is assigned or is determined by calculation,
|
||||
counting, or sequencing. It does not require a unit of quantity or unit of measure.
|
||||
</ccts:Definition>
|
||||
<ccts:RepresentationTermName>Rate</ccts:RepresentationTermName>
|
||||
<ccts:PrimitiveType>string</ccts:PrimitiveType>
|
||||
</xsd:documentation>
|
||||
</xsd:annotation>
|
||||
<xsd:simpleContent>
|
||||
<xsd:extension base="ccts-cct:NumericType"/>
|
||||
</xsd:simpleContent>
|
||||
</xsd:complexType>
|
||||
|
||||
<xsd:complexType name="QuantityType">
|
||||
<xsd:annotation>
|
||||
<xsd:documentation xml:lang="en">
|
||||
<ccts:UniqueID>UBLUDT0000018</ccts:UniqueID>
|
||||
<ccts:CategoryCode>UDT</ccts:CategoryCode>
|
||||
<ccts:DictionaryEntryName>Quantity. Type</ccts:DictionaryEntryName>
|
||||
<ccts:VersionID>1.0</ccts:VersionID>
|
||||
<ccts:Definition>A counted number of non-monetary units, possibly including a fractional part.
|
||||
</ccts:Definition>
|
||||
<ccts:RepresentationTermName>Quantity</ccts:RepresentationTermName>
|
||||
<ccts:PrimitiveType>decimal</ccts:PrimitiveType>
|
||||
</xsd:documentation>
|
||||
</xsd:annotation>
|
||||
<xsd:simpleContent>
|
||||
<xsd:extension base="ccts-cct:QuantityType"/>
|
||||
</xsd:simpleContent>
|
||||
</xsd:complexType>
|
||||
|
||||
<xsd:complexType name="TextType">
|
||||
<xsd:annotation>
|
||||
<xsd:documentation xml:lang="en">
|
||||
<ccts:UniqueID>UBLUDT0000019</ccts:UniqueID>
|
||||
<ccts:CategoryCode>UDT</ccts:CategoryCode>
|
||||
<ccts:DictionaryEntryName>Text. Type</ccts:DictionaryEntryName>
|
||||
<ccts:VersionID>1.0</ccts:VersionID>
|
||||
<ccts:Definition>A character string (i.e. a finite set of characters), generally in the form of words of
|
||||
a language.
|
||||
</ccts:Definition>
|
||||
<ccts:RepresentationTermName>Text</ccts:RepresentationTermName>
|
||||
<ccts:PrimitiveType>string</ccts:PrimitiveType>
|
||||
</xsd:documentation>
|
||||
</xsd:annotation>
|
||||
<xsd:simpleContent>
|
||||
<xsd:extension base="ccts-cct:TextType"/>
|
||||
</xsd:simpleContent>
|
||||
</xsd:complexType>
|
||||
|
||||
<xsd:complexType name="NameType">
|
||||
<xsd:annotation>
|
||||
<xsd:documentation xml:lang="en">
|
||||
<ccts:UniqueID>UBLUDT0000020</ccts:UniqueID>
|
||||
<ccts:CategoryCode>UDT</ccts:CategoryCode>
|
||||
<ccts:DictionaryEntryName>Name. Type</ccts:DictionaryEntryName>
|
||||
<ccts:VersionID>1.0</ccts:VersionID>
|
||||
<ccts:Definition>A character string that constitutes the distinctive designation of a person, place,
|
||||
thing or concept.
|
||||
</ccts:Definition>
|
||||
<ccts:RepresentationTermName>Name</ccts:RepresentationTermName>
|
||||
<ccts:PrimitiveType>string</ccts:PrimitiveType>
|
||||
</xsd:documentation>
|
||||
</xsd:annotation>
|
||||
<xsd:simpleContent>
|
||||
<xsd:extension base="ccts-cct:TextType"/>
|
||||
</xsd:simpleContent>
|
||||
</xsd:complexType>
|
||||
</xsd:schema><!-- ===== Copyright Notice ===== --><!--
|
||||
OASIS takes no position regarding the validity or scope of any
|
||||
intellectual property or other rights that might be claimed to pertain
|
||||
to the implementation or use of the technology described in this
|
||||
document or the extent to which any license under such rights
|
||||
might or might not be available; neither does it represent that it has
|
||||
made any effort to identify any such rights. Information on OASIS's
|
||||
procedures with respect to rights in OASIS specifications can be
|
||||
found at the OASIS website. Copies of claims of rights made
|
||||
available for publication and any assurances of licenses to be made
|
||||
available, or the result of an attempt made to obtain a general
|
||||
license or permission for the use of such proprietary rights by
|
||||
implementors or users of this specification, can be obtained from
|
||||
the OASIS Executive Director.
|
||||
|
||||
OASIS invites any interested party to bring to its attention any
|
||||
copyrights, patents or patent applications, or other proprietary
|
||||
rights which may cover technology that may be required to
|
||||
implement this specification. Please address the information to the
|
||||
OASIS Executive Director.
|
||||
|
||||
This document and translations of it may be copied and furnished to
|
||||
others, and derivative works that comment on or otherwise explain
|
||||
it or assist in its implementation may be prepared, copied,
|
||||
published and distributed, in whole or in part, without restriction of
|
||||
any kind, provided that the above copyright notice and this
|
||||
paragraph are included on all such copies and derivative works.
|
||||
However, this document itself may not be modified in any way,
|
||||
such as by removing the copyright notice or references to OASIS,
|
||||
except as needed for the purpose of developing OASIS
|
||||
specifications, in which case the procedures for copyrights defined
|
||||
in the OASIS Intellectual Property Rights document must be
|
||||
followed, or as required to translate it into languages other than
|
||||
English.
|
||||
|
||||
The limited permissions granted above are perpetual and will not be
|
||||
revoked by OASIS or its successors or assigns.
|
||||
|
||||
This document and the information contained herein is provided on
|
||||
an "AS IS" basis and OASIS DISCLAIMS ALL WARRANTIES,
|
||||
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY
|
||||
WARRANTY THAT THE USE OF THE INFORMATION HEREIN
|
||||
WILL NOT INFRINGE ANY RIGHTS OR ANY IMPLIED
|
||||
WARRANTIES OF MERCHANTABILITY OR FITNESS FOR A
|
||||
PARTICULAR PURPOSE.
|
||||
-->
|
||||
|
|
@ -0,0 +1,499 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!--
|
||||
~ Licensed to the Koordinierungsstelle für IT-Standards (KoSIT) under
|
||||
~ one or more contributor license agreements. See the NOTICE file
|
||||
~ distributed with this work for additional information
|
||||
~ regarding copyright ownership. KoSIT licenses this file
|
||||
~ to you under the Apache License, Version 2.0 (the
|
||||
~ "License"); you may not use this file except in compliance
|
||||
~ with the License. You may obtain a copy of the License at
|
||||
~
|
||||
~ http://www.apache.org/licenses/LICENSE-2.0
|
||||
~
|
||||
~ Unless required by applicable law or agreed to in writing,
|
||||
~ software distributed under the License is distributed on an
|
||||
~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||
~ KIND, either express or implied. See the License for the
|
||||
~ specific language governing permissions and limitations
|
||||
~ under the License.
|
||||
-->
|
||||
|
||||
<!--
|
||||
Library: OASIS Universal Business Language (UBL) 2.1 OS
|
||||
http://docs.oasis-open.org/ubl/os-UBL-2.1/
|
||||
Release Date: 04 November 2013
|
||||
Module: UBL-XAdESv132-2.1.xsd
|
||||
Generated on: 2011-02-21 17:20(UTC)
|
||||
|
||||
This is a copy of http://uri.etsi.org/01903/v1.3.2/XAdES.xsd modified
|
||||
only to change the importing URI for the XML DSig schema.
|
||||
-->
|
||||
<xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:ds="http://www.w3.org/2000/09/xmldsig#"
|
||||
targetNamespace="http://uri.etsi.org/01903/v1.3.2#" xmlns="http://uri.etsi.org/01903/v1.3.2#"
|
||||
elementFormDefault="qualified">
|
||||
<xsd:import namespace="http://www.w3.org/2000/09/xmldsig#" schemaLocation="UBL-xmldsig-core-schema-2.1.xsd"/>
|
||||
<!-- Start auxiliary types definitions: AnyType, ObjectIdentifierType,
|
||||
EncapsulatedPKIDataType and containers for time-stamp tokens -->
|
||||
<!-- Start AnyType -->
|
||||
<xsd:element name="Any" type="AnyType"/>
|
||||
<xsd:complexType name="AnyType" mixed="true">
|
||||
<xsd:sequence minOccurs="0" maxOccurs="unbounded">
|
||||
<xsd:any namespace="##any" processContents="lax"/>
|
||||
</xsd:sequence>
|
||||
<xsd:anyAttribute namespace="##any"/>
|
||||
</xsd:complexType>
|
||||
<!-- End AnyType -->
|
||||
<!-- Start ObjectIdentifierType-->
|
||||
<xsd:element name="ObjectIdentifier" type="ObjectIdentifierType"/>
|
||||
<xsd:complexType name="ObjectIdentifierType">
|
||||
<xsd:sequence>
|
||||
<xsd:element name="Identifier" type="IdentifierType"/>
|
||||
<xsd:element name="Description" type="xsd:string" minOccurs="0"/>
|
||||
<xsd:element name="DocumentationReferences" type="DocumentationReferencesType" minOccurs="0"/>
|
||||
</xsd:sequence>
|
||||
</xsd:complexType>
|
||||
<xsd:complexType name="IdentifierType">
|
||||
<xsd:simpleContent>
|
||||
<xsd:extension base="xsd:anyURI">
|
||||
<xsd:attribute name="Qualifier" type="QualifierType" use="optional"/>
|
||||
</xsd:extension>
|
||||
</xsd:simpleContent>
|
||||
</xsd:complexType>
|
||||
<xsd:simpleType name="QualifierType">
|
||||
<xsd:restriction base="xsd:string">
|
||||
<xsd:enumeration value="OIDAsURI"/>
|
||||
<xsd:enumeration value="OIDAsURN"/>
|
||||
</xsd:restriction>
|
||||
</xsd:simpleType>
|
||||
<xsd:complexType name="DocumentationReferencesType">
|
||||
<xsd:sequence maxOccurs="unbounded">
|
||||
<xsd:element name="DocumentationReference" type="xsd:anyURI"/>
|
||||
</xsd:sequence>
|
||||
</xsd:complexType>
|
||||
<!-- End ObjectIdentifierType-->
|
||||
<!-- Start EncapsulatedPKIDataType-->
|
||||
<xsd:element name="EncapsulatedPKIData" type="EncapsulatedPKIDataType"/>
|
||||
<xsd:complexType name="EncapsulatedPKIDataType">
|
||||
<xsd:simpleContent>
|
||||
<xsd:extension base="xsd:base64Binary">
|
||||
<xsd:attribute name="Id" type="xsd:ID" use="optional"/>
|
||||
<xsd:attribute name="Encoding" type="xsd:anyURI" use="optional"/>
|
||||
</xsd:extension>
|
||||
</xsd:simpleContent>
|
||||
</xsd:complexType>
|
||||
<!-- End EncapsulatedPKIDataType -->
|
||||
<!-- Start time-stamp containers types -->
|
||||
<!-- Start GenericTimeStampType -->
|
||||
<xsd:element name="Include" type="IncludeType"/>
|
||||
<xsd:complexType name="IncludeType">
|
||||
<xsd:attribute name="URI" type="xsd:anyURI" use="required"/>
|
||||
<xsd:attribute name="referencedData" type="xsd:boolean" use="optional"/>
|
||||
</xsd:complexType>
|
||||
<xsd:element name="ReferenceInfo" type="ReferenceInfoType"/>
|
||||
<xsd:complexType name="ReferenceInfoType">
|
||||
<xsd:sequence>
|
||||
<xsd:element ref="ds:DigestMethod"/>
|
||||
<xsd:element ref="ds:DigestValue"/>
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="Id" type="xsd:ID" use="optional"/>
|
||||
<xsd:attribute name="URI" type="xsd:anyURI" use="optional"/>
|
||||
</xsd:complexType>
|
||||
<xsd:complexType name="GenericTimeStampType" abstract="true">
|
||||
<xsd:sequence>
|
||||
<xsd:choice minOccurs="0">
|
||||
<xsd:element ref="Include" minOccurs="0" maxOccurs="unbounded"/>
|
||||
<xsd:element ref="ReferenceInfo" maxOccurs="unbounded"/>
|
||||
</xsd:choice>
|
||||
<xsd:element ref="ds:CanonicalizationMethod" minOccurs="0"/>
|
||||
<xsd:choice maxOccurs="unbounded">
|
||||
<xsd:element name="EncapsulatedTimeStamp" type="EncapsulatedPKIDataType"/>
|
||||
<xsd:element name="XMLTimeStamp" type="AnyType"/>
|
||||
</xsd:choice>
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="Id" type="xsd:ID" use="optional"/>
|
||||
</xsd:complexType>
|
||||
<!-- End GenericTimeStampType -->
|
||||
<!-- Start XAdESTimeStampType -->
|
||||
<xsd:element name="XAdESTimeStamp" type="XAdESTimeStampType"/>
|
||||
<xsd:complexType name="XAdESTimeStampType">
|
||||
<xsd:complexContent>
|
||||
<xsd:restriction base="GenericTimeStampType">
|
||||
<xsd:sequence>
|
||||
<xsd:element ref="Include" minOccurs="0" maxOccurs="unbounded"/>
|
||||
<xsd:element ref="ds:CanonicalizationMethod" minOccurs="0"/>
|
||||
<xsd:choice maxOccurs="unbounded">
|
||||
<xsd:element name="EncapsulatedTimeStamp" type="EncapsulatedPKIDataType"/>
|
||||
<xsd:element name="XMLTimeStamp" type="AnyType"/>
|
||||
</xsd:choice>
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="Id" type="xsd:ID" use="optional"/>
|
||||
</xsd:restriction>
|
||||
</xsd:complexContent>
|
||||
</xsd:complexType>
|
||||
<!-- End XAdESTimeStampType -->
|
||||
<!-- Start OtherTimeStampType -->
|
||||
<xsd:element name="OtherTimeStamp" type="OtherTimeStampType"/>
|
||||
<xsd:complexType name="OtherTimeStampType">
|
||||
<xsd:complexContent>
|
||||
<xsd:restriction base="GenericTimeStampType">
|
||||
<xsd:sequence>
|
||||
<xsd:element ref="ReferenceInfo" maxOccurs="unbounded"/>
|
||||
<xsd:element ref="ds:CanonicalizationMethod" minOccurs="0"/>
|
||||
<xsd:choice>
|
||||
<xsd:element name="EncapsulatedTimeStamp" type="EncapsulatedPKIDataType"/>
|
||||
<xsd:element name="XMLTimeStamp" type="AnyType"/>
|
||||
</xsd:choice>
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="Id" type="xsd:ID" use="optional"/>
|
||||
</xsd:restriction>
|
||||
</xsd:complexContent>
|
||||
</xsd:complexType>
|
||||
<!-- End OtherTimeStampType -->
|
||||
<!-- End time-stamp containers types -->
|
||||
<!-- End auxiliary types definitions-->
|
||||
<!-- Start container types -->
|
||||
<!-- Start QualifyingProperties -->
|
||||
<xsd:element name="QualifyingProperties" type="QualifyingPropertiesType"/>
|
||||
<xsd:complexType name="QualifyingPropertiesType">
|
||||
<xsd:sequence>
|
||||
<xsd:element name="SignedProperties" type="SignedPropertiesType" minOccurs="0"/>
|
||||
<xsd:element name="UnsignedProperties" type="UnsignedPropertiesType" minOccurs="0"/>
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="Target" type="xsd:anyURI" use="required"/>
|
||||
<xsd:attribute name="Id" type="xsd:ID" use="optional"/>
|
||||
</xsd:complexType>
|
||||
<!-- End QualifyingProperties -->
|
||||
<!-- Start SignedProperties-->
|
||||
<xsd:element name="SignedProperties" type="SignedPropertiesType"/>
|
||||
<xsd:complexType name="SignedPropertiesType">
|
||||
<xsd:sequence>
|
||||
<xsd:element name="SignedSignatureProperties" type="SignedSignaturePropertiesType" minOccurs="0"/>
|
||||
<xsd:element name="SignedDataObjectProperties" type="SignedDataObjectPropertiesType" minOccurs="0"/>
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="Id" type="xsd:ID" use="optional"/>
|
||||
</xsd:complexType>
|
||||
<!-- End SignedProperties-->
|
||||
<!-- Start UnsignedProperties-->
|
||||
<xsd:element name="UnsignedProperties" type="UnsignedPropertiesType"/>
|
||||
<xsd:complexType name="UnsignedPropertiesType">
|
||||
<xsd:sequence>
|
||||
<xsd:element name="UnsignedSignatureProperties" type="UnsignedSignaturePropertiesType" minOccurs="0"/>
|
||||
<xsd:element name="UnsignedDataObjectProperties" type="UnsignedDataObjectPropertiesType" minOccurs="0"/>
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="Id" type="xsd:ID" use="optional"/>
|
||||
</xsd:complexType>
|
||||
<!-- End UnsignedProperties-->
|
||||
<!-- Start SignedSignatureProperties-->
|
||||
<xsd:element name="SignedSignatureProperties" type="SignedSignaturePropertiesType"/>
|
||||
<xsd:complexType name="SignedSignaturePropertiesType">
|
||||
<xsd:sequence>
|
||||
<xsd:element name="SigningTime" type="xsd:dateTime" minOccurs="0"/>
|
||||
<xsd:element name="SigningCertificate" type="CertIDListType" minOccurs="0"/>
|
||||
<xsd:element name="SignaturePolicyIdentifier" type="SignaturePolicyIdentifierType" minOccurs="0"/>
|
||||
<xsd:element name="SignatureProductionPlace" type="SignatureProductionPlaceType" minOccurs="0"/>
|
||||
<xsd:element name="SignerRole" type="SignerRoleType" minOccurs="0"/>
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="Id" type="xsd:ID" use="optional"/>
|
||||
</xsd:complexType>
|
||||
<!-- End SignedSignatureProperties-->
|
||||
<!-- Start SignedDataObjectProperties-->
|
||||
<xsd:element name="SignedDataObjectProperties" type="SignedDataObjectPropertiesType"/>
|
||||
<xsd:complexType name="SignedDataObjectPropertiesType">
|
||||
<xsd:sequence>
|
||||
<xsd:element name="DataObjectFormat" type="DataObjectFormatType" minOccurs="0" maxOccurs="unbounded"/>
|
||||
<xsd:element name="CommitmentTypeIndication" type="CommitmentTypeIndicationType" minOccurs="0"
|
||||
maxOccurs="unbounded"/>
|
||||
<xsd:element name="AllDataObjectsTimeStamp" type="XAdESTimeStampType" minOccurs="0" maxOccurs="unbounded"/>
|
||||
<xsd:element name="IndividualDataObjectsTimeStamp" type="XAdESTimeStampType" minOccurs="0"
|
||||
maxOccurs="unbounded"/>
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="Id" type="xsd:ID" use="optional"/>
|
||||
</xsd:complexType>
|
||||
<!-- End SignedDataObjectProperties-->
|
||||
<!-- Start UnsignedSignatureProperties-->
|
||||
<xsd:element name="UnsignedSignatureProperties" type="UnsignedSignaturePropertiesType"/>
|
||||
<xsd:complexType name="UnsignedSignaturePropertiesType">
|
||||
<xsd:choice maxOccurs="unbounded">
|
||||
<xsd:element name="CounterSignature" type="CounterSignatureType"/>
|
||||
<xsd:element name="SignatureTimeStamp" type="XAdESTimeStampType"/>
|
||||
<xsd:element name="CompleteCertificateRefs" type="CompleteCertificateRefsType"/>
|
||||
<xsd:element name="CompleteRevocationRefs" type="CompleteRevocationRefsType"/>
|
||||
<xsd:element name="AttributeCertificateRefs" type="CompleteCertificateRefsType"/>
|
||||
<xsd:element name="AttributeRevocationRefs" type="CompleteRevocationRefsType"/>
|
||||
<xsd:element name="SigAndRefsTimeStamp" type="XAdESTimeStampType"/>
|
||||
<xsd:element name="RefsOnlyTimeStamp" type="XAdESTimeStampType"/>
|
||||
<xsd:element name="CertificateValues" type="CertificateValuesType"/>
|
||||
<xsd:element name="RevocationValues" type="RevocationValuesType"/>
|
||||
<xsd:element name="AttrAuthoritiesCertValues" type="CertificateValuesType"/>
|
||||
<xsd:element name="AttributeRevocationValues" type="RevocationValuesType"/>
|
||||
<xsd:element name="ArchiveTimeStamp" type="XAdESTimeStampType"/>
|
||||
<xsd:any namespace="##other"/>
|
||||
</xsd:choice>
|
||||
<xsd:attribute name="Id" type="xsd:ID" use="optional"/>
|
||||
</xsd:complexType>
|
||||
<!-- End UnsignedSignatureProperties-->
|
||||
<!-- Start UnsignedDataObjectProperties-->
|
||||
<xsd:element name="UnsignedDataObjectProperties" type="UnsignedDataObjectPropertiesType"/>
|
||||
<xsd:complexType name="UnsignedDataObjectPropertiesType">
|
||||
<xsd:sequence>
|
||||
<xsd:element name="UnsignedDataObjectProperty" type="AnyType" maxOccurs="unbounded"/>
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="Id" type="xsd:ID" use="optional"/>
|
||||
</xsd:complexType>
|
||||
<!-- End UnsignedDataObjectProperties-->
|
||||
<!-- Start QualifyingPropertiesReference-->
|
||||
<xsd:element name="QualifyingPropertiesReference" type="QualifyingPropertiesReferenceType"/>
|
||||
<xsd:complexType name="QualifyingPropertiesReferenceType">
|
||||
<xsd:attribute name="URI" type="xsd:anyURI" use="required"/>
|
||||
<xsd:attribute name="Id" type="xsd:ID" use="optional"/>
|
||||
</xsd:complexType>
|
||||
<!-- End QualifyingPropertiesReference-->
|
||||
<!-- End container types -->
|
||||
<!-- Start SigningTime element -->
|
||||
<xsd:element name="SigningTime" type="xsd:dateTime"/>
|
||||
<!-- End SigningTime element -->
|
||||
<!-- Start SigningCertificate -->
|
||||
<xsd:element name="SigningCertificate" type="CertIDListType"/>
|
||||
<xsd:complexType name="CertIDListType">
|
||||
<xsd:sequence>
|
||||
<xsd:element name="Cert" type="CertIDType" maxOccurs="unbounded"/>
|
||||
</xsd:sequence>
|
||||
</xsd:complexType>
|
||||
<xsd:complexType name="CertIDType">
|
||||
<xsd:sequence>
|
||||
<xsd:element name="CertDigest" type="DigestAlgAndValueType"/>
|
||||
<xsd:element name="IssuerSerial" type="ds:X509IssuerSerialType"/>
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="URI" type="xsd:anyURI" use="optional"/>
|
||||
</xsd:complexType>
|
||||
<xsd:complexType name="DigestAlgAndValueType">
|
||||
<xsd:sequence>
|
||||
<xsd:element ref="ds:DigestMethod"/>
|
||||
<xsd:element ref="ds:DigestValue"/>
|
||||
</xsd:sequence>
|
||||
</xsd:complexType>
|
||||
<!-- End SigningCertificate -->
|
||||
<!-- Start SignaturePolicyIdentifier -->
|
||||
<xsd:element name="SignaturePolicyIdentifier" type="SignaturePolicyIdentifierType"/>
|
||||
<xsd:complexType name="SignaturePolicyIdentifierType">
|
||||
<xsd:choice>
|
||||
<xsd:element name="SignaturePolicyId" type="SignaturePolicyIdType"/>
|
||||
<xsd:element name="SignaturePolicyImplied"/>
|
||||
</xsd:choice>
|
||||
</xsd:complexType>
|
||||
<xsd:complexType name="SignaturePolicyIdType">
|
||||
<xsd:sequence>
|
||||
<xsd:element name="SigPolicyId" type="ObjectIdentifierType"/>
|
||||
<xsd:element ref="ds:Transforms" minOccurs="0"/>
|
||||
<xsd:element name="SigPolicyHash" type="DigestAlgAndValueType"/>
|
||||
<xsd:element name="SigPolicyQualifiers" type="SigPolicyQualifiersListType" minOccurs="0"/>
|
||||
</xsd:sequence>
|
||||
</xsd:complexType>
|
||||
<xsd:complexType name="SigPolicyQualifiersListType">
|
||||
<xsd:sequence>
|
||||
<xsd:element name="SigPolicyQualifier" type="AnyType" maxOccurs="unbounded"/>
|
||||
</xsd:sequence>
|
||||
</xsd:complexType>
|
||||
<xsd:element name="SPURI" type="xsd:anyURI"/>
|
||||
<xsd:element name="SPUserNotice" type="SPUserNoticeType"/>
|
||||
<xsd:complexType name="SPUserNoticeType">
|
||||
<xsd:sequence>
|
||||
<xsd:element name="NoticeRef" type="NoticeReferenceType" minOccurs="0"/>
|
||||
<xsd:element name="ExplicitText" type="xsd:string" minOccurs="0"/>
|
||||
</xsd:sequence>
|
||||
</xsd:complexType>
|
||||
<xsd:complexType name="NoticeReferenceType">
|
||||
<xsd:sequence>
|
||||
<xsd:element name="Organization" type="xsd:string"/>
|
||||
<xsd:element name="NoticeNumbers" type="IntegerListType"/>
|
||||
</xsd:sequence>
|
||||
</xsd:complexType>
|
||||
<xsd:complexType name="IntegerListType">
|
||||
<xsd:sequence>
|
||||
<xsd:element name="int" type="xsd:integer" minOccurs="0" maxOccurs="unbounded"/>
|
||||
</xsd:sequence>
|
||||
</xsd:complexType>
|
||||
<!-- End SignaturePolicyIdentifier -->
|
||||
<!-- Start CounterSignature -->
|
||||
<xsd:element name="CounterSignature" type="CounterSignatureType"/>
|
||||
<xsd:complexType name="CounterSignatureType">
|
||||
<xsd:sequence>
|
||||
<xsd:element ref="ds:Signature"/>
|
||||
</xsd:sequence>
|
||||
</xsd:complexType>
|
||||
<!-- End CounterSignature -->
|
||||
<!-- Start DataObjectFormat -->
|
||||
<xsd:element name="DataObjectFormat" type="DataObjectFormatType"/>
|
||||
<xsd:complexType name="DataObjectFormatType">
|
||||
<xsd:sequence>
|
||||
<xsd:element name="Description" type="xsd:string" minOccurs="0"/>
|
||||
<xsd:element name="ObjectIdentifier" type="ObjectIdentifierType" minOccurs="0"/>
|
||||
<xsd:element name="MimeType" type="xsd:string" minOccurs="0"/>
|
||||
<xsd:element name="Encoding" type="xsd:anyURI" minOccurs="0"/>
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="ObjectReference" type="xsd:anyURI" use="required"/>
|
||||
</xsd:complexType>
|
||||
<!-- End DataObjectFormat -->
|
||||
<!-- Start CommitmentTypeIndication -->
|
||||
<xsd:element name="CommitmentTypeIndication" type="CommitmentTypeIndicationType"/>
|
||||
<xsd:complexType name="CommitmentTypeIndicationType">
|
||||
<xsd:sequence>
|
||||
<xsd:element name="CommitmentTypeId" type="ObjectIdentifierType"/>
|
||||
<xsd:choice>
|
||||
<xsd:element name="ObjectReference" type="xsd:anyURI" maxOccurs="unbounded"/>
|
||||
<xsd:element name="AllSignedDataObjects"/>
|
||||
</xsd:choice>
|
||||
<xsd:element name="CommitmentTypeQualifiers" type="CommitmentTypeQualifiersListType" minOccurs="0"/>
|
||||
</xsd:sequence>
|
||||
</xsd:complexType>
|
||||
<xsd:complexType name="CommitmentTypeQualifiersListType">
|
||||
<xsd:sequence>
|
||||
<xsd:element name="CommitmentTypeQualifier" type="AnyType" minOccurs="0" maxOccurs="unbounded"/>
|
||||
</xsd:sequence>
|
||||
</xsd:complexType>
|
||||
<!-- End CommitmentTypeIndication -->
|
||||
<!-- Start SignatureProductionPlace -->
|
||||
<xsd:element name="SignatureProductionPlace" type="SignatureProductionPlaceType"/>
|
||||
<xsd:complexType name="SignatureProductionPlaceType">
|
||||
<xsd:sequence>
|
||||
<xsd:element name="City" type="xsd:string" minOccurs="0"/>
|
||||
<xsd:element name="StateOrProvince" type="xsd:string" minOccurs="0"/>
|
||||
<xsd:element name="PostalCode" type="xsd:string" minOccurs="0"/>
|
||||
<xsd:element name="CountryName" type="xsd:string" minOccurs="0"/>
|
||||
</xsd:sequence>
|
||||
</xsd:complexType>
|
||||
<!-- End SignatureProductionPlace -->
|
||||
<!-- Start SignerRole -->
|
||||
<xsd:element name="SignerRole" type="SignerRoleType"/>
|
||||
<xsd:complexType name="SignerRoleType">
|
||||
<xsd:sequence>
|
||||
<xsd:element name="ClaimedRoles" type="ClaimedRolesListType" minOccurs="0"/>
|
||||
<xsd:element name="CertifiedRoles" type="CertifiedRolesListType" minOccurs="0"/>
|
||||
</xsd:sequence>
|
||||
</xsd:complexType>
|
||||
<xsd:complexType name="ClaimedRolesListType">
|
||||
<xsd:sequence>
|
||||
<xsd:element name="ClaimedRole" type="AnyType" maxOccurs="unbounded"/>
|
||||
</xsd:sequence>
|
||||
</xsd:complexType>
|
||||
<xsd:complexType name="CertifiedRolesListType">
|
||||
<xsd:sequence>
|
||||
<xsd:element name="CertifiedRole" type="EncapsulatedPKIDataType" maxOccurs="unbounded"/>
|
||||
</xsd:sequence>
|
||||
</xsd:complexType>
|
||||
<!-- End SignerRole -->
|
||||
<xsd:element name="AllDataObjectsTimeStamp" type="XAdESTimeStampType"/>
|
||||
<xsd:element name="IndividualDataObjectsTimeStamp" type="XAdESTimeStampType"/>
|
||||
<xsd:element name="SignatureTimeStamp" type="XAdESTimeStampType"/>
|
||||
<!-- Start CompleteCertificateRefs -->
|
||||
<xsd:element name="CompleteCertificateRefs" type="CompleteCertificateRefsType"/>
|
||||
<xsd:complexType name="CompleteCertificateRefsType">
|
||||
<xsd:sequence>
|
||||
<xsd:element name="CertRefs" type="CertIDListType"/>
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="Id" type="xsd:ID" use="optional"/>
|
||||
</xsd:complexType>
|
||||
<!-- End CompleteCertificateRefs -->
|
||||
<!-- Start CompleteRevocationRefs-->
|
||||
<xsd:element name="CompleteRevocationRefs" type="CompleteRevocationRefsType"/>
|
||||
<xsd:complexType name="CompleteRevocationRefsType">
|
||||
<xsd:sequence>
|
||||
<xsd:element name="CRLRefs" type="CRLRefsType" minOccurs="0"/>
|
||||
<xsd:element name="OCSPRefs" type="OCSPRefsType" minOccurs="0"/>
|
||||
<xsd:element name="OtherRefs" type="OtherCertStatusRefsType" minOccurs="0"/>
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="Id" type="xsd:ID" use="optional"/>
|
||||
</xsd:complexType>
|
||||
<xsd:complexType name="CRLRefsType">
|
||||
<xsd:sequence>
|
||||
<xsd:element name="CRLRef" type="CRLRefType" maxOccurs="unbounded"/>
|
||||
</xsd:sequence>
|
||||
</xsd:complexType>
|
||||
<xsd:complexType name="CRLRefType">
|
||||
<xsd:sequence>
|
||||
<xsd:element name="DigestAlgAndValue" type="DigestAlgAndValueType"/>
|
||||
<xsd:element name="CRLIdentifier" type="CRLIdentifierType" minOccurs="0"/>
|
||||
</xsd:sequence>
|
||||
</xsd:complexType>
|
||||
<xsd:complexType name="CRLIdentifierType">
|
||||
<xsd:sequence>
|
||||
<xsd:element name="Issuer" type="xsd:string"/>
|
||||
<xsd:element name="IssueTime" type="xsd:dateTime"/>
|
||||
<xsd:element name="Number" type="xsd:integer" minOccurs="0"/>
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="URI" type="xsd:anyURI" use="optional"/>
|
||||
</xsd:complexType>
|
||||
<xsd:complexType name="OCSPRefsType">
|
||||
<xsd:sequence>
|
||||
<xsd:element name="OCSPRef" type="OCSPRefType" maxOccurs="unbounded"/>
|
||||
</xsd:sequence>
|
||||
</xsd:complexType>
|
||||
<xsd:complexType name="OCSPRefType">
|
||||
<xsd:sequence>
|
||||
<xsd:element name="OCSPIdentifier" type="OCSPIdentifierType"/>
|
||||
<xsd:element name="DigestAlgAndValue" type="DigestAlgAndValueType" minOccurs="0"/>
|
||||
</xsd:sequence>
|
||||
</xsd:complexType>
|
||||
<xsd:complexType name="ResponderIDType">
|
||||
<xsd:choice>
|
||||
<xsd:element name="ByName" type="xsd:string"/>
|
||||
<xsd:element name="ByKey" type="xsd:base64Binary"/>
|
||||
</xsd:choice>
|
||||
</xsd:complexType>
|
||||
<xsd:complexType name="OCSPIdentifierType">
|
||||
<xsd:sequence>
|
||||
<xsd:element name="ResponderID" type="ResponderIDType"/>
|
||||
<xsd:element name="ProducedAt" type="xsd:dateTime"/>
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="URI" type="xsd:anyURI" use="optional"/>
|
||||
</xsd:complexType>
|
||||
<xsd:complexType name="OtherCertStatusRefsType">
|
||||
<xsd:sequence>
|
||||
<xsd:element name="OtherRef" type="AnyType" maxOccurs="unbounded"/>
|
||||
</xsd:sequence>
|
||||
</xsd:complexType>
|
||||
<!-- End CompleteRevocationRefs-->
|
||||
<xsd:element name="AttributeCertificateRefs" type="CompleteCertificateRefsType"/>
|
||||
<xsd:element name="AttributeRevocationRefs" type="CompleteRevocationRefsType"/>
|
||||
<xsd:element name="SigAndRefsTimeStamp" type="XAdESTimeStampType"/>
|
||||
<xsd:element name="RefsOnlyTimeStamp" type="XAdESTimeStampType"/>
|
||||
<!-- Start CertificateValues -->
|
||||
<xsd:element name="CertificateValues" type="CertificateValuesType"/>
|
||||
<xsd:complexType name="CertificateValuesType">
|
||||
<xsd:choice minOccurs="0" maxOccurs="unbounded">
|
||||
<xsd:element name="EncapsulatedX509Certificate" type="EncapsulatedPKIDataType"/>
|
||||
<xsd:element name="OtherCertificate" type="AnyType"/>
|
||||
</xsd:choice>
|
||||
<xsd:attribute name="Id" type="xsd:ID" use="optional"/>
|
||||
</xsd:complexType>
|
||||
<!-- End CertificateValues -->
|
||||
<!-- Start RevocationValues-->
|
||||
<xsd:element name="RevocationValues" type="RevocationValuesType"/>
|
||||
<xsd:complexType name="RevocationValuesType">
|
||||
<xsd:sequence>
|
||||
<xsd:element name="CRLValues" type="CRLValuesType" minOccurs="0"/>
|
||||
<xsd:element name="OCSPValues" type="OCSPValuesType" minOccurs="0"/>
|
||||
<xsd:element name="OtherValues" type="OtherCertStatusValuesType" minOccurs="0"/>
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="Id" type="xsd:ID" use="optional"/>
|
||||
</xsd:complexType>
|
||||
<xsd:complexType name="CRLValuesType">
|
||||
<xsd:sequence>
|
||||
<xsd:element name="EncapsulatedCRLValue" type="EncapsulatedPKIDataType" maxOccurs="unbounded"/>
|
||||
</xsd:sequence>
|
||||
</xsd:complexType>
|
||||
<xsd:complexType name="OCSPValuesType">
|
||||
<xsd:sequence>
|
||||
<xsd:element name="EncapsulatedOCSPValue" type="EncapsulatedPKIDataType" maxOccurs="unbounded"/>
|
||||
</xsd:sequence>
|
||||
</xsd:complexType>
|
||||
<xsd:complexType name="OtherCertStatusValuesType">
|
||||
<xsd:sequence>
|
||||
<xsd:element name="OtherValue" type="AnyType" maxOccurs="unbounded"/>
|
||||
</xsd:sequence>
|
||||
</xsd:complexType>
|
||||
<!-- End RevocationValues-->
|
||||
<xsd:element name="AttrAuthoritiesCertValues" type="CertificateValuesType"/>
|
||||
<xsd:element name="AttributeRevocationValues" type="RevocationValuesType"/>
|
||||
<xsd:element name="ArchiveTimeStamp" type="XAdESTimeStampType"/>
|
||||
</xsd:schema>
|
||||
|
|
@ -0,0 +1,46 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!--
|
||||
~ Licensed to the Koordinierungsstelle für IT-Standards (KoSIT) under
|
||||
~ one or more contributor license agreements. See the NOTICE file
|
||||
~ distributed with this work for additional information
|
||||
~ regarding copyright ownership. KoSIT licenses this file
|
||||
~ to you under the Apache License, Version 2.0 (the
|
||||
~ "License"); you may not use this file except in compliance
|
||||
~ with the License. You may obtain a copy of the License at
|
||||
~
|
||||
~ http://www.apache.org/licenses/LICENSE-2.0
|
||||
~
|
||||
~ Unless required by applicable law or agreed to in writing,
|
||||
~ software distributed under the License is distributed on an
|
||||
~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||
~ KIND, either express or implied. See the License for the
|
||||
~ specific language governing permissions and limitations
|
||||
~ under the License.
|
||||
-->
|
||||
|
||||
<!--
|
||||
Library: OASIS Universal Business Language (UBL) 2.1 OS
|
||||
http://docs.oasis-open.org/ubl/os-UBL-2.1/
|
||||
Release Date: 04 November 2013
|
||||
Module: UBL-XAdESv141-2.1.xsd
|
||||
Generated on: 2011-02-21 17:20(UTC)
|
||||
|
||||
This is a copy of http://uri.etsi.org/01903/v1.4.1/XAdESv141.xsd modified
|
||||
only to change the importing URI for the XAdES v1.3.2 schema.
|
||||
-->
|
||||
<xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xades="http://uri.etsi.org/01903/v1.3.2#"
|
||||
targetNamespace="http://uri.etsi.org/01903/v1.4.1#" xmlns="http://uri.etsi.org/01903/v1.4.1#"
|
||||
elementFormDefault="qualified">
|
||||
<xsd:import namespace="http://uri.etsi.org/01903/v1.3.2#" schemaLocation="UBL-XAdESv132-2.1.xsd"/>
|
||||
<!-- Start CertificateValues -->
|
||||
<xsd:element name="TimeStampValidationData" type="ValidationDataType"/>
|
||||
<xsd:complexType name="ValidationDataType">
|
||||
<xsd:sequence>
|
||||
<xsd:element ref="xades:CertificateValues" minOccurs="0"/>
|
||||
<xsd:element ref="xades:RevocationValues" minOccurs="0"/>
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="Id" type="xsd:ID" use="optional"/>
|
||||
<xsd:attribute name="UR" type="xsd:anyURI" use="optional"/>
|
||||
</xsd:complexType>
|
||||
<xsd:element name="ArchiveTimeStampV2" type="xades:XAdESTimeStampType"/>
|
||||
</xsd:schema>
|
||||
|
|
@ -0,0 +1,332 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<!--
|
||||
~ Licensed to the Koordinierungsstelle für IT-Standards (KoSIT) under
|
||||
~ one or more contributor license agreements. See the NOTICE file
|
||||
~ distributed with this work for additional information
|
||||
~ regarding copyright ownership. KoSIT licenses this file
|
||||
~ to you under the Apache License, Version 2.0 (the
|
||||
~ "License"); you may not use this file except in compliance
|
||||
~ with the License. You may obtain a copy of the License at
|
||||
~
|
||||
~ http://www.apache.org/licenses/LICENSE-2.0
|
||||
~
|
||||
~ Unless required by applicable law or agreed to in writing,
|
||||
~ software distributed under the License is distributed on an
|
||||
~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||
~ KIND, either express or implied. See the License for the
|
||||
~ specific language governing permissions and limitations
|
||||
~ under the License.
|
||||
-->
|
||||
|
||||
<!--
|
||||
Library: OASIS Universal Business Language (UBL) 2.1 OS
|
||||
http://docs.oasis-open.org/ubl/os-UBL-2.1/
|
||||
Release Date: 04 November 2013
|
||||
Module: UBL-xmldsig-core-schema-2.1.xsd
|
||||
Generated on: 2010-08-13 19:10(UTC)
|
||||
|
||||
This is a copy of http://www.w3.org/TR/xmldsig-core/xmldsig-core-schema.xsd
|
||||
modified only to remove these PUBLIC and SYSTEM identifiers from the DOCTYPE:
|
||||
|
||||
PUBLIC "-//W3C//DTD XMLSchema 200102//EN"
|
||||
"http://www.w3.org/2001/XMLSchema.dtd"
|
||||
-->
|
||||
<!DOCTYPE schema
|
||||
[
|
||||
<!ATTLIST schema
|
||||
xmlns:ds CDATA #FIXED "http://www.w3.org/2000/09/xmldsig#">
|
||||
<!ENTITY dsig 'http://www.w3.org/2000/09/xmldsig#'>
|
||||
<!ENTITY % p ''>
|
||||
<!ENTITY % s ''>
|
||||
]>
|
||||
|
||||
<schema xmlns:ds="http://www.w3.org/2000/09/xmldsig#"
|
||||
xmlns="http://www.w3.org/2001/XMLSchema"
|
||||
targetNamespace="http://www.w3.org/2000/09/xmldsig#"
|
||||
version="0.1" elementFormDefault="qualified">
|
||||
|
||||
<!-- Basic Types Defined for Signatures -->
|
||||
|
||||
<simpleType name="CryptoBinary">
|
||||
<restriction base="base64Binary">
|
||||
</restriction>
|
||||
</simpleType>
|
||||
|
||||
<!-- Start Signature -->
|
||||
|
||||
<element name="Signature" type="ds:SignatureType"/>
|
||||
<complexType name="SignatureType">
|
||||
<sequence>
|
||||
<element ref="ds:SignedInfo"/>
|
||||
<element ref="ds:SignatureValue"/>
|
||||
<element ref="ds:KeyInfo" minOccurs="0"/>
|
||||
<element ref="ds:Object" minOccurs="0" maxOccurs="unbounded"/>
|
||||
</sequence>
|
||||
<attribute name="Id" type="ID" use="optional"/>
|
||||
</complexType>
|
||||
|
||||
<element name="SignatureValue" type="ds:SignatureValueType"/>
|
||||
<complexType name="SignatureValueType">
|
||||
<simpleContent>
|
||||
<extension base="base64Binary">
|
||||
<attribute name="Id" type="ID" use="optional"/>
|
||||
</extension>
|
||||
</simpleContent>
|
||||
</complexType>
|
||||
|
||||
<!-- Start SignedInfo -->
|
||||
|
||||
<element name="SignedInfo" type="ds:SignedInfoType"/>
|
||||
<complexType name="SignedInfoType">
|
||||
<sequence>
|
||||
<element ref="ds:CanonicalizationMethod"/>
|
||||
<element ref="ds:SignatureMethod"/>
|
||||
<element ref="ds:Reference" maxOccurs="unbounded"/>
|
||||
</sequence>
|
||||
<attribute name="Id" type="ID" use="optional"/>
|
||||
</complexType>
|
||||
|
||||
<element name="CanonicalizationMethod" type="ds:CanonicalizationMethodType"/>
|
||||
<complexType name="CanonicalizationMethodType" mixed="true">
|
||||
<sequence>
|
||||
<any namespace="##any" minOccurs="0" maxOccurs="unbounded"/>
|
||||
<!-- (0,unbounded) elements from (1,1) namespace -->
|
||||
</sequence>
|
||||
<attribute name="Algorithm" type="anyURI" use="required"/>
|
||||
</complexType>
|
||||
|
||||
<element name="SignatureMethod" type="ds:SignatureMethodType"/>
|
||||
<complexType name="SignatureMethodType" mixed="true">
|
||||
<sequence>
|
||||
<element name="HMACOutputLength" minOccurs="0" type="ds:HMACOutputLengthType"/>
|
||||
<any namespace="##other" minOccurs="0" maxOccurs="unbounded"/>
|
||||
<!-- (0,unbounded) elements from (1,1) external namespace -->
|
||||
</sequence>
|
||||
<attribute name="Algorithm" type="anyURI" use="required"/>
|
||||
</complexType>
|
||||
|
||||
<!-- Start Reference -->
|
||||
|
||||
<element name="Reference" type="ds:ReferenceType"/>
|
||||
<complexType name="ReferenceType">
|
||||
<sequence>
|
||||
<element ref="ds:Transforms" minOccurs="0"/>
|
||||
<element ref="ds:DigestMethod"/>
|
||||
<element ref="ds:DigestValue"/>
|
||||
</sequence>
|
||||
<attribute name="Id" type="ID" use="optional"/>
|
||||
<attribute name="URI" type="anyURI" use="optional"/>
|
||||
<attribute name="Type" type="anyURI" use="optional"/>
|
||||
</complexType>
|
||||
|
||||
<element name="Transforms" type="ds:TransformsType"/>
|
||||
<complexType name="TransformsType">
|
||||
<sequence>
|
||||
<element ref="ds:Transform" maxOccurs="unbounded"/>
|
||||
</sequence>
|
||||
</complexType>
|
||||
|
||||
<element name="Transform" type="ds:TransformType"/>
|
||||
<complexType name="TransformType" mixed="true">
|
||||
<choice minOccurs="0" maxOccurs="unbounded">
|
||||
<any namespace="##other" processContents="lax"/>
|
||||
<!-- (1,1) elements from (0,unbounded) namespaces -->
|
||||
<element name="XPath" type="string"/>
|
||||
</choice>
|
||||
<attribute name="Algorithm" type="anyURI" use="required"/>
|
||||
</complexType>
|
||||
|
||||
<!-- End Reference -->
|
||||
|
||||
<element name="DigestMethod" type="ds:DigestMethodType"/>
|
||||
<complexType name="DigestMethodType" mixed="true">
|
||||
<sequence>
|
||||
<any namespace="##other" processContents="lax" minOccurs="0" maxOccurs="unbounded"/>
|
||||
</sequence>
|
||||
<attribute name="Algorithm" type="anyURI" use="required"/>
|
||||
</complexType>
|
||||
|
||||
<element name="DigestValue" type="ds:DigestValueType"/>
|
||||
<simpleType name="DigestValueType">
|
||||
<restriction base="base64Binary"/>
|
||||
</simpleType>
|
||||
|
||||
<!-- End SignedInfo -->
|
||||
|
||||
<!-- Start KeyInfo -->
|
||||
|
||||
<element name="KeyInfo" type="ds:KeyInfoType"/>
|
||||
<complexType name="KeyInfoType" mixed="true">
|
||||
<choice maxOccurs="unbounded">
|
||||
<element ref="ds:KeyName"/>
|
||||
<element ref="ds:KeyValue"/>
|
||||
<element ref="ds:RetrievalMethod"/>
|
||||
<element ref="ds:X509Data"/>
|
||||
<element ref="ds:PGPData"/>
|
||||
<element ref="ds:SPKIData"/>
|
||||
<element ref="ds:MgmtData"/>
|
||||
<any processContents="lax" namespace="##other"/>
|
||||
<!-- (1,1) elements from (0,unbounded) namespaces -->
|
||||
</choice>
|
||||
<attribute name="Id" type="ID" use="optional"/>
|
||||
</complexType>
|
||||
|
||||
<element name="KeyName" type="string"/>
|
||||
<element name="MgmtData" type="string"/>
|
||||
|
||||
<element name="KeyValue" type="ds:KeyValueType"/>
|
||||
<complexType name="KeyValueType" mixed="true">
|
||||
<choice>
|
||||
<element ref="ds:DSAKeyValue"/>
|
||||
<element ref="ds:RSAKeyValue"/>
|
||||
<any namespace="##other" processContents="lax"/>
|
||||
</choice>
|
||||
</complexType>
|
||||
|
||||
<element name="RetrievalMethod" type="ds:RetrievalMethodType"/>
|
||||
<complexType name="RetrievalMethodType">
|
||||
<sequence>
|
||||
<element ref="ds:Transforms" minOccurs="0"/>
|
||||
</sequence>
|
||||
<attribute name="URI" type="anyURI"/>
|
||||
<attribute name="Type" type="anyURI" use="optional"/>
|
||||
</complexType>
|
||||
|
||||
<!-- Start X509Data -->
|
||||
|
||||
<element name="X509Data" type="ds:X509DataType"/>
|
||||
<complexType name="X509DataType">
|
||||
<sequence maxOccurs="unbounded">
|
||||
<choice>
|
||||
<element name="X509IssuerSerial" type="ds:X509IssuerSerialType"/>
|
||||
<element name="X509SKI" type="base64Binary"/>
|
||||
<element name="X509SubjectName" type="string"/>
|
||||
<element name="X509Certificate" type="base64Binary"/>
|
||||
<element name="X509CRL" type="base64Binary"/>
|
||||
<any namespace="##other" processContents="lax"/>
|
||||
</choice>
|
||||
</sequence>
|
||||
</complexType>
|
||||
|
||||
<complexType name="X509IssuerSerialType">
|
||||
<sequence>
|
||||
<element name="X509IssuerName" type="string"/>
|
||||
<element name="X509SerialNumber" type="integer"/>
|
||||
</sequence>
|
||||
</complexType>
|
||||
|
||||
<!-- End X509Data -->
|
||||
|
||||
<!-- Begin PGPData -->
|
||||
|
||||
<element name="PGPData" type="ds:PGPDataType"/>
|
||||
<complexType name="PGPDataType">
|
||||
<choice>
|
||||
<sequence>
|
||||
<element name="PGPKeyID" type="base64Binary"/>
|
||||
<element name="PGPKeyPacket" type="base64Binary" minOccurs="0"/>
|
||||
<any namespace="##other" processContents="lax" minOccurs="0"
|
||||
maxOccurs="unbounded"/>
|
||||
</sequence>
|
||||
<sequence>
|
||||
<element name="PGPKeyPacket" type="base64Binary"/>
|
||||
<any namespace="##other" processContents="lax" minOccurs="0"
|
||||
maxOccurs="unbounded"/>
|
||||
</sequence>
|
||||
</choice>
|
||||
</complexType>
|
||||
|
||||
<!-- End PGPData -->
|
||||
|
||||
<!-- Begin SPKIData -->
|
||||
|
||||
<element name="SPKIData" type="ds:SPKIDataType"/>
|
||||
<complexType name="SPKIDataType">
|
||||
<sequence maxOccurs="unbounded">
|
||||
<element name="SPKISexp" type="base64Binary"/>
|
||||
<any namespace="##other" processContents="lax" minOccurs="0"/>
|
||||
</sequence>
|
||||
</complexType>
|
||||
|
||||
<!-- End SPKIData -->
|
||||
|
||||
<!-- End KeyInfo -->
|
||||
|
||||
<!-- Start Object (Manifest, SignatureProperty) -->
|
||||
|
||||
<element name="Object" type="ds:ObjectType"/>
|
||||
<complexType name="ObjectType" mixed="true">
|
||||
<sequence minOccurs="0" maxOccurs="unbounded">
|
||||
<any namespace="##any" processContents="lax"/>
|
||||
</sequence>
|
||||
<attribute name="Id" type="ID" use="optional"/>
|
||||
<attribute name="MimeType" type="string" use="optional"/> <!-- add a grep facet -->
|
||||
<attribute name="Encoding" type="anyURI" use="optional"/>
|
||||
</complexType>
|
||||
|
||||
<element name="Manifest" type="ds:ManifestType"/>
|
||||
<complexType name="ManifestType">
|
||||
<sequence>
|
||||
<element ref="ds:Reference" maxOccurs="unbounded"/>
|
||||
</sequence>
|
||||
<attribute name="Id" type="ID" use="optional"/>
|
||||
</complexType>
|
||||
|
||||
<element name="SignatureProperties" type="ds:SignaturePropertiesType"/>
|
||||
<complexType name="SignaturePropertiesType">
|
||||
<sequence>
|
||||
<element ref="ds:SignatureProperty" maxOccurs="unbounded"/>
|
||||
</sequence>
|
||||
<attribute name="Id" type="ID" use="optional"/>
|
||||
</complexType>
|
||||
|
||||
<element name="SignatureProperty" type="ds:SignaturePropertyType"/>
|
||||
<complexType name="SignaturePropertyType" mixed="true">
|
||||
<choice maxOccurs="unbounded">
|
||||
<any namespace="##other" processContents="lax"/>
|
||||
<!-- (1,1) elements from (1,unbounded) namespaces -->
|
||||
</choice>
|
||||
<attribute name="Target" type="anyURI" use="required"/>
|
||||
<attribute name="Id" type="ID" use="optional"/>
|
||||
</complexType>
|
||||
|
||||
<!-- End Object (Manifest, SignatureProperty) -->
|
||||
|
||||
<!-- Start Algorithm Parameters -->
|
||||
|
||||
<simpleType name="HMACOutputLengthType">
|
||||
<restriction base="integer"/>
|
||||
</simpleType>
|
||||
|
||||
<!-- Start KeyValue Element-types -->
|
||||
|
||||
<element name="DSAKeyValue" type="ds:DSAKeyValueType"/>
|
||||
<complexType name="DSAKeyValueType">
|
||||
<sequence>
|
||||
<sequence minOccurs="0">
|
||||
<element name="P" type="ds:CryptoBinary"/>
|
||||
<element name="Q" type="ds:CryptoBinary"/>
|
||||
</sequence>
|
||||
<element name="G" type="ds:CryptoBinary" minOccurs="0"/>
|
||||
<element name="Y" type="ds:CryptoBinary"/>
|
||||
<element name="J" type="ds:CryptoBinary" minOccurs="0"/>
|
||||
<sequence minOccurs="0">
|
||||
<element name="Seed" type="ds:CryptoBinary"/>
|
||||
<element name="PgenCounter" type="ds:CryptoBinary"/>
|
||||
</sequence>
|
||||
</sequence>
|
||||
</complexType>
|
||||
|
||||
<element name="RSAKeyValue" type="ds:RSAKeyValueType"/>
|
||||
<complexType name="RSAKeyValueType">
|
||||
<sequence>
|
||||
<element name="Modulus" type="ds:CryptoBinary"/>
|
||||
<element name="Exponent" type="ds:CryptoBinary"/>
|
||||
</sequence>
|
||||
</complexType>
|
||||
|
||||
<!-- End KeyValue Element-types -->
|
||||
|
||||
<!-- End Signature -->
|
||||
|
||||
</schema>
|
||||
|
|
@ -0,0 +1,153 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!--
|
||||
~ Licensed to the Koordinierungsstelle für IT-Standards (KoSIT) under
|
||||
~ one or more contributor license agreements. See the NOTICE file
|
||||
~ distributed with this work for additional information
|
||||
~ regarding copyright ownership. KoSIT licenses this file
|
||||
~ to you under the Apache License, Version 2.0 (the
|
||||
~ "License"); you may not use this file except in compliance
|
||||
~ with the License. You may obtain a copy of the License at
|
||||
~
|
||||
~ http://www.apache.org/licenses/LICENSE-2.0
|
||||
~
|
||||
~ Unless required by applicable law or agreed to in writing,
|
||||
~ software distributed under the License is distributed on an
|
||||
~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||
~ KIND, either express or implied. See the License for the
|
||||
~ specific language governing permissions and limitations
|
||||
~ under the License.
|
||||
-->
|
||||
<xsd:schema xmlns:cac="urn:oasis:names:specification:ubl:schema:xsd:CommonAggregateComponents-2"
|
||||
xmlns:cbc="urn:oasis:names:specification:ubl:schema:xsd:CommonBasicComponents-2"
|
||||
xmlns:ext="urn:oasis:names:specification:ubl:schema:xsd:CommonExtensionComponents-2"
|
||||
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
|
||||
xmlns="urn:oasis:names:specification:ubl:schema:xsd:CreditNote-2"
|
||||
targetNamespace="urn:oasis:names:specification:ubl:schema:xsd:CreditNote-2"
|
||||
elementFormDefault="qualified"
|
||||
attributeFormDefault="unqualified"
|
||||
version="2.1">
|
||||
<xsd:import namespace="urn:oasis:names:specification:ubl:schema:xsd:CommonAggregateComponents-2"
|
||||
schemaLocation="../common/UBL-CommonAggregateComponents-2.1.xsd"/>
|
||||
<xsd:import namespace="urn:oasis:names:specification:ubl:schema:xsd:CommonBasicComponents-2"
|
||||
schemaLocation="../common/UBL-CommonBasicComponents-2.1.xsd"/>
|
||||
<xsd:import namespace="urn:oasis:names:specification:ubl:schema:xsd:CommonExtensionComponents-2"
|
||||
schemaLocation="../common/UBL-CommonExtensionComponents-2.1.xsd"/>
|
||||
<xsd:element name="CreditNote" type="CreditNoteType"/>
|
||||
<xsd:complexType name="CreditNoteType">
|
||||
<xsd:sequence>
|
||||
<xsd:element ref="ext:UBLExtensions" minOccurs="0" maxOccurs="1"/>
|
||||
<xsd:element ref="cbc:UBLVersionID" minOccurs="0" maxOccurs="1"/>
|
||||
<xsd:element ref="cbc:CustomizationID" minOccurs="0" maxOccurs="1"/>
|
||||
<xsd:element ref="cbc:ProfileID" minOccurs="0" maxOccurs="1"/>
|
||||
<xsd:element ref="cbc:ProfileExecutionID" minOccurs="0" maxOccurs="1"/>
|
||||
<xsd:element ref="cbc:ID" minOccurs="1" maxOccurs="1"/>
|
||||
<xsd:element ref="cbc:CopyIndicator" minOccurs="0" maxOccurs="1"/>
|
||||
<xsd:element ref="cbc:UUID" minOccurs="0" maxOccurs="1"/>
|
||||
<xsd:element ref="cbc:IssueDate" minOccurs="1" maxOccurs="1"/>
|
||||
<xsd:element ref="cbc:IssueTime" minOccurs="0" maxOccurs="1"/>
|
||||
<xsd:element ref="cbc:TaxPointDate" minOccurs="0" maxOccurs="1"/>
|
||||
<xsd:element ref="cbc:CreditNoteTypeCode" minOccurs="0" maxOccurs="1"/>
|
||||
<xsd:element ref="cbc:Note" minOccurs="0" maxOccurs="unbounded"/>
|
||||
<xsd:element ref="cbc:DocumentCurrencyCode" minOccurs="0" maxOccurs="1"/>
|
||||
<xsd:element ref="cbc:TaxCurrencyCode" minOccurs="0" maxOccurs="1"/>
|
||||
<xsd:element ref="cbc:PricingCurrencyCode" minOccurs="0" maxOccurs="1"/>
|
||||
<xsd:element ref="cbc:PaymentCurrencyCode" minOccurs="0" maxOccurs="1"/>
|
||||
<xsd:element ref="cbc:PaymentAlternativeCurrencyCode"
|
||||
minOccurs="0"
|
||||
maxOccurs="1"/>
|
||||
<xsd:element ref="cbc:AccountingCostCode" minOccurs="0" maxOccurs="1"/>
|
||||
<xsd:element ref="cbc:AccountingCost" minOccurs="0" maxOccurs="1"/>
|
||||
<xsd:element ref="cbc:LineCountNumeric" minOccurs="0" maxOccurs="1"/>
|
||||
<xsd:element ref="cbc:BuyerReference" minOccurs="0" maxOccurs="1"/>
|
||||
<xsd:element ref="cac:InvoicePeriod" minOccurs="0" maxOccurs="unbounded"/>
|
||||
<xsd:element ref="cac:DiscrepancyResponse" minOccurs="0" maxOccurs="unbounded"/>
|
||||
<xsd:element ref="cac:OrderReference" minOccurs="0" maxOccurs="1"/>
|
||||
<xsd:element ref="cac:BillingReference" minOccurs="0" maxOccurs="unbounded"/>
|
||||
<xsd:element ref="cac:DespatchDocumentReference"
|
||||
minOccurs="0"
|
||||
maxOccurs="unbounded"/>
|
||||
<xsd:element ref="cac:ReceiptDocumentReference"
|
||||
minOccurs="0"
|
||||
maxOccurs="unbounded"/>
|
||||
<xsd:element ref="cac:ContractDocumentReference"
|
||||
minOccurs="0"
|
||||
maxOccurs="unbounded"/>
|
||||
<xsd:element ref="cac:AdditionalDocumentReference"
|
||||
minOccurs="0"
|
||||
maxOccurs="unbounded"/>
|
||||
<xsd:element ref="cac:StatementDocumentReference"
|
||||
minOccurs="0"
|
||||
maxOccurs="unbounded"/>
|
||||
<xsd:element ref="cac:OriginatorDocumentReference"
|
||||
minOccurs="0"
|
||||
maxOccurs="unbounded"/>
|
||||
<xsd:element ref="cac:Signature" minOccurs="0" maxOccurs="unbounded"/>
|
||||
<xsd:element ref="cac:AccountingSupplierParty" minOccurs="1" maxOccurs="1"/>
|
||||
<xsd:element ref="cac:AccountingCustomerParty" minOccurs="1" maxOccurs="1"/>
|
||||
<xsd:element ref="cac:PayeeParty" minOccurs="0" maxOccurs="1"/>
|
||||
<xsd:element ref="cac:BuyerCustomerParty" minOccurs="0" maxOccurs="1"/>
|
||||
<xsd:element ref="cac:SellerSupplierParty" minOccurs="0" maxOccurs="1"/>
|
||||
<xsd:element ref="cac:TaxRepresentativeParty" minOccurs="0" maxOccurs="1"/>
|
||||
<xsd:element ref="cac:Delivery" minOccurs="0" maxOccurs="unbounded"/>
|
||||
<xsd:element ref="cac:DeliveryTerms" minOccurs="0" maxOccurs="unbounded"/>
|
||||
<xsd:element ref="cac:PaymentMeans" minOccurs="0" maxOccurs="unbounded"/>
|
||||
<xsd:element ref="cac:PaymentTerms" minOccurs="0" maxOccurs="unbounded"/>
|
||||
<xsd:element ref="cac:TaxExchangeRate" minOccurs="0" maxOccurs="1"/>
|
||||
<xsd:element ref="cac:PricingExchangeRate" minOccurs="0" maxOccurs="1"/>
|
||||
<xsd:element ref="cac:PaymentExchangeRate" minOccurs="0" maxOccurs="1"/>
|
||||
<xsd:element ref="cac:PaymentAlternativeExchangeRate"
|
||||
minOccurs="0"
|
||||
maxOccurs="1"/>
|
||||
<xsd:element ref="cac:AllowanceCharge" minOccurs="0" maxOccurs="unbounded"/>
|
||||
<xsd:element ref="cac:TaxTotal" minOccurs="0" maxOccurs="unbounded"/>
|
||||
<xsd:element ref="cac:LegalMonetaryTotal" minOccurs="1" maxOccurs="1"/>
|
||||
<xsd:element ref="cac:CreditNoteLine" minOccurs="1" maxOccurs="unbounded"/>
|
||||
</xsd:sequence>
|
||||
</xsd:complexType>
|
||||
</xsd:schema>
|
||||
<!-- ===== Copyright Notice ===== --><!--
|
||||
OASIS takes no position regarding the validity or scope of any
|
||||
intellectual property or other rights that might be claimed to pertain
|
||||
to the implementation or use of the technology described in this
|
||||
document or the extent to which any license under such rights
|
||||
might or might not be available; neither does it represent that it has
|
||||
made any effort to identify any such rights. Information on OASIS's
|
||||
procedures with respect to rights in OASIS specifications can be
|
||||
found at the OASIS website. Copies of claims of rights made
|
||||
available for publication and any assurances of licenses to be made
|
||||
available, or the result of an attempt made to obtain a general
|
||||
license or permission for the use of such proprietary rights by
|
||||
implementors or users of this specification, can be obtained from
|
||||
the OASIS Executive Director.
|
||||
|
||||
OASIS invites any interested party to bring to its attention any
|
||||
copyrights, patents or patent applications, or other proprietary
|
||||
rights which may cover technology that may be required to
|
||||
implement this specification. Please address the information to the
|
||||
OASIS Executive Director.
|
||||
|
||||
This document and translations of it may be copied and furnished to
|
||||
others, and derivative works that comment on or otherwise explain
|
||||
it or assist in its implementation may be prepared, copied,
|
||||
published and distributed, in whole or in part, without restriction of
|
||||
any kind, provided that the above copyright notice and this
|
||||
paragraph are included on all such copies and derivative works.
|
||||
However, this document itself may not be modified in any way,
|
||||
such as by removing the copyright notice or references to OASIS,
|
||||
except as needed for the purpose of developing OASIS
|
||||
specifications, in which case the procedures for copyrights defined
|
||||
in the OASIS Intellectual Property Rights document must be
|
||||
followed, or as required to translate it into languages other than
|
||||
English.
|
||||
|
||||
The limited permissions granted above are perpetual and will not be
|
||||
revoked by OASIS or its successors or assigns.
|
||||
|
||||
This document and the information contained herein is provided on
|
||||
an "AS IS" basis and OASIS DISCLAIMS ALL WARRANTIES,
|
||||
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY
|
||||
WARRANTY THAT THE USE OF THE INFORMATION HEREIN
|
||||
WILL NOT INFRINGE ANY RIGHTS OR ANY IMPLIED
|
||||
WARRANTIES OF MERCHANTABILITY OR FITNESS FOR A
|
||||
PARTICULAR PURPOSE.
|
||||
-->
|
||||
|
|
@ -0,0 +1,156 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!--
|
||||
~ Licensed to the Koordinierungsstelle für IT-Standards (KoSIT) under
|
||||
~ one or more contributor license agreements. See the NOTICE file
|
||||
~ distributed with this work for additional information
|
||||
~ regarding copyright ownership. KoSIT licenses this file
|
||||
~ to you under the Apache License, Version 2.0 (the
|
||||
~ "License"); you may not use this file except in compliance
|
||||
~ with the License. You may obtain a copy of the License at
|
||||
~
|
||||
~ http://www.apache.org/licenses/LICENSE-2.0
|
||||
~
|
||||
~ Unless required by applicable law or agreed to in writing,
|
||||
~ software distributed under the License is distributed on an
|
||||
~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||
~ KIND, either express or implied. See the License for the
|
||||
~ specific language governing permissions and limitations
|
||||
~ under the License.
|
||||
-->
|
||||
<xsd:schema xmlns:cac="urn:oasis:names:specification:ubl:schema:xsd:CommonAggregateComponents-2"
|
||||
xmlns:cbc="urn:oasis:names:specification:ubl:schema:xsd:CommonBasicComponents-2"
|
||||
xmlns:ext="urn:oasis:names:specification:ubl:schema:xsd:CommonExtensionComponents-2"
|
||||
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
|
||||
xmlns="urn:oasis:names:specification:ubl:schema:xsd:Invoice-2"
|
||||
targetNamespace="urn:oasis:names:specification:ubl:schema:xsd:Invoice-2"
|
||||
elementFormDefault="qualified"
|
||||
attributeFormDefault="unqualified"
|
||||
version="2.1">
|
||||
<xsd:import namespace="urn:oasis:names:specification:ubl:schema:xsd:CommonAggregateComponents-2"
|
||||
schemaLocation="../common/UBL-CommonAggregateComponents-2.1.xsd"/>
|
||||
<xsd:import namespace="urn:oasis:names:specification:ubl:schema:xsd:CommonBasicComponents-2"
|
||||
schemaLocation="../common/UBL-CommonBasicComponents-2.1.xsd"/>
|
||||
<xsd:import namespace="urn:oasis:names:specification:ubl:schema:xsd:CommonExtensionComponents-2"
|
||||
schemaLocation="../common/UBL-CommonExtensionComponents-2.1.xsd"/>
|
||||
<xsd:element name="Invoice" type="InvoiceType"/>
|
||||
<xsd:complexType name="InvoiceType">
|
||||
<xsd:sequence>
|
||||
<xsd:element ref="ext:UBLExtensions" minOccurs="0" maxOccurs="1"/>
|
||||
<xsd:element ref="cbc:UBLVersionID" minOccurs="0" maxOccurs="1"/>
|
||||
<xsd:element ref="cbc:CustomizationID" minOccurs="0" maxOccurs="1"/>
|
||||
<xsd:element ref="cbc:ProfileID" minOccurs="0" maxOccurs="1"/>
|
||||
<xsd:element ref="cbc:ProfileExecutionID" minOccurs="0" maxOccurs="1"/>
|
||||
<xsd:element ref="cbc:ID" minOccurs="1" maxOccurs="1"/>
|
||||
<xsd:element ref="cbc:CopyIndicator" minOccurs="0" maxOccurs="1"/>
|
||||
<xsd:element ref="cbc:UUID" minOccurs="0" maxOccurs="1"/>
|
||||
<xsd:element ref="cbc:IssueDate" minOccurs="1" maxOccurs="1"/>
|
||||
<xsd:element ref="cbc:IssueTime" minOccurs="0" maxOccurs="1"/>
|
||||
<xsd:element ref="cbc:DueDate" minOccurs="0" maxOccurs="1"/>
|
||||
<xsd:element ref="cbc:InvoiceTypeCode" minOccurs="0" maxOccurs="1"/>
|
||||
<xsd:element ref="cbc:Note" minOccurs="0" maxOccurs="unbounded"/>
|
||||
<xsd:element ref="cbc:TaxPointDate" minOccurs="0" maxOccurs="1"/>
|
||||
<xsd:element ref="cbc:DocumentCurrencyCode" minOccurs="0" maxOccurs="1"/>
|
||||
<xsd:element ref="cbc:TaxCurrencyCode" minOccurs="0" maxOccurs="1"/>
|
||||
<xsd:element ref="cbc:PricingCurrencyCode" minOccurs="0" maxOccurs="1"/>
|
||||
<xsd:element ref="cbc:PaymentCurrencyCode" minOccurs="0" maxOccurs="1"/>
|
||||
<xsd:element ref="cbc:PaymentAlternativeCurrencyCode"
|
||||
minOccurs="0"
|
||||
maxOccurs="1"/>
|
||||
<xsd:element ref="cbc:AccountingCostCode" minOccurs="0" maxOccurs="1"/>
|
||||
<xsd:element ref="cbc:AccountingCost" minOccurs="0" maxOccurs="1"/>
|
||||
<xsd:element ref="cbc:LineCountNumeric" minOccurs="0" maxOccurs="1"/>
|
||||
<xsd:element ref="cbc:BuyerReference" minOccurs="0" maxOccurs="1"/>
|
||||
<xsd:element ref="cac:InvoicePeriod" minOccurs="0" maxOccurs="unbounded"/>
|
||||
<xsd:element ref="cac:OrderReference" minOccurs="0" maxOccurs="1"/>
|
||||
<xsd:element ref="cac:BillingReference" minOccurs="0" maxOccurs="unbounded"/>
|
||||
<xsd:element ref="cac:DespatchDocumentReference"
|
||||
minOccurs="0"
|
||||
maxOccurs="unbounded"/>
|
||||
<xsd:element ref="cac:ReceiptDocumentReference"
|
||||
minOccurs="0"
|
||||
maxOccurs="unbounded"/>
|
||||
<xsd:element ref="cac:StatementDocumentReference"
|
||||
minOccurs="0"
|
||||
maxOccurs="unbounded"/>
|
||||
<xsd:element ref="cac:OriginatorDocumentReference"
|
||||
minOccurs="0"
|
||||
maxOccurs="unbounded"/>
|
||||
<xsd:element ref="cac:ContractDocumentReference"
|
||||
minOccurs="0"
|
||||
maxOccurs="unbounded"/>
|
||||
<xsd:element ref="cac:AdditionalDocumentReference"
|
||||
minOccurs="0"
|
||||
maxOccurs="unbounded"/>
|
||||
<xsd:element ref="cac:ProjectReference" minOccurs="0" maxOccurs="unbounded"/>
|
||||
<xsd:element ref="cac:Signature" minOccurs="0" maxOccurs="unbounded"/>
|
||||
<xsd:element ref="cac:AccountingSupplierParty" minOccurs="1" maxOccurs="1"/>
|
||||
<xsd:element ref="cac:AccountingCustomerParty" minOccurs="1" maxOccurs="1"/>
|
||||
<xsd:element ref="cac:PayeeParty" minOccurs="0" maxOccurs="1"/>
|
||||
<xsd:element ref="cac:BuyerCustomerParty" minOccurs="0" maxOccurs="1"/>
|
||||
<xsd:element ref="cac:SellerSupplierParty" minOccurs="0" maxOccurs="1"/>
|
||||
<xsd:element ref="cac:TaxRepresentativeParty" minOccurs="0" maxOccurs="1"/>
|
||||
<xsd:element ref="cac:Delivery" minOccurs="0" maxOccurs="unbounded"/>
|
||||
<xsd:element ref="cac:DeliveryTerms" minOccurs="0" maxOccurs="1"/>
|
||||
<xsd:element ref="cac:PaymentMeans" minOccurs="0" maxOccurs="unbounded"/>
|
||||
<xsd:element ref="cac:PaymentTerms" minOccurs="0" maxOccurs="unbounded"/>
|
||||
<xsd:element ref="cac:PrepaidPayment" minOccurs="0" maxOccurs="unbounded"/>
|
||||
<xsd:element ref="cac:AllowanceCharge" minOccurs="0" maxOccurs="unbounded"/>
|
||||
<xsd:element ref="cac:TaxExchangeRate" minOccurs="0" maxOccurs="1"/>
|
||||
<xsd:element ref="cac:PricingExchangeRate" minOccurs="0" maxOccurs="1"/>
|
||||
<xsd:element ref="cac:PaymentExchangeRate" minOccurs="0" maxOccurs="1"/>
|
||||
<xsd:element ref="cac:PaymentAlternativeExchangeRate"
|
||||
minOccurs="0"
|
||||
maxOccurs="1"/>
|
||||
<xsd:element ref="cac:TaxTotal" minOccurs="0" maxOccurs="unbounded"/>
|
||||
<xsd:element ref="cac:WithholdingTaxTotal" minOccurs="0" maxOccurs="unbounded"/>
|
||||
<xsd:element ref="cac:LegalMonetaryTotal" minOccurs="1" maxOccurs="1"/>
|
||||
<xsd:element ref="cac:InvoiceLine" minOccurs="1" maxOccurs="unbounded"/>
|
||||
</xsd:sequence>
|
||||
</xsd:complexType>
|
||||
</xsd:schema>
|
||||
<!-- ===== Copyright Notice ===== --><!--
|
||||
OASIS takes no position regarding the validity or scope of any
|
||||
intellectual property or other rights that might be claimed to pertain
|
||||
to the implementation or use of the technology described in this
|
||||
document or the extent to which any license under such rights
|
||||
might or might not be available; neither does it represent that it has
|
||||
made any effort to identify any such rights. Information on OASIS's
|
||||
procedures with respect to rights in OASIS specifications can be
|
||||
found at the OASIS website. Copies of claims of rights made
|
||||
available for publication and any assurances of licenses to be made
|
||||
available, or the result of an attempt made to obtain a general
|
||||
license or permission for the use of such proprietary rights by
|
||||
implementors or users of this specification, can be obtained from
|
||||
the OASIS Executive Director.
|
||||
|
||||
OASIS invites any interested party to bring to its attention any
|
||||
copyrights, patents or patent applications, or other proprietary
|
||||
rights which may cover technology that may be required to
|
||||
implement this specification. Please address the information to the
|
||||
OASIS Executive Director.
|
||||
|
||||
This document and translations of it may be copied and furnished to
|
||||
others, and derivative works that comment on or otherwise explain
|
||||
it or assist in its implementation may be prepared, copied,
|
||||
published and distributed, in whole or in part, without restriction of
|
||||
any kind, provided that the above copyright notice and this
|
||||
paragraph are included on all such copies and derivative works.
|
||||
However, this document itself may not be modified in any way,
|
||||
such as by removing the copyright notice or references to OASIS,
|
||||
except as needed for the purpose of developing OASIS
|
||||
specifications, in which case the procedures for copyrights defined
|
||||
in the OASIS Intellectual Property Rights document must be
|
||||
followed, or as required to translate it into languages other than
|
||||
English.
|
||||
|
||||
The limited permissions granted above are perpetual and will not be
|
||||
revoked by OASIS or its successors or assigns.
|
||||
|
||||
This document and the information contained herein is provided on
|
||||
an "AS IS" basis and OASIS DISCLAIMS ALL WARRANTIES,
|
||||
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY
|
||||
WARRANTY THAT THE USE OF THE INFORMATION HEREIN
|
||||
WILL NOT INFRINGE ANY RIGHTS OR ANY IMPLIED
|
||||
WARRANTIES OF MERCHANTABILITY OR FITNESS FOR A
|
||||
PARTICULAR PURPOSE.
|
||||
-->
|
||||
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
|
|
@ -0,0 +1,756 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!--
|
||||
~ Licensed to the Koordinierungsstelle für IT-Standards (KoSIT) under
|
||||
~ one or more contributor license agreements. See the NOTICE file
|
||||
~ distributed with this work for additional information
|
||||
~ regarding copyright ownership. KoSIT licenses this file
|
||||
~ to you under the Apache License, Version 2.0 (the
|
||||
~ "License"); you may not use this file except in compliance
|
||||
~ with the License. You may obtain a copy of the License at
|
||||
~
|
||||
~ http://www.apache.org/licenses/LICENSE-2.0
|
||||
~
|
||||
~ Unless required by applicable law or agreed to in writing,
|
||||
~ software distributed under the License is distributed on an
|
||||
~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||
~ KIND, either express or implied. See the License for the
|
||||
~ specific language governing permissions and limitations
|
||||
~ under the License.
|
||||
-->
|
||||
|
||||
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
|
||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||
xmlns:xs="http://www.w3.org/2001/XMLSchema"
|
||||
xmlns:rep="http://www.xoev.de/de/validator/varl/1 "
|
||||
xmlns:s="http://www.xoev.de/de/validator/framework/1/scenarios"
|
||||
xmlns:in="http://www.xoev.de/de/validator/framework/1/createreportinput"
|
||||
xmlns:svrl="http://purl.oclc.org/dsdl/svrl"
|
||||
xmlns:xd="http://www.oxygenxml.com/ns/doc/xsl"
|
||||
xmlns:html="http://www.w3.org/1999/xhtml"
|
||||
exclude-result-prefixes="xs"
|
||||
version="2.0">
|
||||
|
||||
<xsl:output method="xml" indent="yes"/>
|
||||
|
||||
<xsl:param name="input-document" required="yes"/>
|
||||
|
||||
<xsl:variable name="custom-levels" as="element(s:customLevel)*" select="//s:customLevel"/>
|
||||
|
||||
|
||||
<xsl:template match="in:createReportInput">
|
||||
|
||||
<xsl:variable name="validationStepResults" as="element(rep:validationStepResult)*">
|
||||
<xsl:apply-templates select="in:validationResultsWellformedness"/>
|
||||
<xsl:apply-templates select="in:validationResultsXmlSchema"/>
|
||||
<xsl:apply-templates select="in:validationResultsSchematron"/>
|
||||
</xsl:variable>
|
||||
|
||||
<xsl:variable name="report" as="document-node(element(rep:report))">
|
||||
<xsl:document>
|
||||
<rep:report>
|
||||
<xsl:attribute name="valid">
|
||||
<xsl:choose>
|
||||
<xsl:when test="s:noScenarioMatched">false</xsl:when>
|
||||
<xsl:when test="$validationStepResults[@valid = 'false']">false</xsl:when>
|
||||
<xsl:otherwise>true</xsl:otherwise>
|
||||
</xsl:choose>
|
||||
</xsl:attribute>
|
||||
<xsl:apply-templates select="in:engine" mode="copy-to-report-ns"/>
|
||||
<xsl:apply-templates select="in:timestamp" mode="copy-to-report-ns"/>
|
||||
<xsl:apply-templates select="in:documentIdentification" mode="copy-to-report-ns"/>
|
||||
|
||||
<xsl:choose>
|
||||
<xsl:when test="s:scenario">
|
||||
<rep:scenarioMatched>
|
||||
<xsl:sequence select="s:scenario"/>
|
||||
<xsl:call-template name="document-data"/>
|
||||
<rep:validationResult>
|
||||
<xsl:sequence select="$validationStepResults"/>
|
||||
</rep:validationResult>
|
||||
</rep:scenarioMatched>
|
||||
</xsl:when>
|
||||
<xsl:otherwise>
|
||||
<rep:noScenarioMatched>
|
||||
|
||||
</rep:noScenarioMatched>
|
||||
</xsl:otherwise>
|
||||
</xsl:choose>
|
||||
</rep:report>
|
||||
</xsl:document>
|
||||
</xsl:variable>
|
||||
|
||||
<rep:report varlVersion="1.0.0">
|
||||
<xsl:copy-of select="$report/rep:report/(node()|@*)"/>
|
||||
<xsl:apply-templates select="$report" mode="assessment"/>
|
||||
</rep:report>
|
||||
|
||||
</xsl:template>
|
||||
|
||||
<!-- Overwrite this template in customisation layer to generate a documentData element -->
|
||||
<xsl:template name="document-data"/>
|
||||
|
||||
|
||||
<!-- ************************************************************************************** -->
|
||||
<!-- * * -->
|
||||
<!-- * Syntax checks (well-formedness and XML Schema * -->
|
||||
<!-- * * -->
|
||||
<!-- ************************************************************************************** -->
|
||||
|
||||
<xsl:template match="in:validationResultsWellformedness|in:validationResultsXmlSchema">
|
||||
<xsl:variable name="id" as="xs:string"
|
||||
select="if (self::inValidationResultsWellformedness) then 'val-xml' else 'val-xsd'"/>
|
||||
<xsl:variable name="messages" as="element(rep:message)*">
|
||||
<xsl:apply-templates select="in:xmlSyntaxError">
|
||||
<xsl:with-param name="parent-id" select="$id"/>
|
||||
</xsl:apply-templates>
|
||||
</xsl:variable>
|
||||
<!-- Skip output for implicit validation steps (i. e., wellformedness check) unless there is anything to tell -->
|
||||
<xsl:if test="exists($messages) or exists(s:resource)">
|
||||
<rep:validationStepResult id="{$id}"
|
||||
valid="{if ($messages[@level = ('warning', 'error')]) then false() else true()}">
|
||||
<xsl:sequence select="s:resource"/>
|
||||
<xsl:sequence select="$messages"/>
|
||||
</rep:validationStepResult>
|
||||
</xsl:if>
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template match="in:xmlSyntaxError">
|
||||
<xsl:param name="parent-id" as="xs:string" required="yes"/>
|
||||
<xsl:variable name="id" select="concat($parent-id, '.', count(preceding-sibling::xmlSyntaxError) + 1)"/>
|
||||
<xsl:variable name="level" select="if (@severity = 'SEVERITY_WARNING') then 'warning' else 'error'"/>
|
||||
<rep:message id="{$id}" level="{$level}">
|
||||
<xsl:apply-templates select="*"/>
|
||||
<xsl:value-of select="in:message"/>
|
||||
</rep:message>
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template match="in:xmlSyntaxError/in:*" priority="-1"/>
|
||||
|
||||
|
||||
<xsl:template match="in:xmlSyntaxError/in:rowNumber[. != '-1']">
|
||||
<xsl:attribute name="lineNumber" select="."/>
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template match="in:xmlSyntaxError/in:columnNumber[. != '-1']">
|
||||
<xsl:attribute name="columnNumber" select="."/>
|
||||
</xsl:template>
|
||||
|
||||
<!-- ************************************************************************************** -->
|
||||
<!-- * * -->
|
||||
<!-- * Schematron (SVRL) * -->
|
||||
<!-- * * -->
|
||||
<!-- ************************************************************************************** -->
|
||||
|
||||
|
||||
<xsl:template match="in:validationResultsSchematron">
|
||||
<xsl:variable name="schematron-output" as="element(svrl:schematron-output)?"
|
||||
select="in:results/svrl:schematron-output"/>
|
||||
<xsl:if test="empty($schematron-output)">
|
||||
<xsl:message terminate="yes">Unexpected result from schematron validation - there is no
|
||||
svrl:schematron-output element!
|
||||
</xsl:message>
|
||||
</xsl:if>
|
||||
<xsl:variable name="id" as="xs:string"
|
||||
select="concat('val-sch.',1 + count(preceding-sibling::in:validationResultsSchematron))"/>
|
||||
<xsl:variable name="messages" as="element(rep:message)*">
|
||||
<xsl:apply-templates select="$schematron-output/(svrl:failed-assert|svrl:successful-report)">
|
||||
<xsl:with-param name="parent-id" select="$id"/>
|
||||
</xsl:apply-templates>
|
||||
</xsl:variable>
|
||||
<rep:validationStepResult id="{$id}"
|
||||
valid="{if ($messages[@level = ('warning', 'error')]) then false() else true()}">
|
||||
<xsl:sequence select="s:resource"/>
|
||||
<xsl:sequence select="$messages"/>
|
||||
</rep:validationStepResult>
|
||||
</xsl:template>
|
||||
|
||||
|
||||
<xsl:template match="svrl:failed-assert|svrl:successful-report">
|
||||
<xsl:param name="parent-id" as="xs:string" required="yes"/>
|
||||
<xsl:variable name="id"
|
||||
select="concat($parent-id, '.', count(preceding-sibling::failed-assert | preceding-sibling::successful-report) + 1)"/>
|
||||
<rep:message id="{$id}">
|
||||
<xsl:apply-templates select="in:location/*"/>
|
||||
<xsl:attribute name="level">
|
||||
<xsl:choose>
|
||||
<xsl:when test="(@flag,@role) = ('fatal', 'error')">error</xsl:when>
|
||||
<xsl:when test="(@flag,@role) = ('warning', 'warn')">warning</xsl:when>
|
||||
<xsl:when test="(@flag,@role) = ('information', 'info')">information</xsl:when>
|
||||
<xsl:when test="@role = ('information', 'info')">warning</xsl:when>
|
||||
<xsl:otherwise>error</xsl:otherwise>
|
||||
</xsl:choose>
|
||||
</xsl:attribute>
|
||||
<xsl:apply-templates select="@location"/>
|
||||
<xsl:apply-templates select="@id"/>
|
||||
<xsl:value-of select="svrl:text"/>
|
||||
</rep:message>
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template match="svrl:*/@location">
|
||||
<xsl:attribute name="xpathLocation" select="."/>
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template match="svrl:failed-assert/@id">
|
||||
<xsl:attribute name="code" select="."/>
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template match="svrl:successful-report/@id">
|
||||
<xsl:attribute name="code" select="."/>
|
||||
</xsl:template>
|
||||
|
||||
<!-- ************************************************************************************** -->
|
||||
<!-- * Validation helpers * -->
|
||||
<!-- ************************************************************************************** -->
|
||||
|
||||
<!-- Identity template -->
|
||||
<xsl:template mode="copy-to-report-ns" match="@*">
|
||||
<xsl:copy/>
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template mode="copy-to-report-ns" match="element()" priority="5">
|
||||
<xsl:element name="rep:{local-name()}">
|
||||
<xsl:apply-templates mode="copy-to-report-ns" select="node()|@*"/>
|
||||
</xsl:element>
|
||||
</xsl:template>
|
||||
|
||||
<!-- ************************************************************************************** -->
|
||||
<!-- * * -->
|
||||
<!-- * Assessment * -->
|
||||
<!-- * * -->
|
||||
<!-- ************************************************************************************** -->
|
||||
|
||||
<xd:doc>
|
||||
<xd:desc>
|
||||
<xd:p>Dies ist das zentrale Template des Skripts. Angewandt auf ein
|
||||
report-Dokument ergänzt es dieses um eine Handlungsempfehlung in Form eines
|
||||
<xd:i>accept</xd:i>
|
||||
oder <xd:i>reject</xd:i> Elements.
|
||||
</xd:p>
|
||||
</xd:desc>
|
||||
</xd:doc>
|
||||
<xsl:template match="rep:report" mode="assessment">
|
||||
<rep:assessment>
|
||||
<xsl:variable name="element-name" as="xs:string">
|
||||
<xsl:choose>
|
||||
<xsl:when test="empty(s:scenario)">reject</xsl:when>
|
||||
<xsl:when test="//rep:message[rep:custom-level(.) = 'error']">reject</xsl:when>
|
||||
<xsl:otherwise>accept</xsl:otherwise>
|
||||
</xsl:choose>
|
||||
</xsl:variable>
|
||||
<xsl:element name="rep:{$element-name}" exclude-result-prefixes="#all">
|
||||
<xsl:call-template name="explanations"/>
|
||||
</xsl:element>
|
||||
</rep:assessment>
|
||||
</xsl:template>
|
||||
|
||||
<xd:doc>
|
||||
<xd:desc>
|
||||
<xd:p>Ermittelt für eine während der Validierung ausgegebene Fehlernachricht deren
|
||||
Fehlerlevel <xd:i>(error, warning, information)</xd:i> gemäß der
|
||||
benutzerspezifischen Qualifizierung.
|
||||
</xd:p>
|
||||
<xd:p>Jede Fehlernachricht hat im Rahmen der Validierung ein solches Fehlerlevel
|
||||
erhalten (siehe Attribut <xd:i>@level</xd:i>). Im Regelfall entspricht die
|
||||
benutzerspezifische Qualifizierung unverändert diesem Level. Nutzer können jedoch im
|
||||
Rahmen der Bewertung eigene Qualifizierungen vereinbaren und in dem als Parameter
|
||||
<xd:ref name="assessment" type="parameter"/>
|
||||
übergebenen
|
||||
<xd:i>assessment</xd:i>
|
||||
Element für bestimmte, anhand des Fehlercodes identifizierten Fehlermeldungen eine
|
||||
eigene Qualifizierung als <xd:i>customLevel</xd:i> festlegen.
|
||||
</xd:p>
|
||||
<xd:p>Dies kann z. B. genutzt werden, um einen <xd:i>error</xd:i>, der ansonsten zur
|
||||
Rückweisung der Nachricht führen würde, zumindest zeitweilig als
|
||||
<xd:i>warning</xd:i>
|
||||
zu qualifizieren, so dass eine entsprechende
|
||||
Dokumenteninstanz trotz einer Warnung angenommen und verarbeitet würde.
|
||||
</xd:p>
|
||||
<xd:p>Die Funktion prüft für eine Fehlernachricht, ob deren <xd:i>@code</xd:i> Attribut
|
||||
Bestandteil der für ein bestimmtes <xd:i>customLevel</xd:i> des
|
||||
<xd:ref
|
||||
name="assessment" type="parameter"/>
|
||||
Parameters angegebenen Fehlercodes ist.
|
||||
Falls ja, dann gilt das jeweilige <xd:i>customLevel</xd:i>. Andernfalls wird der im
|
||||
Rahmen der Validierung ermittelte Fehlerlevel unverändert übernommen.
|
||||
</xd:p>
|
||||
</xd:desc>
|
||||
<xd:param name="message">Eine im Rahmen der Validierung ausgegebene
|
||||
Fehlernachricht
|
||||
</xd:param>
|
||||
<xd:return/>
|
||||
</xd:doc>
|
||||
<xsl:function name="rep:custom-level" as="xs:string">
|
||||
<xsl:param name="message" as="element(rep:message)"/>
|
||||
<xsl:variable name="cl" as="element(s:customLevel)?"
|
||||
select="$custom-levels[tokenize(., '\s+') = $message/@code]"/>
|
||||
<xsl:value-of select="if ($cl) then $cl/@level else $message/@level"/>
|
||||
</xsl:function>
|
||||
|
||||
<xsl:template name="explanations">
|
||||
<rep:explanation>
|
||||
<xsl:call-template name="html:html"/>
|
||||
</rep:explanation>
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template name="html:html">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml" data-report-type="report">
|
||||
<xsl:call-template name="html:head"/>
|
||||
<body>
|
||||
<xsl:call-template name="html:document"/>
|
||||
</body>
|
||||
</html>
|
||||
</xsl:template>
|
||||
|
||||
<xd:doc>
|
||||
<xd:desc>
|
||||
<xd:p>Generiert das <xd:i>head</xd:i> Element eines eingebetteten HTML Dokuments,
|
||||
welches den Prüf- und Bewertungsbericht visualisiert und die Handlungsempfehlung
|
||||
begründet
|
||||
</xd:p>
|
||||
</xd:desc>
|
||||
</xd:doc>
|
||||
<xsl:template name="html:head" as="element(html:head)">
|
||||
<head xmlns="http://www.w3.org/1999/xhtml">
|
||||
<title>Prüfbericht</title>
|
||||
<style>
|
||||
body{
|
||||
font-family: Calibri;
|
||||
width: 230mm;
|
||||
}
|
||||
|
||||
.metadata dt {
|
||||
float: left;
|
||||
width: 230px;
|
||||
clear: left;
|
||||
}
|
||||
|
||||
.metadata dd {
|
||||
margin-left: 250px;
|
||||
}
|
||||
|
||||
table{
|
||||
border-collapse: collapse;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
table.tbl-errors{
|
||||
font-size: smaller;
|
||||
}
|
||||
|
||||
table.document{
|
||||
font-size: smaller;
|
||||
}
|
||||
|
||||
table.document td {vertical-align:top;}
|
||||
|
||||
.tbl-errors td{
|
||||
border: 1px solid lightgray;
|
||||
padding: 2px;
|
||||
vertical-align: top;
|
||||
}
|
||||
|
||||
thead{
|
||||
font-weight: bold;
|
||||
background-color: #f0f0f0;
|
||||
padding-top: 6pt;
|
||||
padding-bottom: 2pt;
|
||||
}
|
||||
|
||||
.tbl-meta td{
|
||||
padding-right: 1em;
|
||||
}
|
||||
|
||||
td.pos{
|
||||
padding-left: 3pt;
|
||||
width: 5%;
|
||||
color: gray
|
||||
}
|
||||
|
||||
td.element{
|
||||
width: 95%;
|
||||
word-wrap: break-word;
|
||||
}
|
||||
|
||||
|
||||
td.element:before{
|
||||
content: attr(title);
|
||||
color: gray;
|
||||
}
|
||||
|
||||
|
||||
div.attribute{
|
||||
display: inline;
|
||||
font-style: italic;
|
||||
color: gray;
|
||||
}
|
||||
div.attribute:before{
|
||||
content: attr(title) '=';
|
||||
}
|
||||
div.val{
|
||||
display: inline;
|
||||
font-weight: bold;
|
||||
}
|
||||
|
||||
td.level1{
|
||||
padding-left: 2mm;
|
||||
}
|
||||
|
||||
td.level2{
|
||||
padding-left: 5mm;
|
||||
}
|
||||
|
||||
td.level3{
|
||||
padding-left: 10mm;
|
||||
}
|
||||
|
||||
td.level4{
|
||||
padding-left: 15mm;
|
||||
}
|
||||
|
||||
td.level5{
|
||||
padding-left: 20mm;
|
||||
}
|
||||
td.level6{
|
||||
padding-left: 25mm;
|
||||
}
|
||||
|
||||
tr{
|
||||
vertical-align: bottom;
|
||||
border-bottom: 1px solid #c0c0c0;
|
||||
}
|
||||
|
||||
.error{
|
||||
color: red;
|
||||
}
|
||||
|
||||
.warning{
|
||||
}
|
||||
|
||||
p.important{
|
||||
font-weight: bold;
|
||||
text-align: left;
|
||||
background-color: #e0e0e0;
|
||||
padding: 3pt;
|
||||
}
|
||||
|
||||
td.right{
|
||||
text-align: right
|
||||
}
|
||||
</style>
|
||||
</head>
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template name="html:document" xmlns="http://www.w3.org/1999/xhtml">
|
||||
<h1>Prüfbericht</h1>
|
||||
|
||||
<xsl:call-template name="html:document-metadata"/>
|
||||
|
||||
<xsl:call-template name="html:conformance"/>
|
||||
|
||||
<xsl:if test="//rep:message">
|
||||
<xsl:call-template name="html:validationresults"/>
|
||||
</xsl:if>
|
||||
<xsl:call-template name="html:assessment"/>
|
||||
|
||||
<!-- this is the extension -->
|
||||
<xsl:if test="$input-document instance of document-node(element())">
|
||||
<xsl:call-template name="html:contentdoc">
|
||||
<xsl:with-param name="invoice" select="$input-document"/>
|
||||
</xsl:call-template>
|
||||
</xsl:if>
|
||||
|
||||
<xsl:call-template name="html:epilog"/>
|
||||
</xsl:template>
|
||||
|
||||
|
||||
<xd:doc>
|
||||
<xd:desc>
|
||||
<xd:p>Generiert am Beginn eines eingebetteten HTML Dokuments, welches den Prüf- und
|
||||
Bewertungsbericht visualisiert und die Handlungsempfehlung begründet, eine Übersicht
|
||||
mit Metadaten des geprüften Dokuments.
|
||||
</xd:p>
|
||||
</xd:desc>
|
||||
</xd:doc>
|
||||
<xsl:template name="html:document-metadata" as="element()+">
|
||||
<div class="metadata">
|
||||
<p class="important">
|
||||
<xsl:text>Angaben zum geprüften Dokument</xsl:text>
|
||||
</p>
|
||||
<dl>
|
||||
<dt>Referenz:</dt>
|
||||
<dd>
|
||||
<xsl:value-of select="rep:documentIdentification/rep:documentReference"/>
|
||||
</dd>
|
||||
|
||||
<dt>Zeitpunkt der Prüfung:</dt>
|
||||
<dd>
|
||||
<xsl:value-of select="format-dateTime(rep:timestamp, '[D].[M].[Y] [H]:[m]:[s]')"/>
|
||||
</dd>
|
||||
|
||||
<dt>Erkannter Dokumenttyp:</dt>
|
||||
<dd>
|
||||
<xsl:choose>
|
||||
<xsl:when test="rep:scenarioMatched">
|
||||
<xsl:value-of select="rep:scenarioMatched/s:scenario/s:name"/>
|
||||
</xsl:when>
|
||||
<xsl:otherwise>
|
||||
<b class="error">unbekannt</b>
|
||||
</xsl:otherwise>
|
||||
</xsl:choose>
|
||||
</dd>
|
||||
</dl>
|
||||
<xsl:call-template name="html:documentdata"/>
|
||||
</div>
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template name="html:documentdata"/>
|
||||
|
||||
<xd:doc>
|
||||
<xd:desc>
|
||||
<xd:p>Generiert am Ende eines eingebetteten HTML Dokuments, welches den Prüf- und
|
||||
Bewertungsbericht visualisiert und die Handlungsempfehlung begründet, eine Übersicht
|
||||
mit Metadaten zum Prüfmodul.
|
||||
</xd:p>
|
||||
</xd:desc>
|
||||
</xd:doc>
|
||||
<xsl:template name="html:epilog" as="element()+">
|
||||
<p class="info" xmlns="http://www.w3.org/1999/xhtml">
|
||||
<xsl:text>Dieser Prüfbericht wurde erstellt mit </xsl:text>
|
||||
<xsl:value-of select="rep:engine/rep:name"/>
|
||||
<xsl:text>.</xsl:text>
|
||||
</p>
|
||||
</xsl:template>
|
||||
|
||||
<xd:doc>
|
||||
<xd:desc>
|
||||
<xd:p>Generiert in dem eingebetetteten HTML Dokument eine Tabelle mit den während der
|
||||
Validierung ausgegebenen Daten.
|
||||
</xd:p>
|
||||
</xd:desc>
|
||||
</xd:doc>
|
||||
<xsl:template name="html:validationresults" as="element()*">
|
||||
<p>Übersicht der Validierungsergebnisse:</p>
|
||||
<table class="tbl-errors">
|
||||
<thead>
|
||||
<tr>
|
||||
<th>Prüfschritt</th>
|
||||
<th>Fehler</th>
|
||||
<th>Warnungen</th>
|
||||
<th>Informationen</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<xsl:for-each select="//rep:validationResult/rep:validationStepResult">
|
||||
<xsl:variable name="step-id" select="@id"/>
|
||||
<tr>
|
||||
<td>
|
||||
<xsl:value-of select="s:resource/s:name"/>
|
||||
<xsl:text> (</xsl:text>
|
||||
<xsl:value-of select="@id"/>
|
||||
<xsl:text>)</xsl:text>
|
||||
</td>
|
||||
<td style="width: 30mm;">
|
||||
<xsl:value-of
|
||||
select="count(rep:message[@level eq 'error'])"/>
|
||||
</td>
|
||||
<td style="width: 30mm;">
|
||||
<xsl:value-of
|
||||
select="count(rep:message[@level eq 'warning'])"/>
|
||||
</td>
|
||||
<td style="width: 30mm;">
|
||||
<xsl:value-of
|
||||
select="count(rep:message[@level eq 'information'])"
|
||||
/>
|
||||
</td>
|
||||
</tr>
|
||||
</xsl:for-each>
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
<p>Validierungsergebnisse im Detail:</p>
|
||||
<table xmlns="http://www.w3.org/1999/xhtml" class="tbl-errors">
|
||||
<thead>
|
||||
<tr>
|
||||
<th style="width: 30mm;">Pos</th>
|
||||
<th style="width: 25mm;">Code</th>
|
||||
<th style="width: 25mm;">Adj. Grad (Grad)</th>
|
||||
<th>Text</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<xsl:for-each select="//rep:message">
|
||||
<tr>
|
||||
<xsl:attribute name="class">
|
||||
<xsl:value-of select="rep:custom-level(.)"/>
|
||||
</xsl:attribute>
|
||||
<td rowspan="2">
|
||||
<xsl:value-of select="@id"/>
|
||||
</td>
|
||||
<td rowspan="2">
|
||||
<xsl:value-of select="@code"/>
|
||||
</td>
|
||||
<td rowspan="2">
|
||||
<xsl:value-of select="rep:custom-level(.)"/>
|
||||
<xsl:if test="not(rep:custom-level(.) eq @level)">
|
||||
<xsl:value-of select="concat(' (', @level, ')')"/>
|
||||
</xsl:if>
|
||||
</td>
|
||||
<td>
|
||||
<xsl:value-of select="normalize-space(.)"/>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<xsl:attribute name="class">
|
||||
<xsl:value-of select="rep:custom-level(.)"/>
|
||||
</xsl:attribute>
|
||||
<td>
|
||||
<xsl:if test="@xpathLocation">
|
||||
<xsl:text>Pfad: </xsl:text><xsl:value-of select="@xpathLocation"/>
|
||||
</xsl:if>
|
||||
<xsl:if test="@lineNumber">
|
||||
<xsl:text> Zeile: </xsl:text><xsl:value-of select="@lineNumber"/>
|
||||
</xsl:if>
|
||||
<xsl:if test="@columnNumber">
|
||||
<xsl:text> Spalte: </xsl:text><xsl:value-of select="@columnNumber"/>
|
||||
</xsl:if>
|
||||
</td>
|
||||
</tr>
|
||||
</xsl:for-each>
|
||||
</tbody>
|
||||
</table>
|
||||
</xsl:template>
|
||||
|
||||
<xd:doc>
|
||||
<xd:desc>
|
||||
<xd:p>Generiert in dem eingebetteten HTML Dokument eine Aussage zur Konformität des
|
||||
geprüften Dokuments zu den formalen Vorgaben.
|
||||
</xd:p>
|
||||
</xd:desc>
|
||||
</xd:doc>
|
||||
<xsl:template name="html:conformance">
|
||||
<xsl:variable name="e" as="xs:integer" select="count(//rep:message[@level eq 'error'])"/>
|
||||
<xsl:variable name="w" as="xs:integer" select="count(//rep:message[@level eq 'warning'])"/>
|
||||
<xsl:choose>
|
||||
<xsl:when test="rep:scenarioMatched">
|
||||
<p class="important" xmlns="http://www.w3.org/1999/xhtml">
|
||||
<b>Konformitätsprüfung:</b>
|
||||
<xsl:text>Das geprüfte Dokument enthält </xsl:text>
|
||||
<xsl:choose>
|
||||
<xsl:when test="$e + $w eq 0">
|
||||
<xsl:text>weder Fehler noch Warnungen. Es ist konform zu den formalen Vorgaben.</xsl:text>
|
||||
</xsl:when>
|
||||
<xsl:otherwise>
|
||||
<xsl:value-of select="concat($e, ' Fehler / ', $w, ' Warnungen. Es ist ')"/>
|
||||
<b>nicht konform</b>
|
||||
<xsl:text> zu den formalen Vorgaben.</xsl:text>
|
||||
</xsl:otherwise>
|
||||
</xsl:choose>
|
||||
</p>
|
||||
</xsl:when>
|
||||
<xsl:otherwise>
|
||||
<p class="important" xmlns="http://www.w3.org/1999/xhtml">
|
||||
<b>Konformitätsprüfung:</b>
|
||||
<xsl:text>Das geprüfte Dokument entspricht keinen zulässigen Dokumenttyp und ist damit </xsl:text>
|
||||
<b>nicht konform</b>
|
||||
<xsl:text> zu den formalen Vorgaben.</xsl:text>
|
||||
</p>
|
||||
</xsl:otherwise>
|
||||
</xsl:choose>
|
||||
|
||||
</xsl:template>
|
||||
|
||||
<xd:doc>
|
||||
<xd:desc>
|
||||
<xd:p>Generiert in dem eingebetteten HTML Dokument die Aussage zur
|
||||
Handlungsempfehlung.
|
||||
</xd:p>
|
||||
</xd:desc>
|
||||
</xd:doc>
|
||||
<xsl:template name="html:assessment" xmlns="http://www.w3.org/1999/xhtml">
|
||||
<xsl:variable name="e1" as="xs:integer" select="count(//message[@level eq 'error'])"/>
|
||||
<xsl:variable name="e2" as="xs:integer"
|
||||
select="count(//rep:message[rep:custom-level(.) eq 'error'])"/>
|
||||
<xsl:choose>
|
||||
<xsl:when test="empty(rep:scenarioMatched)">
|
||||
<p class="important error">Bewertung: Es wird empfohlen das Dokument zurückzuweisen.</p>
|
||||
</xsl:when>
|
||||
<xsl:when test="$e1 eq 0 and $e2 eq 0">
|
||||
<p class="important">Bewertung: Es wird empfohlen das Dokument anzunehmen und weiter zu verarbeiten.</p>
|
||||
</xsl:when>
|
||||
<xsl:when test="$e1 gt 0 and $e2 eq 0">
|
||||
<p class="important">Bewertung: Es wird empfohlen das Dokument anzunehmen und zu verarbeiten, da die
|
||||
vorhandenen Fehler derzeit toleriert werden.
|
||||
</p>
|
||||
</xsl:when>
|
||||
<xsl:otherwise>
|
||||
<p class="important error">Bewertung: Es wird empfohlen das Dokument zurückzuweisen.</p>
|
||||
</xsl:otherwise>
|
||||
</xsl:choose>
|
||||
</xsl:template>
|
||||
|
||||
|
||||
<xsl:template name="html:contentdoc">
|
||||
<xsl:param name="invoice" as="document-node(element())"/>
|
||||
<p class="important">
|
||||
<xsl:text>Inhalt des Rechnungsdokuments:</xsl:text>
|
||||
</p>
|
||||
<table class="document" xmlns="http://www.w3.org/1999/xhtml">
|
||||
<xsl:apply-templates select="$invoice/*" mode="html:contentdoc"/>
|
||||
</table>
|
||||
</xsl:template>
|
||||
|
||||
<xd:doc>
|
||||
<xd:desc>
|
||||
<xd:p>Eine Element wird als eine Zeile in einer Tabelle visualisiert. Die erste Spalte
|
||||
enthält die Zeilennummer, die zweite Attribute und Text des Elements
|
||||
</xd:p>
|
||||
</xd:desc>
|
||||
</xd:doc>
|
||||
<xsl:template match="*" mode="html:contentdoc">
|
||||
<xsl:variable name="line-number" as="xs:string">
|
||||
<xsl:number select="." count="*" level="any" format="0001"/>
|
||||
</xsl:variable>
|
||||
<tr class="row" xmlns="http://www.w3.org/1999/xhtml" id="{$line-number}">
|
||||
<td class="pos">
|
||||
<xsl:value-of select="$line-number"/>
|
||||
</td>
|
||||
<td class="element {concat('level',count(ancestor-or-self::*))}" title="{local-name()}">
|
||||
<xsl:apply-templates select="text()" mode="html:contentdoc"/>
|
||||
<xsl:apply-templates select="@*" mode="html:contentdoc"/>
|
||||
</td>
|
||||
</tr>
|
||||
<xsl:apply-templates select="*" mode="html:contentdoc"/>
|
||||
</xsl:template>
|
||||
|
||||
<xd:doc>
|
||||
<xd:desc>
|
||||
<xd:p>Ein Textbereich (in der Zeile des Elements)</xd:p>
|
||||
</xd:desc>
|
||||
</xd:doc>
|
||||
<xsl:template match="text()" mode="html:contentdoc">
|
||||
<div class="val" xmlns="http://www.w3.org/1999/xhtml">
|
||||
<xsl:value-of select="."/>
|
||||
</div>
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template match="element(*, xs:base64Binary)/text()" priority="10" mode="html:contentdoc">
|
||||
<div class="val" xmlns="http://www.w3.org/1999/xhtml">
|
||||
<xsl:text>[ … ]</xsl:text>
|
||||
</div>
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template match="@xsi:schemaLocation" mode="html:contentdoc"/>
|
||||
|
||||
<xd:doc>
|
||||
<xd:desc>
|
||||
<xd:p>Ein Attributbereich (in der Zeile des Elements)</xd:p>
|
||||
</xd:desc>
|
||||
</xd:doc>
|
||||
<xsl:template match="@*" mode="html:contentdoc">
|
||||
<div class="attribute" title="{local-name(.)}" xmlns="http://www.w3.org/1999/xhtml">
|
||||
<xsl:value-of select="."/>
|
||||
</div>
|
||||
</xsl:template>
|
||||
|
||||
|
||||
</xsl:stylesheet>
|
||||
|
|
@ -0,0 +1,607 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!--
|
||||
~ Licensed to the Koordinierungsstelle für IT-Standards (KoSIT) under
|
||||
~ one or more contributor license agreements. See the NOTICE file
|
||||
~ distributed with this work for additional information
|
||||
~ regarding copyright ownership. KoSIT licenses this file
|
||||
~ to you under the Apache License, Version 2.0 (the
|
||||
~ "License"); you may not use this file except in compliance
|
||||
~ with the License. You may obtain a copy of the License at
|
||||
~
|
||||
~ http://www.apache.org/licenses/LICENSE-2.0
|
||||
~
|
||||
~ Unless required by applicable law or agreed to in writing,
|
||||
~ software distributed under the License is distributed on an
|
||||
~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||
~ KIND, either express or implied. See the License for the
|
||||
~ specific language governing permissions and limitations
|
||||
~ under the License.
|
||||
-->
|
||||
|
||||
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
|
||||
xmlns:xs="http://www.w3.org/2001/XMLSchema"
|
||||
xmlns:rep="http://www.xoev.de/de/validator/varl/1 "
|
||||
xmlns:s="http://www.xoev.de/de/validator/framework/1/scenarios"
|
||||
xmlns:in="http://www.xoev.de/de/validator/framework/1/createreportinput"
|
||||
xmlns:svrl="http://purl.oclc.org/dsdl/svrl"
|
||||
xmlns:xd="http://www.oxygenxml.com/ns/doc/xsl"
|
||||
xmlns:html="http://www.w3.org/1999/xhtml"
|
||||
exclude-result-prefixes="xs"
|
||||
version="2.0">
|
||||
|
||||
<xsl:output method="xml" indent="yes"/>
|
||||
|
||||
<xsl:param name="input-document" as="document-node(element())" required="yes"/>
|
||||
|
||||
<xsl:variable name="custom-levels" as="element(s:customLevel)*" select="//s:customLevel"/>
|
||||
|
||||
|
||||
<xsl:template match="in:createReportInput">
|
||||
|
||||
<xsl:variable name="validationStepResults" as="element(rep:validationStepResult)*">
|
||||
<xsl:apply-templates select="in:validationResultsWellformedness"/>
|
||||
<xsl:apply-templates select="in:validationResultsXmlSchema"/>
|
||||
<xsl:apply-templates select="in:validationResultsSchematron"/>
|
||||
</xsl:variable>
|
||||
|
||||
<xsl:variable name="report" as="document-node(element(rep:report))">
|
||||
<xsl:document>
|
||||
<rep:report valid="{if ($validationStepResults[@valid = 'false']) then false() else true()}">
|
||||
<xsl:apply-templates select="in:engine" mode="copy-to-report-ns"/>
|
||||
<xsl:apply-templates select="in:timestamp" mode="copy-to-report-ns"/>
|
||||
<xsl:apply-templates select="in:documentIdentification" mode="copy-to-report-ns"/>
|
||||
<xsl:apply-templates select="s:scenario" mode="copy-to-report-ns"/>
|
||||
<xsl:call-template name="document-data"/>
|
||||
|
||||
<rep:validationResult>
|
||||
<xsl:sequence select="$validationStepResults"/>
|
||||
</rep:validationResult>
|
||||
</rep:report>
|
||||
</xsl:document>
|
||||
</xsl:variable>
|
||||
|
||||
<xsl:variable name="report-with-ids" as="document-node(element(rep:report))">
|
||||
<xsl:document>
|
||||
<xsl:apply-templates select="$report" mode="add-ids"/>
|
||||
</xsl:document>
|
||||
</xsl:variable>
|
||||
|
||||
<rep:report varlVersion="1.0.0">
|
||||
<xsl:copy-of select="$report-with-ids/rep:report/(node()|@*)"/>
|
||||
<xsl:apply-templates select="$report-with-ids"/>
|
||||
</rep:report>
|
||||
|
||||
</xsl:template>
|
||||
|
||||
<!-- Overwrite in customisation layer to generate a documentData element -->
|
||||
<xsl:template name="document-data"/>
|
||||
|
||||
|
||||
<!-- ************************************************************************************** -->
|
||||
<!-- * * -->
|
||||
<!-- * Syntax checks (well-formedness and XML Schema * -->
|
||||
<!-- * * -->
|
||||
<!-- ************************************************************************************** -->
|
||||
|
||||
<xsl:template match="in:validationResultsWellformedness|in:validationResultsXmlSchema">
|
||||
<xsl:variable name="messages" as="element(rep:message)*">
|
||||
<xsl:apply-templates select="in:xmlSyntaxError"/>
|
||||
</xsl:variable>
|
||||
<!-- Skip output for implicit validation steps (i. e., wellformedness check) unless there is anything to tell -->
|
||||
<xsl:if test="exists($messages) or exists(s:resource)">
|
||||
<rep:validationStepResult valid="{if ($messages[@level = ('warning', 'error')]) then false() else true()}">
|
||||
<xsl:apply-templates mode="copy-to-report-ns" select="s:resource"/>
|
||||
<xsl:sequence select="$messages"/>
|
||||
</rep:validationStepResult>
|
||||
</xsl:if>
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template match="in:xmlSyntaxError">
|
||||
<rep:message level="{if (@severity = 'SEVERITY_WARNING') then 'warning' else 'error'}">
|
||||
<xsl:apply-templates select="in:location/*"/>
|
||||
<xsl:value-of select="in:message"/>
|
||||
</rep:message>
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template match="in:xmlSyntaxError/in:rowNumber">
|
||||
<xsl:attribute name="lineNumber" select="."/>
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template match="in:xmlSyntaxError/in:columnNumber">
|
||||
<xsl:attribute name="columnNumber" select="."/>
|
||||
</xsl:template>
|
||||
|
||||
<!-- ************************************************************************************** -->
|
||||
<!-- * * -->
|
||||
<!-- * Schematron (SVRL) * -->
|
||||
<!-- * * -->
|
||||
<!-- ************************************************************************************** -->
|
||||
|
||||
|
||||
<xsl:template match="in:validationResultsSchematron">
|
||||
<xsl:variable name="schematron-output" as="element(svrl:schematron-output)?" select="in:results/svrl:schematron-output"/>
|
||||
<xsl:if test="empty($schematron-output)">
|
||||
<xsl:message terminate="yes">Unexpected result from schematron validation - there is no svrl:schematron-output element!</xsl:message>
|
||||
</xsl:if>
|
||||
<xsl:variable name="messages" as="element(rep:message)*">
|
||||
<xsl:apply-templates select="$schematron-output/(svrl:failed-assert|svrl:successful-report)"/>
|
||||
</xsl:variable>
|
||||
<rep:validationStepResult valid="{if ($messages[@level = ('warning', 'error')]) then false() else true()}">
|
||||
<xsl:apply-templates mode="copy-to-report-ns" select="s:resource"/>
|
||||
<xsl:sequence select="$messages"/>
|
||||
</rep:validationStepResult>
|
||||
</xsl:template>
|
||||
|
||||
|
||||
<xsl:template match="svrl:failed-assert|svrl:successful-report">
|
||||
<rep:message>
|
||||
<xsl:apply-templates select="in:location/*"/>
|
||||
<xsl:attribute name="level">
|
||||
<xsl:choose>
|
||||
<xsl:when test="(@flag,@role) = ('fatal', 'error')">error</xsl:when>
|
||||
<xsl:when test="(@flag,@role) = ('warning', 'warn')">warning</xsl:when>
|
||||
<xsl:when test="(@flag,@role) = ('information', 'info')">information</xsl:when>
|
||||
<xsl:when test="@role = ('information', 'info')">warning</xsl:when>
|
||||
<xsl:otherwise>error</xsl:otherwise>
|
||||
</xsl:choose>
|
||||
</xsl:attribute>
|
||||
<xsl:apply-templates select="@location"/>
|
||||
<xsl:apply-templates select="@id"/>
|
||||
<xsl:value-of select="svrl:text"/>
|
||||
</rep:message>
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template match="svrl:*/@location">
|
||||
<xsl:attribute name="xpathLocation" select="."/>
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template match="svrl:failed-assert/@id">
|
||||
<xsl:attribute name="code" select="."/>
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template match="svrl:successful-report/@id">
|
||||
<xsl:attribute name="code" select="."/>
|
||||
</xsl:template>
|
||||
|
||||
<!-- ************************************************************************************** -->
|
||||
<!-- * Validation helpers * -->
|
||||
<!-- ************************************************************************************** -->
|
||||
|
||||
<!-- Identity template -->
|
||||
<xsl:template mode="copy-to-report-ns" match="element()|@*">
|
||||
<xsl:copy>
|
||||
<xsl:apply-templates mode="copy-to-report-ns" select="node()|@*"/>
|
||||
</xsl:copy>
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template mode="copy-to-report-ns" match="element()" priority="5">
|
||||
<xsl:element name="rep:{local-name()}">
|
||||
<xsl:apply-templates mode="copy-to-report-ns" select="node()|@*"/>
|
||||
</xsl:element>
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template mode="copy-to-report-ns" match="s:*" priority="10">
|
||||
<xsl:copy>
|
||||
<xsl:apply-templates mode="copy-to-report-ns" select="node()|@*"/>
|
||||
</xsl:copy>
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template match="node()|@*" mode="add-ids">
|
||||
<xsl:copy>
|
||||
<xsl:apply-templates select="node()|@*" mode="add-ids"/>
|
||||
</xsl:copy>
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template match="rep:validationStepResult" mode="add-ids">
|
||||
<xsl:copy>
|
||||
<xsl:attribute name="id">
|
||||
<xsl:text>step_</xsl:text>
|
||||
<xsl:number level="multiple" count="rep:validationStepResult"/>
|
||||
</xsl:attribute>
|
||||
<xsl:apply-templates select="node()|@*" mode="add-ids"/>
|
||||
</xsl:copy>
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template match="rep:message" mode="add-ids">
|
||||
<xsl:copy>
|
||||
<xsl:attribute name="id">
|
||||
<xsl:text>message_</xsl:text>
|
||||
<xsl:number level="multiple" count="rep:message | rep:validationStepResult"/>
|
||||
</xsl:attribute>
|
||||
<xsl:apply-templates select="node()|@*" mode="add-ids"/>
|
||||
</xsl:copy>
|
||||
</xsl:template>
|
||||
|
||||
<!-- ************************************************************************************** -->
|
||||
<!-- * * -->
|
||||
<!-- * Assessment (ohne HTML) * -->
|
||||
<!-- * * -->
|
||||
<!-- ************************************************************************************** -->
|
||||
|
||||
<xd:doc>
|
||||
<xd:desc>
|
||||
<xd:p>Dies ist das zentrale Template des Skripts. Angewandt auf ein
|
||||
validationReport-Dokument, und unter Nutzung des <xd:ref name="assessment"
|
||||
type="parameter"/> Parameters wird eine Handlungsempfehlung in Form eines
|
||||
<xd:i>accept</xd:i> oder <xd:i>reject</xd:i> Elements erstellt, welches eine
|
||||
Begründung der jeweiligen Empfehlung enthalten kann.</xd:p>
|
||||
<xd:p>Das Template realisiert eine Funktion f:validationReport, assessment →
|
||||
suggestion</xd:p>
|
||||
</xd:desc>
|
||||
</xd:doc>
|
||||
<xsl:template match="rep:report">
|
||||
<xsl:variable name="element-name" select="if (//rep:message[rep:custom-level(.) = 'error']) then 'reject' else 'accept'"/>
|
||||
<rep:assessment>
|
||||
<xsl:element name="rep:{$element-name}" exclude-result-prefixes="#all">
|
||||
<rep:explanation>
|
||||
<html xmlns="http://www.w3.org/1999/xhtml" data-report-type="devreport-{$element-name}">
|
||||
<xsl:call-template name="html:head"/>
|
||||
<body>
|
||||
<xsl:call-template name="html:document"/>
|
||||
</body>
|
||||
</html>
|
||||
</rep:explanation>
|
||||
</xsl:element>
|
||||
</rep:assessment>
|
||||
</xsl:template>
|
||||
|
||||
<xd:doc>
|
||||
<xd:desc>
|
||||
<xd:p>Ermittelt für eine während der Validierung ausgegebene Fehlernachricht deren
|
||||
Fehlerlevel <xd:i>(error, warning, information)</xd:i> gemäß der
|
||||
benutzerspezifischen Qualifizierung.</xd:p>
|
||||
<xd:p>Jede Fehlernachricht hat im Rahmen der Validierung ein solches Fehlerlevel
|
||||
erhalten (siehe Attribut <xd:i>@level</xd:i>). Im Regelfall entspricht die
|
||||
benutzerspezifische Qualifizierung unverändert diesem Level. Nutzer können jedoch im
|
||||
Rahmen der Bewertung eigene Qualifizierungen vereinbaren und in dem als Parameter
|
||||
<xd:ref name="assessment" type="parameter"/> übergebenen <xd:i>assessment</xd:i>
|
||||
Element für bestimmte, anhand des Fehlercodes identifizierten Fehlermeldungen eine
|
||||
eigene Qualifizierung als <xd:i>customLevel</xd:i> festlegen.</xd:p>
|
||||
<xd:p>Dies kann z. B. genutzt werden, um einen <xd:i>error</xd:i>, der ansonsten zur
|
||||
Rückweisung der Nachricht führen würde, zumindest zeitweilig als
|
||||
<xd:i>warning</xd:i> zu qualifizieren, so dass eine entsprechende
|
||||
Dokumenteninstanz trotz einer Warnung angenommen und verarbeitet würde.</xd:p>
|
||||
<xd:p>Die Funktion prüft für eine Fehlernachricht, ob deren <xd:i>@code</xd:i> Attribut
|
||||
Bestandteil der für ein bestimmtes <xd:i>customLevel</xd:i> des <xd:ref
|
||||
name="assessment" type="parameter"/> Parameters angegebenen Fehlercodes ist.
|
||||
Falls ja, dann gilt das jeweilige <xd:i>customLevel</xd:i>. Andernfalls wird der im
|
||||
Rahmen der Validierung ermittelte Fehlerlevel unverändert übernommen.</xd:p>
|
||||
</xd:desc>
|
||||
<xd:param name="message">Eine im Rahmen der Validierung ausgegebene
|
||||
Fehlernachricht</xd:param>
|
||||
<xd:return/>
|
||||
</xd:doc>
|
||||
<xsl:function name="rep:custom-level" >
|
||||
<xsl:param name="message" as="element(rep:message)"/>
|
||||
<xsl:variable name="cl" as="element(s:customLevel)?"
|
||||
select="$custom-levels[tokenize(., '\s+') = $message/@code]"/>
|
||||
<xsl:value-of select="if ($cl) then $cl/@level else $message/@level"/>
|
||||
</xsl:function>
|
||||
|
||||
|
||||
<!-- ************************************************************************************** -->
|
||||
<!-- * * -->
|
||||
<!-- * HTML * -->
|
||||
<!-- * * -->
|
||||
<!-- ************************************************************************************** -->
|
||||
|
||||
<xsl:template name="html:document">
|
||||
<xsl:call-template name="html:report-header"/>
|
||||
<xsl:call-template name="html:prolog"/>
|
||||
<!-- TODO: documentData -->
|
||||
<xsl:call-template name="html:conformance"/>
|
||||
<xsl:if test="//rep:message">
|
||||
<xsl:call-template name="html:messagetable"/>
|
||||
</xsl:if>
|
||||
<xsl:call-template name="html:assessment"/>
|
||||
<xsl:call-template name="html:epilog"/>
|
||||
</xsl:template>
|
||||
|
||||
<xd:doc>
|
||||
<xd:desc>
|
||||
<xd:p>Generiert das <xd:i>head</xd:i> Element eines eingebetteten HTML Dokuments,
|
||||
welches den Prüf- und Bewertungsbericht visualisiert und die Handlungsempfehlung
|
||||
begründet</xd:p>
|
||||
</xd:desc>
|
||||
</xd:doc>
|
||||
<xsl:template name="html:head" as="element(html:head)">
|
||||
<head xmlns="http://www.w3.org/1999/xhtml">
|
||||
<title>Pruefbericht der KoSIT</title>
|
||||
<style>
|
||||
body{
|
||||
font-family: Calibri;
|
||||
width: 230mm;
|
||||
}
|
||||
|
||||
table{
|
||||
border-collapse: collapse;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
table.tbl-errors{
|
||||
font-size: 10pt;
|
||||
}
|
||||
|
||||
.tbl-errors td{
|
||||
border: 1px solid lightgray;
|
||||
padding: 2px;
|
||||
vertical-align: top;
|
||||
}
|
||||
|
||||
thead{
|
||||
font-weight: bold;
|
||||
background-color: #f0f0f0;
|
||||
padding-top: 6pt;
|
||||
padding-bottom: 2pt;
|
||||
}
|
||||
|
||||
.tbl-meta td{
|
||||
padding-right: 1em;
|
||||
}
|
||||
|
||||
|
||||
|
||||
tr{
|
||||
vertical-align: bottom;
|
||||
border-bottom: 1px solid #c0c0c0;
|
||||
}
|
||||
|
||||
tr.error{
|
||||
font-weight: bold;
|
||||
color: red;
|
||||
}
|
||||
|
||||
tr.warning{
|
||||
font-weight: bold;
|
||||
}
|
||||
|
||||
|
||||
|
||||
tr.pos{
|
||||
font-weight: bold;
|
||||
}
|
||||
|
||||
p.important{
|
||||
font-weight: bold;
|
||||
text-align: left;
|
||||
background-color: #e0e0e0;
|
||||
padding: 3pt;
|
||||
}
|
||||
|
||||
td.right{
|
||||
text-align: right
|
||||
}</style>
|
||||
</head>
|
||||
</xsl:template>
|
||||
|
||||
<xd:doc>
|
||||
<xd:desc>
|
||||
<xd:p>Generiert die Überschrift des eines eingebetteten HTML Dokuments, welches den
|
||||
Prüf- und Bewertungsbericht visualisiert und die Handlungsempfehlung
|
||||
begründet</xd:p>
|
||||
</xd:desc>
|
||||
</xd:doc>
|
||||
<xsl:template name="html:report-header" as="element()+">
|
||||
<h1 xmlns="http://www.w3.org/1999/xhtml">Prüfbericht der KoSIT</h1>
|
||||
</xsl:template>
|
||||
|
||||
<xd:doc>
|
||||
<xd:desc>
|
||||
<xd:p>Generiert am Beginn eines eingebetteten HTML Dokuments, welches den Prüf- und
|
||||
Bewertungsbericht visualisiert und die Handlungsempfehlung begründet, eine Übersicht
|
||||
mit Metadaten des geprüften Dokuments.</xd:p>
|
||||
</xd:desc>
|
||||
</xd:doc>
|
||||
<xsl:template name="html:prolog" as="element()+">
|
||||
<h2 xmlns="http://www.w3.org/1999/xhtml">
|
||||
<xsl:text>Angaben zum geprüften Dokument</xsl:text>
|
||||
</h2>
|
||||
<table class="tbl-meta" xmlns="http://www.w3.org/1999/xhtml">
|
||||
<xsl:if test="/*/@id">
|
||||
<tr>
|
||||
<td colspan="2">Prüfbericht Nr.</td>
|
||||
<td colspan="3">
|
||||
<xsl:value-of select="/*/@id"/>
|
||||
</td>
|
||||
</tr>
|
||||
</xsl:if>
|
||||
<tr>
|
||||
<td colspan="2">Dokument:</td>
|
||||
<td colspan="3">
|
||||
<xsl:value-of select="rep:documentIdentification/rep:documentReference"/>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td colspan="2">Szenario:</td>
|
||||
<td colspan="3">
|
||||
<xsl:value-of select="s:scenario/@name"/>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td colspan="2">Zeitpunkt:</td>
|
||||
<td colspan="3">
|
||||
<xsl:value-of select="format-dateTime(rep:timestamp, '[D].[M].[Y] [H]:[m]:[s]')"
|
||||
/>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td colspan="2">Validierungsschritte:</td>
|
||||
<td>Fehler</td>
|
||||
<td>Warnung</td>
|
||||
<td>Information</td>
|
||||
</tr>
|
||||
<xsl:for-each select="/rep:validationResults/rep:validationStepResult">
|
||||
<xsl:variable name="step-id" select="@id"/>
|
||||
<tr>
|
||||
<td>
|
||||
<xsl:value-of select="@id"/>
|
||||
</td>
|
||||
<td>
|
||||
<xsl:value-of select="s:resource/s:resouceName"/>
|
||||
</td>
|
||||
<td>
|
||||
<xsl:value-of
|
||||
select="count(//rep:message[@step eq $step-id and @level eq 'error'])"/>
|
||||
</td>
|
||||
<td>
|
||||
<xsl:value-of
|
||||
select="count(//rep:message[@step eq $step-id and @level eq 'warning'])"/>
|
||||
</td>
|
||||
<td>
|
||||
<xsl:value-of
|
||||
select="count(//rep:message[@step eq $step-id and @level eq 'information'])"
|
||||
/>
|
||||
</td>
|
||||
</tr>
|
||||
</xsl:for-each>
|
||||
</table>
|
||||
</xsl:template>
|
||||
|
||||
<xd:doc>
|
||||
<xd:desc>
|
||||
<xd:p>Generiert am Ende eines eingebetteten HTML Dokuments, welches den Prüf- und
|
||||
Bewertungsbericht visualisiert und die Handlungsempfehlung begründet, eine Übersicht
|
||||
mit Metadaten zum Prüfmodul.</xd:p>
|
||||
</xd:desc>
|
||||
</xd:doc>
|
||||
<xsl:template name="html:epilog" as="element()+">
|
||||
<p class="info" xmlns="http://www.w3.org/1999/xhtml">
|
||||
<xsl:text>Erstellt mit: </xsl:text>
|
||||
<xsl:value-of select="rep:engine/rep:name"/>
|
||||
<xsl:text> für das InstructionSet </xsl:text>
|
||||
<em>
|
||||
<xsl:value-of select="rep:engine/rep:info[@key eq 'title']"/>
|
||||
</em>
|
||||
<xsl:text> vom </xsl:text>
|
||||
<xsl:value-of
|
||||
select="format-dateTime(xs:dateTime(rep:engine/rep:info[@key eq 'version']), '[D].[M].[Y]')"/>
|
||||
<xsl:text>.</xsl:text>
|
||||
</p>
|
||||
</xsl:template>
|
||||
|
||||
<xd:doc>
|
||||
<xd:desc>
|
||||
<xd:p>Generiert in dem eingebetetteten HTML Dokument eine Tabelle mit den während der
|
||||
Validierung ausgegebenen Daten.</xd:p>
|
||||
</xd:desc>
|
||||
</xd:doc>
|
||||
<xsl:template name="html:messagetable" as="element()">
|
||||
<table xmlns="http://www.w3.org/1999/xhtml" class="tbl-errors">
|
||||
<xsl:call-template name="html:messagetable.head"/>
|
||||
<tbody>
|
||||
<xsl:for-each select="//rep:message">
|
||||
<xsl:call-template name="html:messagetable.row"/>
|
||||
</xsl:for-each>
|
||||
</tbody>
|
||||
</table>
|
||||
</xsl:template>
|
||||
|
||||
<xd:doc>
|
||||
<xd:desc>
|
||||
<xd:p>Generiert in der HTML-Tabelle der Validierungsnachtichten in dem eingebetteten
|
||||
HTML Dokument dn Tabellenkopf</xd:p>
|
||||
</xd:desc>
|
||||
</xd:doc>
|
||||
<xsl:template name="html:messagetable.head" xmlns="http://www.w3.org/1999/xhtml">
|
||||
<thead>
|
||||
<tr>
|
||||
<th>Pos</th>
|
||||
<th>Code</th>
|
||||
<th>CustomLevel (Level)</th>
|
||||
<th>Step</th>
|
||||
<th>Text</th>
|
||||
</tr>
|
||||
</thead>
|
||||
</xsl:template>
|
||||
|
||||
<xd:doc>
|
||||
<xd:desc>
|
||||
<xd:p>Generiert in der HTML-Tabelle der Validierungsnachtichten in dem eingebetteten
|
||||
HTML Dokument eine oder mehrere Zeilen pro Validierungsnachricht</xd:p>
|
||||
</xd:desc>
|
||||
</xd:doc>
|
||||
<xsl:template name="html:messagetable.row" xmlns="http://www.w3.org/1999/xhtml">
|
||||
<tr>
|
||||
<xsl:attribute name="class">
|
||||
<xsl:value-of select="rep:custom-level(.)"/>
|
||||
</xsl:attribute>
|
||||
<td>
|
||||
<xsl:value-of select="position()"/>
|
||||
</td>
|
||||
<td>
|
||||
<xsl:value-of select="@code"/>
|
||||
</td>
|
||||
<td>
|
||||
<xsl:value-of select="rep:custom-level(.)"/>
|
||||
<xsl:if test="not(rep:custom-level(.) eq @level)">
|
||||
<xsl:value-of select="concat(' (', @level, ')')"/>
|
||||
</xsl:if>
|
||||
</td>
|
||||
<td>
|
||||
<xsl:value-of select="@step"/>
|
||||
</td>
|
||||
<td>
|
||||
<xsl:value-of select="normalize-space(.)"/>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td colspan="4"/>
|
||||
<td>
|
||||
<xsl:value-of select="@location"/>
|
||||
</td>
|
||||
</tr>
|
||||
</xsl:template>
|
||||
|
||||
<xd:doc>
|
||||
<xd:desc>
|
||||
<xd:p>Generiert in dem eingebetteten HTML Dokument eine Aussage zur Konformität des
|
||||
geprüften Dokuments zu den formalen Vorgaben.</xd:p>
|
||||
</xd:desc>
|
||||
</xd:doc>
|
||||
<xsl:template name="html:conformance">
|
||||
<xsl:variable name="e" as="xs:integer" select="count(//rep:message[@level eq 'error'])"/>
|
||||
<xsl:variable name="w" as="xs:integer" select="count(//rep:message[@level eq 'warning'])"/>
|
||||
<p class="important" xmlns="http://www.w3.org/1999/xhtml">
|
||||
<b>Konformitätsprüfung: </b>
|
||||
<xsl:text>Das geprüfte Dokument enthält </xsl:text>
|
||||
<xsl:choose>
|
||||
<xsl:when test="$e + $w eq 0">
|
||||
<xsl:text>weder Fehler noch Warnungen. Es ist konform zu den formalen Vorgaben.</xsl:text>
|
||||
</xsl:when>
|
||||
<xsl:otherwise>
|
||||
<xsl:value-of select="concat($e, ' Fehler / ', $w, ' Warnungen. Es ist ')"/>
|
||||
<b>nicht konform</b>
|
||||
<xsl:text> zu den formalen Vorgaben.</xsl:text>
|
||||
</xsl:otherwise>
|
||||
</xsl:choose>
|
||||
</p>
|
||||
</xsl:template>
|
||||
|
||||
<xd:doc>
|
||||
<xd:desc>
|
||||
<xd:p>Generiert in dem eingebetteten HTML Dokument die Aussage zur
|
||||
Handlungsempfehlung.</xd:p>
|
||||
</xd:desc>
|
||||
</xd:doc>
|
||||
<xsl:template name="html:assessment">
|
||||
<xsl:variable name="e1" as="xs:integer" select="count(//message[@level eq 'error'])"/>
|
||||
<xsl:variable name="e2" as="xs:integer"
|
||||
select="count(//rep:message[rep:custom-level(.) eq 'error'])"/>
|
||||
<p class="important" xmlns="http://www.w3.org/1999/xhtml">
|
||||
<b>Bewertung: </b>
|
||||
<xsl:choose>
|
||||
<xsl:when test="$e1 eq 0 and $e2 eq 0">
|
||||
<xsl:text>Es wird empfohlen das Dokument anzunehmen un weiter zu verarbeiten.</xsl:text>
|
||||
</xsl:when>
|
||||
<xsl:when test="$e1 gt 0 and $e2 eq 0">
|
||||
<xsl:text>Es wird empfohlen das Dokument anzunehmen und zu verarbeiten, da die vorhandenen Fehler derzeit toleriert werden.</xsl:text>
|
||||
</xsl:when>
|
||||
<xsl:otherwise>
|
||||
<xsl:text>Es wird empfohlen das Dokument zurückzuweisen.</xsl:text>
|
||||
</xsl:otherwise>
|
||||
</xsl:choose>
|
||||
</p>
|
||||
</xsl:template>
|
||||
|
||||
|
||||
</xsl:stylesheet>
|
||||
330
src/test/resources/examples/results/report.xml
Normal file
330
src/test/resources/examples/results/report.xml
Normal file
|
|
@ -0,0 +1,330 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!--
|
||||
~ Licensed to the Koordinierungsstelle für IT-Standards (KoSIT) under
|
||||
~ one or more contributor license agreements. See the NOTICE file
|
||||
~ distributed with this work for additional information
|
||||
~ regarding copyright ownership. KoSIT licenses this file
|
||||
~ to you under the Apache License, Version 2.0 (the
|
||||
~ "License"); you may not use this file except in compliance
|
||||
~ with the License. You may obtain a copy of the License at
|
||||
~
|
||||
~ http://www.apache.org/licenses/LICENSE-2.0
|
||||
~
|
||||
~ Unless required by applicable law or agreed to in writing,
|
||||
~ software distributed under the License is distributed on an
|
||||
~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||
~ KIND, either express or implied. See the License for the
|
||||
~ specific language governing permissions and limitations
|
||||
~ under the License.
|
||||
-->
|
||||
|
||||
<rep:report xmlns:rep="http://www.xoev.de/de/validator/varl/1 " valid="false" varlVersion="1.0.0">
|
||||
<rep:engine>
|
||||
<rep:name>KoSIT POC</rep:name>
|
||||
</rep:engine>
|
||||
<rep:timestamp>2017-09-01T13:13:59.055+02:00</rep:timestamp>
|
||||
<rep:documentIdentification>
|
||||
<rep:documentHash>
|
||||
<rep:hashAlgorithm>SHA-256</rep:hashAlgorithm>
|
||||
<rep:hashValue>4exhW9EJxAbhlZLHZ3mYZ3/hWGG5e6mIpiTAlGTpQ7s=</rep:hashValue>
|
||||
</rep:documentHash>
|
||||
<rep:documentReference>
|
||||
/C:/Developer/source/init/eRechnung-Check/src/test/resources/examples/UBLReady/UBLReady_EU_UBL-NL_20170102_FULL.xml
|
||||
</rep:documentReference>
|
||||
</rep:documentIdentification>
|
||||
<ns2:scenario xmlns:ns2="http://www.xoev.de/de/validator/framework/1/scenarios"
|
||||
xmlns="http://www.xoev.de/de/validator/framework/1/createreportinput">
|
||||
<ns2:name>UBL 2.1 Invoice</ns2:name>
|
||||
<ns2:namespace prefix="invoice">urn:oasis:names:specification:ubl:schema:xsd:Invoice-2</ns2:namespace>
|
||||
<ns2:match>/invoice:Invoice</ns2:match>
|
||||
<ns2:validateWithXmlSchema>
|
||||
<ns2:resource>
|
||||
<ns2:name>UBL 2.1 Invoice</ns2:name>
|
||||
<ns2:location>resources/eRechnung/UBL-2.1/xsdrt/maindoc/UBL-Invoice-2.1.xsd</ns2:location>
|
||||
</ns2:resource>
|
||||
</ns2:validateWithXmlSchema>
|
||||
<ns2:validateWithSchematron>
|
||||
<ns2:resource>
|
||||
<ns2:name>BII Rules for Invoice</ns2:name>
|
||||
<ns2:location>resources/eRechnung/UBL-2.1/xsl/BIIRULES-UBL-T10.xsl</ns2:location>
|
||||
</ns2:resource>
|
||||
</ns2:validateWithSchematron>
|
||||
<ns2:validateWithSchematron>
|
||||
<ns2:resource>
|
||||
<ns2:name>openPEPPOL Rules for Invoice</ns2:name>
|
||||
<ns2:location>resources/eRechnung/UBL-2.1/xsl/OPENPEPPOL-UBL-T10.xsl</ns2:location>
|
||||
</ns2:resource>
|
||||
</ns2:validateWithSchematron>
|
||||
<ns2:createReport>
|
||||
<ns2:resource>
|
||||
<ns2:name>Report für eRechnung</ns2:name>
|
||||
<ns2:location>resources/eRechnung/report.xsl</ns2:location>
|
||||
</ns2:resource>
|
||||
</ns2:createReport>
|
||||
</ns2:scenario>
|
||||
<rep:validationResult>
|
||||
<rep:validationStepResult id="step_1" valid="true">
|
||||
<ns2:resource xmlns:ns2="http://www.xoev.de/de/validator/framework/1/scenarios"
|
||||
xmlns="http://www.xoev.de/de/validator/framework/1/createreportinput">
|
||||
<ns2:name>UBL 2.1 Invoice</ns2:name>
|
||||
<ns2:location>resources/eRechnung/UBL-2.1/xsdrt/maindoc/UBL-Invoice-2.1.xsd</ns2:location>
|
||||
</ns2:resource>
|
||||
</rep:validationStepResult>
|
||||
<rep:validationStepResult id="step_2" valid="false">
|
||||
<ns2:resource xmlns:ns2="http://www.xoev.de/de/validator/framework/1/scenarios"
|
||||
xmlns="http://www.xoev.de/de/validator/framework/1/createreportinput">
|
||||
<ns2:name>BII Rules for Invoice</ns2:name>
|
||||
<ns2:location>resources/eRechnung/UBL-2.1/xsl/BIIRULES-UBL-T10.xsl</ns2:location>
|
||||
</ns2:resource>
|
||||
<rep:message code="CL-T10-R010" id="message_2.1" level="warning"
|
||||
xpathLocation="/*:Invoice[namespace-uri()='urn:oasis:names:specification:ubl:schema:xsd:Invoice-2'][1]/*:AllowanceCharge[namespace-uri()='urn:oasis:names:specification:ubl:schema:xsd:CommonAggregateComponents-2'][3]/*:AllowanceChargeReasonCode[namespace-uri()='urn:oasis:names:specification:ubl:schema:xsd:CommonBasicComponents-2'][1]">
|
||||
[CL-T10-R010]-Coded allowance and charge reasons SHOULD belong to the UNCL 4465 code list BII2 subset
|
||||
</rep:message>
|
||||
</rep:validationStepResult>
|
||||
<rep:validationStepResult id="step_3" valid="false">
|
||||
<ns2:resource xmlns:ns2="http://www.xoev.de/de/validator/framework/1/scenarios"
|
||||
xmlns="http://www.xoev.de/de/validator/framework/1/createreportinput">
|
||||
<ns2:name>openPEPPOL Rules for Invoice</ns2:name>
|
||||
<ns2:location>resources/eRechnung/UBL-2.1/xsl/OPENPEPPOL-UBL-T10.xsl</ns2:location>
|
||||
</ns2:resource>
|
||||
<rep:message code="EUGEN-T10-R026" id="message_3.1" level="error"
|
||||
xpathLocation="/*:Invoice[namespace-uri()='urn:oasis:names:specification:ubl:schema:xsd:Invoice-2'][1]/*:DocumentCurrencyCode[namespace-uri()='urn:oasis:names:specification:ubl:schema:xsd:CommonBasicComponents-2'][1]">
|
||||
[EUGEN-T10-R026]-A currency code element MUST have a list identifier attribute 'ISO4217'.
|
||||
</rep:message>
|
||||
<rep:message code="EUGEN-T10-R041" id="message_3.2" level="warning"
|
||||
xpathLocation="/*:Invoice[namespace-uri()='urn:oasis:names:specification:ubl:schema:xsd:Invoice-2'][1]/*:AccountingSupplierParty[namespace-uri()='urn:oasis:names:specification:ubl:schema:xsd:CommonAggregateComponents-2'][1]">
|
||||
[EUGEN-T10-R041]-The VAT identifier for the supplier SHOULD be prefixed with country code for companies
|
||||
with VAT registration in EU countries
|
||||
</rep:message>
|
||||
<rep:message code="EUGEN-T10-R054" id="message_3.3" level="warning"
|
||||
xpathLocation="/*:Invoice[namespace-uri()='urn:oasis:names:specification:ubl:schema:xsd:Invoice-2'][1]/*:AccountingSupplierParty[namespace-uri()='urn:oasis:names:specification:ubl:schema:xsd:CommonAggregateComponents-2'][1]/*:Party[namespace-uri()='urn:oasis:names:specification:ubl:schema:xsd:CommonAggregateComponents-2'][1]/*:PartyLegalEntity[namespace-uri()='urn:oasis:names:specification:ubl:schema:xsd:CommonAggregateComponents-2'][1]/*:CompanyID[namespace-uri()='urn:oasis:names:specification:ubl:schema:xsd:CommonBasicComponents-2'][1]">
|
||||
[EUGEN-T10-R054]-A party legal entity company identifier SHOULD have a scheme identifier attribute.
|
||||
</rep:message>
|
||||
<rep:message code="EUGEN-T10-R029" id="message_3.4" level="error"
|
||||
xpathLocation="/*:Invoice[namespace-uri()='urn:oasis:names:specification:ubl:schema:xsd:Invoice-2'][1]/*:AllowanceCharge[namespace-uri()='urn:oasis:names:specification:ubl:schema:xsd:CommonAggregateComponents-2'][1]/*:AllowanceChargeReasonCode[namespace-uri()='urn:oasis:names:specification:ubl:schema:xsd:CommonBasicComponents-2'][1]">
|
||||
[EUGEN-T10-R029]-An allowance charge reason code MUST have a list identifier attribute 'UNCL4465'.
|
||||
</rep:message>
|
||||
<rep:message code="EUGEN-T10-R029" id="message_3.5" level="error"
|
||||
xpathLocation="/*:Invoice[namespace-uri()='urn:oasis:names:specification:ubl:schema:xsd:Invoice-2'][1]/*:AllowanceCharge[namespace-uri()='urn:oasis:names:specification:ubl:schema:xsd:CommonAggregateComponents-2'][2]/*:AllowanceChargeReasonCode[namespace-uri()='urn:oasis:names:specification:ubl:schema:xsd:CommonBasicComponents-2'][1]">
|
||||
[EUGEN-T10-R029]-An allowance charge reason code MUST have a list identifier attribute 'UNCL4465'.
|
||||
</rep:message>
|
||||
<rep:message code="EUGEN-T10-R029" id="message_3.6" level="error"
|
||||
xpathLocation="/*:Invoice[namespace-uri()='urn:oasis:names:specification:ubl:schema:xsd:Invoice-2'][1]/*:AllowanceCharge[namespace-uri()='urn:oasis:names:specification:ubl:schema:xsd:CommonAggregateComponents-2'][3]/*:AllowanceChargeReasonCode[namespace-uri()='urn:oasis:names:specification:ubl:schema:xsd:CommonBasicComponents-2'][1]">
|
||||
[EUGEN-T10-R029]-An allowance charge reason code MUST have a list identifier attribute 'UNCL4465'.
|
||||
</rep:message>
|
||||
</rep:validationStepResult>
|
||||
</rep:validationResult>
|
||||
<rep:assessment>
|
||||
<rep:reject>
|
||||
<rep:explanation>
|
||||
<html xmlns="http://www.w3.org/1999/xhtml" data-report-type="devreport-reject">
|
||||
<head>
|
||||
<title>Pruefbericht der KoSIT</title>
|
||||
<style>
|
||||
body{
|
||||
font-family: Calibri;
|
||||
width: 230mm;
|
||||
}
|
||||
|
||||
table{
|
||||
border-collapse: collapse;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
table.tbl-errors{
|
||||
font-size: 10pt;
|
||||
}
|
||||
|
||||
.tbl-errors td{
|
||||
border: 1px solid lightgray;
|
||||
padding: 2px;
|
||||
vertical-align: top;
|
||||
}
|
||||
|
||||
thead{
|
||||
font-weight: bold;
|
||||
background-color: #f0f0f0;
|
||||
padding-top: 6pt;
|
||||
padding-bottom: 2pt;
|
||||
}
|
||||
|
||||
.tbl-meta td{
|
||||
padding-right: 1em;
|
||||
}
|
||||
|
||||
|
||||
tr{
|
||||
vertical-align: bottom;
|
||||
border-bottom: 1px solid #c0c0c0;
|
||||
}
|
||||
|
||||
tr.error{
|
||||
font-weight: bold;
|
||||
color: red;
|
||||
}
|
||||
|
||||
tr.warning{
|
||||
font-weight: bold;
|
||||
}
|
||||
|
||||
|
||||
tr.pos{
|
||||
font-weight: bold;
|
||||
}
|
||||
|
||||
p.important{
|
||||
font-weight: bold;
|
||||
text-align: left;
|
||||
background-color: #e0e0e0;
|
||||
padding: 3pt;
|
||||
}
|
||||
|
||||
td.right{
|
||||
text-align: right
|
||||
}
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
<h1>Prüfbericht der KoSIT</h1>
|
||||
<h2>Angaben zum geprüften Dokument</h2>
|
||||
<table class="tbl-meta">
|
||||
<tr>
|
||||
<td colspan="2">Dokument:</td>
|
||||
<td colspan="3">
|
||||
/C:/Developer/source/init/eRechnung-Check/src/test/resources/examples/UBLReady/UBLReady_EU_UBL-NL_20170102_FULL.xml
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td colspan="2">Szenario:</td>
|
||||
<td colspan="3"/>
|
||||
</tr>
|
||||
<tr>
|
||||
<td colspan="2">Zeitpunkt:</td>
|
||||
<td colspan="3">1.9.2017 13:13:59</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td colspan="2">Validierungsschritte:</td>
|
||||
<td>Fehler</td>
|
||||
<td>Warnung</td>
|
||||
<td>Information</td>
|
||||
</tr>
|
||||
</table>
|
||||
<p class="important"><b>Konformitätsprüfung:</b>Das geprüfte Dokument enthält 4 Fehler / 3
|
||||
Warnungen. Es ist <b>nicht konform</b> zu den formalen Vorgaben.
|
||||
</p>
|
||||
<table class="tbl-errors">
|
||||
<thead>
|
||||
<tr>
|
||||
<th>Pos</th>
|
||||
<th>Code</th>
|
||||
<th>CustomLevel (Level)</th>
|
||||
<th>Step</th>
|
||||
<th>Text</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr class="warning">
|
||||
<td>1</td>
|
||||
<td>CL-T10-R010</td>
|
||||
<td>warning</td>
|
||||
<td/>
|
||||
<td>[CL-T10-R010]-Coded allowance and charge reasons SHOULD belong to the UNCL 4465
|
||||
code list BII2 subset
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td colspan="4"/>
|
||||
<td/>
|
||||
</tr>
|
||||
<tr class="error">
|
||||
<td>2</td>
|
||||
<td>EUGEN-T10-R026</td>
|
||||
<td>error</td>
|
||||
<td/>
|
||||
<td>[EUGEN-T10-R026]-A currency code element MUST have a list identifier attribute
|
||||
'ISO4217'.
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td colspan="4"/>
|
||||
<td/>
|
||||
</tr>
|
||||
<tr class="warning">
|
||||
<td>3</td>
|
||||
<td>EUGEN-T10-R041</td>
|
||||
<td>warning</td>
|
||||
<td/>
|
||||
<td>[EUGEN-T10-R041]-The VAT identifier for the supplier SHOULD be prefixed with
|
||||
country code for companies with VAT registration in EU countries
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td colspan="4"/>
|
||||
<td/>
|
||||
</tr>
|
||||
<tr class="warning">
|
||||
<td>4</td>
|
||||
<td>EUGEN-T10-R054</td>
|
||||
<td>warning</td>
|
||||
<td/>
|
||||
<td>[EUGEN-T10-R054]-A party legal entity company identifier SHOULD have a scheme
|
||||
identifier attribute.
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td colspan="4"/>
|
||||
<td/>
|
||||
</tr>
|
||||
<tr class="error">
|
||||
<td>5</td>
|
||||
<td>EUGEN-T10-R029</td>
|
||||
<td>error</td>
|
||||
<td/>
|
||||
<td>[EUGEN-T10-R029]-An allowance charge reason code MUST have a list identifier
|
||||
attribute 'UNCL4465'.
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td colspan="4"/>
|
||||
<td/>
|
||||
</tr>
|
||||
<tr class="error">
|
||||
<td>6</td>
|
||||
<td>EUGEN-T10-R029</td>
|
||||
<td>error</td>
|
||||
<td/>
|
||||
<td>[EUGEN-T10-R029]-An allowance charge reason code MUST have a list identifier
|
||||
attribute 'UNCL4465'.
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td colspan="4"/>
|
||||
<td/>
|
||||
</tr>
|
||||
<tr class="error">
|
||||
<td>7</td>
|
||||
<td>EUGEN-T10-R029</td>
|
||||
<td>error</td>
|
||||
<td/>
|
||||
<td>[EUGEN-T10-R029]-An allowance charge reason code MUST have a list identifier
|
||||
attribute 'UNCL4465'.
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td colspan="4"/>
|
||||
<td/>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
<p class="important"><b>Bewertung:</b>Es wird empfohlen das Dokument zurückzuweisen.
|
||||
</p>
|
||||
<p class="info">Erstellt mit: KoSIT POC für das InstructionSet
|
||||
<em/>
|
||||
vom .
|
||||
</p>
|
||||
</body>
|
||||
</html>
|
||||
</rep:explanation>
|
||||
</rep:reject>
|
||||
</rep:assessment>
|
||||
</rep:report>
|
||||
66
src/test/resources/examples/versioning/scenarios-base.xml
Normal file
66
src/test/resources/examples/versioning/scenarios-base.xml
Normal file
|
|
@ -0,0 +1,66 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!--
|
||||
~ Licensed to the Koordinierungsstelle für IT-Standards (KoSIT) under
|
||||
~ one or more contributor license agreements. See the NOTICE file
|
||||
~ distributed with this work for additional information
|
||||
~ regarding copyright ownership. KoSIT licenses this file
|
||||
~ to you under the Apache License, Version 2.0 (the
|
||||
~ "License"); you may not use this file except in compliance
|
||||
~ with the License. You may obtain a copy of the License at
|
||||
~
|
||||
~ http://www.apache.org/licenses/LICENSE-2.0
|
||||
~
|
||||
~ Unless required by applicable law or agreed to in writing,
|
||||
~ software distributed under the License is distributed on an
|
||||
~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||
~ KIND, either express or implied. See the License for the
|
||||
~ specific language governing permissions and limitations
|
||||
~ under the License.
|
||||
-->
|
||||
|
||||
<scenarios xmlns="http://www.xoev.de/de/validator/framework/1/scenarios" frameworkVersion="1.0.0">
|
||||
<name>XInneres</name>
|
||||
<date>2017-08-08</date>
|
||||
<description>
|
||||
<p>Prüft XInneres Nachrichten anhand der von uns offiziell herausgegebenen XML Schemata und Beispielen für mögliche weitergehende Prüfungen mit Schematron. </p>
|
||||
<p>Prüft elektronische Rechnungen im Format UBL 2.1 </p>
|
||||
</description>
|
||||
|
||||
<scenario>
|
||||
<name>UBL 2.1 Invoice</name>
|
||||
<namespace prefix="invoice">urn:oasis:names:specification:ubl:schema:xsd:Invoice-2</namespace>
|
||||
<match>/invoice:Invoice</match>
|
||||
|
||||
<validateWithXmlSchema>
|
||||
<resource>
|
||||
<name>UBL 2.1 Invoice</name>
|
||||
<location>resources/eRechnung/UBL-2.1/xsdrt/maindoc/UBL-Invoice-2.1.xsd</location>
|
||||
</resource>
|
||||
</validateWithXmlSchema>
|
||||
<validateWithSchematron>
|
||||
<resource>
|
||||
<name>BII Rules for Invoice</name>
|
||||
<location>resources/eRechnung/UBL-2.1/xsl/BIIRULES-UBL-T10.xsl</location>
|
||||
</resource>
|
||||
</validateWithSchematron>
|
||||
<validateWithSchematron>
|
||||
<resource>
|
||||
<name>openPEPPOL Rules for Invoice</name>
|
||||
<location>resources/eRechnung/UBL-2.1/xsl/OPENPEPPOL-UBL-T10.xsl</location>
|
||||
</resource>
|
||||
</validateWithSchematron>
|
||||
<createReport>
|
||||
<resource>
|
||||
<name>Report für eRechnung</name>
|
||||
<location>resources/eRechnung/report.xsl</location>
|
||||
</resource>
|
||||
</createReport>
|
||||
</scenario>
|
||||
<noScenarioReport>
|
||||
<resource>
|
||||
<name>default</name>
|
||||
<location>resources/eRechnung/report.xsl</location>
|
||||
</resource>
|
||||
</noScenarioReport>
|
||||
|
||||
</scenarios>
|
||||
|
|
@ -0,0 +1,66 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!--
|
||||
~ Licensed to the Koordinierungsstelle für IT-Standards (KoSIT) under
|
||||
~ one or more contributor license agreements. See the NOTICE file
|
||||
~ distributed with this work for additional information
|
||||
~ regarding copyright ownership. KoSIT licenses this file
|
||||
~ to you under the Apache License, Version 2.0 (the
|
||||
~ "License"); you may not use this file except in compliance
|
||||
~ with the License. You may obtain a copy of the License at
|
||||
~
|
||||
~ http://www.apache.org/licenses/LICENSE-2.0
|
||||
~
|
||||
~ Unless required by applicable law or agreed to in writing,
|
||||
~ software distributed under the License is distributed on an
|
||||
~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||
~ KIND, either express or implied. See the License for the
|
||||
~ specific language governing permissions and limitations
|
||||
~ under the License.
|
||||
-->
|
||||
|
||||
<scenarios xmlns="http://www.xoev.de/de/validator/framework/1/scenarios" frameworkVersion="1.1.0">
|
||||
<name>XInneres</name>
|
||||
<date>2017-08-08</date>
|
||||
<description>
|
||||
<p>Prüft XInneres Nachrichten anhand der von uns offiziell herausgegebenen XML Schemata und Beispielen für mögliche weitergehende Prüfungen mit Schematron. </p>
|
||||
<p>Prüft elektronische Rechnungen im Format UBL 2.1 </p>
|
||||
</description>
|
||||
|
||||
<scenario>
|
||||
<name>UBL 2.1 Invoice</name>
|
||||
<namespace prefix="invoice">urn:oasis:names:specification:ubl:schema:xsd:Invoice-2</namespace>
|
||||
<match>/invoice:Invoice</match>
|
||||
|
||||
<validateWithXmlSchema>
|
||||
<resource>
|
||||
<name>UBL 2.1 Invoice</name>
|
||||
<location>resources/eRechnung/UBL-2.1/xsdrt/maindoc/UBL-Invoice-2.1.xsd</location>
|
||||
</resource>
|
||||
</validateWithXmlSchema>
|
||||
<validateWithSchematron>
|
||||
<resource>
|
||||
<name>BII Rules for Invoice</name>
|
||||
<location>resources/eRechnung/UBL-2.1/xsl/BIIRULES-UBL-T10.xsl</location>
|
||||
</resource>
|
||||
</validateWithSchematron>
|
||||
<validateWithSchematron>
|
||||
<resource>
|
||||
<name>openPEPPOL Rules for Invoice</name>
|
||||
<location>resources/eRechnung/UBL-2.1/xsl/OPENPEPPOL-UBL-T10.xsl</location>
|
||||
</resource>
|
||||
</validateWithSchematron>
|
||||
<createReport>
|
||||
<resource>
|
||||
<name>Report für eRechnung</name>
|
||||
<location>resources/eRechnung/report.xsl</location>
|
||||
</resource>
|
||||
</createReport>
|
||||
</scenario>
|
||||
<noScenarioReport>
|
||||
<resource>
|
||||
<name>default</name>
|
||||
<location>resources/eRechnung/report.xsl</location>
|
||||
</resource>
|
||||
</noScenarioReport>
|
||||
|
||||
</scenarios>
|
||||
|
|
@ -0,0 +1,60 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!--
|
||||
~ Licensed to the Koordinierungsstelle für IT-Standards (KoSIT) under
|
||||
~ one or more contributor license agreements. See the NOTICE file
|
||||
~ distributed with this work for additional information
|
||||
~ regarding copyright ownership. KoSIT licenses this file
|
||||
~ to you under the Apache License, Version 2.0 (the
|
||||
~ "License"); you may not use this file except in compliance
|
||||
~ with the License. You may obtain a copy of the License at
|
||||
~
|
||||
~ http://www.apache.org/licenses/LICENSE-2.0
|
||||
~
|
||||
~ Unless required by applicable law or agreed to in writing,
|
||||
~ software distributed under the License is distributed on an
|
||||
~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||
~ KIND, either express or implied. See the License for the
|
||||
~ specific language governing permissions and limitations
|
||||
~ under the License.
|
||||
-->
|
||||
|
||||
<scenarios xmlns="http://www.xoev.de/de/validator/framework/1/scenarios" frameworkVersion="1.1.0">
|
||||
<name>XInneres</name>
|
||||
<date>2017-08-08</date>
|
||||
<description>
|
||||
<p>Prüft XInneres Nachrichten anhand der von uns offiziell herausgegebenen XML Schemata und Beispielen für mögliche weitergehende Prüfungen mit Schematron. </p>
|
||||
<p>Prüft elektronische Rechnungen im Format UBL 2.1 </p>
|
||||
</description>
|
||||
|
||||
<scenario>
|
||||
<name>UBL 2.1 Invoice</name>
|
||||
<namespace prefix="invoice">urn:oasis:names:specification:ubl:schema:xsd:Invoice-2</namespace>
|
||||
<match>/invoice:Invoice</match>
|
||||
<newElementFeature>toTest</newElementFeature>
|
||||
<validateWithXmlSchema>
|
||||
<resource>
|
||||
<name>UBL 2.1 Invoice</name>
|
||||
<location>resources/eRechnung/UBL-2.1/xsdrt/maindoc/UBL-Invoice-2.1.xsd</location>
|
||||
</resource>
|
||||
</validateWithXmlSchema>
|
||||
<validateWithSchematron>
|
||||
<resource>
|
||||
<name>BII Rules for Invoice</name>
|
||||
<location>resources/eRechnung/UBL-2.1/xsl/BIIRULES-UBL-T10.xsl</location>
|
||||
</resource>
|
||||
</validateWithSchematron>
|
||||
<validateWithSchematron>
|
||||
<resource>
|
||||
<name>openPEPPOL Rules for Invoice</name>
|
||||
<location>resources/eRechnung/UBL-2.1/xsl/OPENPEPPOL-UBL-T10.xsl</location>
|
||||
</resource>
|
||||
</validateWithSchematron>
|
||||
<createReport>
|
||||
<resource>
|
||||
<name>Report für eRechnung</name>
|
||||
<location>resources/eRechnung/report.xsl</location>
|
||||
</resource>
|
||||
</createReport>
|
||||
</scenario>
|
||||
|
||||
</scenarios>
|
||||
|
|
@ -0,0 +1,60 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!--
|
||||
~ Licensed to the Koordinierungsstelle für IT-Standards (KoSIT) under
|
||||
~ one or more contributor license agreements. See the NOTICE file
|
||||
~ distributed with this work for additional information
|
||||
~ regarding copyright ownership. KoSIT licenses this file
|
||||
~ to you under the Apache License, Version 2.0 (the
|
||||
~ "License"); you may not use this file except in compliance
|
||||
~ with the License. You may obtain a copy of the License at
|
||||
~
|
||||
~ http://www.apache.org/licenses/LICENSE-2.0
|
||||
~
|
||||
~ Unless required by applicable law or agreed to in writing,
|
||||
~ software distributed under the License is distributed on an
|
||||
~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||
~ KIND, either express or implied. See the License for the
|
||||
~ specific language governing permissions and limitations
|
||||
~ under the License.
|
||||
-->
|
||||
|
||||
<scenarios xmlns="http://www.xoev.de/de/validator/framework/2/scenarios" frameworkVersion="2.1.0">
|
||||
<name>XInneres</name>
|
||||
<date>2017-08-08</date>
|
||||
<description>
|
||||
<p>Prüft XInneres Nachrichten anhand der von uns offiziell herausgegebenen XML Schemata und Beispielen für mögliche weitergehende Prüfungen mit Schematron. </p>
|
||||
<p>Prüft elektronische Rechnungen im Format UBL 2.1 </p>
|
||||
</description>
|
||||
|
||||
<scenario>
|
||||
<name>UBL 2.1 Invoice</name>
|
||||
<namespace prefix="invoice">urn:oasis:names:specification:ubl:schema:xsd:Invoice-2</namespace>
|
||||
<match>/invoice:Invoice</match>
|
||||
<newElementFeature>toTest</newElementFeature>
|
||||
<validateWithXmlSchema>
|
||||
<resource>
|
||||
<name>UBL 2.1 Invoice</name>
|
||||
<location>resources/eRechnung/UBL-2.1/xsdrt/maindoc/UBL-Invoice-2.1.xsd</location>
|
||||
</resource>
|
||||
</validateWithXmlSchema>
|
||||
<validateWithSchematron>
|
||||
<resource>
|
||||
<name>BII Rules for Invoice</name>
|
||||
<location>resources/eRechnung/UBL-2.1/xsl/BIIRULES-UBL-T10.xsl</location>
|
||||
</resource>
|
||||
</validateWithSchematron>
|
||||
<validateWithSchematron>
|
||||
<resource>
|
||||
<name>openPEPPOL Rules for Invoice</name>
|
||||
<location>resources/eRechnung/UBL-2.1/xsl/OPENPEPPOL-UBL-T10.xsl</location>
|
||||
</resource>
|
||||
</validateWithSchematron>
|
||||
<createReport>
|
||||
<resource>
|
||||
<name>Report für eRechnung</name>
|
||||
<location>resources/eRechnung/report.xsl</location>
|
||||
</resource>
|
||||
</createReport>
|
||||
</scenario>
|
||||
|
||||
</scenarios>
|
||||
90
src/test/resources/invalid/scenarios-illformed.xml
Normal file
90
src/test/resources/invalid/scenarios-illformed.xml
Normal file
|
|
@ -0,0 +1,90 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!--
|
||||
~ Licensed to the Koordinierungsstelle für IT-Standards (KoSIT) under
|
||||
~ one or more contributor license agreements. See the NOTICE file
|
||||
~ distributed with this work for additional information
|
||||
~ regarding copyright ownership. KoSIT licenses this file
|
||||
~ to you under the Apache License, Version 2.0 (the
|
||||
~ "License"); you may not use this file except in compliance
|
||||
~ with the License. You may obtain a copy of the License at
|
||||
~
|
||||
~ http://www.apache.org/licenses/LICENSE-2.0
|
||||
~
|
||||
~ Unless required by applicable law or agreed to in writing,
|
||||
~ software distributed under the License is distributed on an
|
||||
~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||
~ KIND, either express or implied. See the License for the
|
||||
~ specific language governing permissions and limitations
|
||||
~ under the License.
|
||||
-->
|
||||
|
||||
<scenarios xmlns="http://xoev.de/validation/scenarios/1">
|
||||
<name>XInneres</name>
|
||||
<date>2017-08-08</date>
|
||||
<description>
|
||||
<p>Prüft XInneres Nachrichten anhand der von uns offiziell herausgegebenen XML Schemata und Beispielen für mögliche weitergehende Prüfungen mit Schematron. </p>
|
||||
<p>Prüft elektronische Rechnungen im Format UBL 2.1 </p>
|
||||
</description>
|
||||
|
||||
<scenario>
|
||||
<name>XMeld 2.1</name>
|
||||
<namespace prefix="xmeld">http://www.osci.de/xmeld21</namespace>
|
||||
<match>/xmeld:*</match>
|
||||
<validateWithXmlSchema>
|
||||
<resource>
|
||||
<name>XML Schema von XMeld 2.1 (aggregiert)</name>
|
||||
<location>resources/xmeld21/xmeld-nachrichten.xsd</location>
|
||||
</resource>
|
||||
</validateWithXmlSchema>
|
||||
<validateWithSchematron>
|
||||
<resource>
|
||||
<name>XInneres Prüfregeln</name>
|
||||
<location>resources/xmeld21/xinneres-pruefregeln.xsl</location>
|
||||
</resource>
|
||||
</validateWithSchematron>
|
||||
<createReport>
|
||||
<resource>
|
||||
<name>Default Report</name>
|
||||
<location>resources/default/report.xsl</location>
|
||||
</resource>
|
||||
</createReport>
|
||||
</scenariox>
|
||||
|
||||
<scenario>
|
||||
<name>UBL 2.1 Invoice</name>
|
||||
<namespace prefix="invoice">urn:oasis:names:specification:ubl:schema:xsd:Invoice-2</namespace>
|
||||
<match>/invoice:Invoice</match>
|
||||
|
||||
<validateWithXmlSchema>
|
||||
<resource>
|
||||
<name>UBL 2.1 Invoice</name>
|
||||
<location>resources/eRechnung/UBL-2.1/xsdrt/maindoc/UBL-Invoice-2.1.xsd</location>
|
||||
</resource>
|
||||
</validateWithXmlSchema>
|
||||
<validateWithSchematron>
|
||||
<resource>
|
||||
<name>BII Rules for Invoice</name>
|
||||
<location>resources/eRechnung/BIS2.0-VA-V3.4.0/XSLT/BIIRULES-UBL-T10.xsl</location>
|
||||
</resource>
|
||||
</validateWithSchematron>
|
||||
<validateWithSchematron>
|
||||
<resource>
|
||||
<name>openPEPPOL Rules for Invoice</name>
|
||||
<location>resources/eRechnung/BIS2.0-VA-V3.4.0/XSLT/OPENPEPPOL-UBL-T10.xsl</location>
|
||||
</resource>
|
||||
</validateWithSchematron>
|
||||
<createReport>
|
||||
<resource>
|
||||
<name>Report für eRechnung</name>
|
||||
<!-- report-erechnung.xsl bindet report.xsl ein -->
|
||||
<location>resources/eRechnung/report-erechnung.xsl</location>
|
||||
</resource>
|
||||
<customLevel level="warning">EUGEN-T110-R019</customLevel>
|
||||
</createReport>
|
||||
<!--<createReport>
|
||||
<name>Report für eRechnung (Dataport-Fassung)</name>
|
||||
<location>resources/eRechnung/report-erechnung-dataport.xsl</location>
|
||||
</createReport>-->
|
||||
</scenario>
|
||||
|
||||
</scenarios>
|
||||
87
src/test/resources/invalid/scenarios-invalid.xml
Normal file
87
src/test/resources/invalid/scenarios-invalid.xml
Normal file
|
|
@ -0,0 +1,87 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!--
|
||||
~ Licensed to the Koordinierungsstelle für IT-Standards (KoSIT) under
|
||||
~ one or more contributor license agreements. See the NOTICE file
|
||||
~ distributed with this work for additional information
|
||||
~ regarding copyright ownership. KoSIT licenses this file
|
||||
~ to you under the Apache License, Version 2.0 (the
|
||||
~ "License"); you may not use this file except in compliance
|
||||
~ with the License. You may obtain a copy of the License at
|
||||
~
|
||||
~ http://www.apache.org/licenses/LICENSE-2.0
|
||||
~
|
||||
~ Unless required by applicable law or agreed to in writing,
|
||||
~ software distributed under the License is distributed on an
|
||||
~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||
~ KIND, either express or implied. See the License for the
|
||||
~ specific language governing permissions and limitations
|
||||
~ under the License.
|
||||
-->
|
||||
|
||||
<scenarios xmlns="http://www.xoev.de/de/validator/framework/1/scenarios">
|
||||
<name>XInneres</name>
|
||||
<date>2017-08-08</date>
|
||||
<description>
|
||||
<p>Prüft XInneres Nachrichten anhand der von uns offiziell herausgegebenen XML Schemata und Beispielen für
|
||||
mögliche weitergehende Prüfungen mit Schematron.
|
||||
</p>
|
||||
<p>Prüft elektronische Rechnungen im Format UBL 2.1</p>
|
||||
</description>
|
||||
|
||||
<scenario>
|
||||
<name>XMeld 2.1</name>
|
||||
<namespace prefix="xmeld">http://www.osci.de/xmeld21</namespace>
|
||||
<match>/xmeld:*</match>
|
||||
|
||||
<validateWithSchematron>
|
||||
<resource>
|
||||
<name>XInneres Prüfregeln</name>
|
||||
<location>resources/xmeld21/xinneres-pruefregeln.xsl</location>
|
||||
</resource>
|
||||
</validateWithSchematron>
|
||||
<createReport>
|
||||
<resource>
|
||||
<name>Default Report</name>
|
||||
<location>resources/default/report.xsl</location>
|
||||
</resource>
|
||||
</createReport>
|
||||
</scenario>
|
||||
|
||||
<scenario>
|
||||
<name>UBL 2.1 Invoice</name>
|
||||
<namespace prefix="invoice">urn:oasis:names:specification:ubl:schema:xsd:Invoice-2</namespace>
|
||||
<match>/invoice:Invoice</match>
|
||||
|
||||
<validateWithXmlSchema>
|
||||
<resource>
|
||||
<name>UBL 2.1 Invoice</name>
|
||||
<location>resources/eRechnung/UBL-2.1/xsdrt/maindoc/UBL-Invoice-2.1.xsd</location>
|
||||
</resource>
|
||||
</validateWithXmlSchema>
|
||||
<validateWithSchematron>
|
||||
<resource>
|
||||
<name>BII Rules for Invoice</name>
|
||||
<location>resources/eRechnung/BIS2.0-VA-V3.4.0/XSLT/BIIRULES-UBL-T10.xsl</location>
|
||||
</resource>
|
||||
</validateWithSchematron>
|
||||
<validateWithSchematron>
|
||||
<resource>
|
||||
<name>openPEPPOL Rules for Invoice</name>
|
||||
<location>resources/eRechnung/BIS2.0-VA-V3.4.0/XSLT/OPENPEPPOL-UBL-T10.xsl</location>
|
||||
</resource>
|
||||
</validateWithSchematron>
|
||||
<createReport>
|
||||
<resource>
|
||||
<name>Report für eRechnung</name>
|
||||
<!-- report-erechnung.xsl bindet report.xsl ein -->
|
||||
<location>resources/eRechnung/report-erechnung.xsl</location>
|
||||
</resource>
|
||||
<customLevel level="warning">EUGEN-T110-R019</customLevel>
|
||||
</createReport>
|
||||
<!--<createReport>
|
||||
<name>Report für eRechnung (Dataport-Fassung)</name>
|
||||
<location>resources/eRechnung/report-erechnung-dataport.xsl</location>
|
||||
</createReport>-->
|
||||
</scenario>
|
||||
|
||||
</scenarios>
|
||||
101
src/test/resources/valid/report.xml
Normal file
101
src/test/resources/valid/report.xml
Normal file
|
|
@ -0,0 +1,101 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!--
|
||||
~ Licensed to the Koordinierungsstelle für IT-Standards (KoSIT) under
|
||||
~ one or more contributor license agreements. See the NOTICE file
|
||||
~ distributed with this work for additional information
|
||||
~ regarding copyright ownership. KoSIT licenses this file
|
||||
~ to you under the Apache License, Version 2.0 (the
|
||||
~ "License"); you may not use this file except in compliance
|
||||
~ with the License. You may obtain a copy of the License at
|
||||
~
|
||||
~ http://www.apache.org/licenses/LICENSE-2.0
|
||||
~
|
||||
~ Unless required by applicable law or agreed to in writing,
|
||||
~ software distributed under the License is distributed on an
|
||||
~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||
~ KIND, either express or implied. See the License for the
|
||||
~ specific language governing permissions and limitations
|
||||
~ under the License.
|
||||
-->
|
||||
|
||||
<rep:report xmlns:rep="http://xoev.de/validation/report/1" xmlns:s="http://xoev.de/validation/scenarios/1" valid="true">
|
||||
|
||||
<rep:engine>
|
||||
<rep:name>Prüfmodul der KoSIT POC</rep:name>
|
||||
</rep:engine>
|
||||
|
||||
<rep:timestamp>2017-08-17T12:00:00</rep:timestamp>
|
||||
|
||||
<rep:documentIdentification>
|
||||
<rep:documentHash>
|
||||
<rep:hashAlgorithm>fake</rep:hashAlgorithm>
|
||||
<rep:hashValue>0x0c</rep:hashValue>
|
||||
</rep:documentHash>
|
||||
<rep:documentReference>ABHanAZR_AllesKorrekt.xml</rep:documentReference>
|
||||
</rep:documentIdentification>
|
||||
|
||||
<s:scenario>
|
||||
<s:name>UBL 2.1 Invoice</s:name>
|
||||
<s:namespace prefix="invoice">urn:oasis:names:specification:ubl:schema:xsd:Invoice-2</s:namespace>
|
||||
<s:match>/invoice:Invoice</s:match>
|
||||
<s:validateWithXmlSchema>
|
||||
<s:resource>
|
||||
<s:name>UBL 2.1 Invoice</s:name>
|
||||
<s:location>resources/eRechnung/UBL-2.1/xsdrt/maindoc/UBL-Invoice-2.1.xsd</s:location>
|
||||
</s:resource>
|
||||
</s:validateWithXmlSchema>
|
||||
<s:validateWithSchematron>
|
||||
<s:resource>
|
||||
<s:name>BII Rules for Invoice</s:name>
|
||||
<s:location>resources/eRechnung/BIS2.0-VA-V3.4.0/XSLT/BIIRULES-UBL-T10.xsl</s:location>
|
||||
</s:resource>
|
||||
</s:validateWithSchematron>
|
||||
<s:validateWithSchematron>
|
||||
<s:resource>
|
||||
<s:name>openPEPPOL Rules for Invoice</s:name>
|
||||
<s:location>resources/eRechnung/BIS2.0-VA-V3.4.0/XSLT/OPENPEPPOL-UBL-T10.xsl</s:location>
|
||||
</s:resource>
|
||||
</s:validateWithSchematron>
|
||||
<s:createReport>
|
||||
<s:resource>
|
||||
<s:name>Report für eRechnung</s:name>
|
||||
<s:location>resources/eRechnung/report-erechnung.xsl</s:location>
|
||||
</s:resource>
|
||||
</s:createReport>
|
||||
</s:scenario>
|
||||
|
||||
<rep:documentData>
|
||||
<rechnungsnummer>123</rechnungsnummer>
|
||||
<rechnungssteller>ABC GmbH</rechnungssteller>
|
||||
</rep:documentData>
|
||||
|
||||
<rep:validationResult>
|
||||
<rep:validationStepResult id="step_1" valid="true">
|
||||
<s:resource>
|
||||
<s:name>UBL 2.1 Invoice</s:name>
|
||||
<s:location>resources/eRechnung/UBL-2.1/xsdrt/maindoc/UBL-Invoice-2.1.xsd</s:location>
|
||||
</s:resource>
|
||||
<!--<rep:message id="message_1.1" level="error" lineNumber="1" columnNumber="120">Problem ...</rep:message>-->
|
||||
</rep:validationStepResult>
|
||||
|
||||
<rep:validationStepResult id="step_2" valid="false">
|
||||
<s:resource>
|
||||
<s:name>openPEPPOL Rules for Invoice</s:name>
|
||||
<s:location>../resources/eRechnung/BIS2.0-VA-V3.4.0/XSLT/OPENPEPPOL-UBL-T10.xsl</s:location>
|
||||
</s:resource>
|
||||
<rep:message id="message_2.1" level="warning" lineNumber="120" columnNumber="13" xpathLocation="..." code="EUGEN-T110-R013">[EUGEN-T110-R025]-UBLVersionID must be 2.1</rep:message>
|
||||
</rep:validationStepResult>
|
||||
|
||||
</rep:validationResult>
|
||||
|
||||
<rep:assessment>
|
||||
<rep:customLevel level="warning">EUGEN-T110-R024</rep:customLevel>
|
||||
<rep:reject>
|
||||
<rep:explanation id="enduser">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml"> ... </html>
|
||||
</rep:explanation>
|
||||
</rep:reject>
|
||||
</rep:assessment>
|
||||
|
||||
|
||||
</rep:report>
|
||||
96
src/test/resources/valid/scenarios.xml
Normal file
96
src/test/resources/valid/scenarios.xml
Normal file
|
|
@ -0,0 +1,96 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!--
|
||||
~ Licensed to the Koordinierungsstelle für IT-Standards (KoSIT) under
|
||||
~ one or more contributor license agreements. See the NOTICE file
|
||||
~ distributed with this work for additional information
|
||||
~ regarding copyright ownership. KoSIT licenses this file
|
||||
~ to you under the Apache License, Version 2.0 (the
|
||||
~ "License"); you may not use this file except in compliance
|
||||
~ with the License. You may obtain a copy of the License at
|
||||
~
|
||||
~ http://www.apache.org/licenses/LICENSE-2.0
|
||||
~
|
||||
~ Unless required by applicable law or agreed to in writing,
|
||||
~ software distributed under the License is distributed on an
|
||||
~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||
~ KIND, either express or implied. See the License for the
|
||||
~ specific language governing permissions and limitations
|
||||
~ under the License.
|
||||
-->
|
||||
|
||||
<scenarios xmlns="http://www.xoev.de/de/validator/framework/1/scenarios" frameworkVersion="1.0.0">
|
||||
<name>XInneres</name>
|
||||
<date>2017-08-08</date>
|
||||
<description>
|
||||
<p>Prüft XInneres Nachrichten anhand der von uns offiziell herausgegebenen XML Schemata und Beispielen für mögliche weitergehende Prüfungen mit Schematron. </p>
|
||||
<p>Prüft elektronische Rechnungen im Format UBL 2.1 </p>
|
||||
</description>
|
||||
|
||||
<scenario>
|
||||
<name>XMeld 2.1</name>
|
||||
<namespace prefix="xmeld">http://www.osci.de/xmeld21</namespace>
|
||||
<match>/xmeld:*</match>
|
||||
<validateWithXmlSchema>
|
||||
<resource>
|
||||
<name>XML Schema von XMeld 2.1 (aggregiert)</name>
|
||||
<location>resources/xmeld21/xmeld-nachrichten.xsd</location>
|
||||
</resource>
|
||||
</validateWithXmlSchema>
|
||||
<validateWithSchematron>
|
||||
<resource>
|
||||
<name>XInneres Prüfregeln</name>
|
||||
<location>resources/xmeld21/xinneres-pruefregeln.xsl</location>
|
||||
</resource>
|
||||
</validateWithSchematron>
|
||||
<createReport>
|
||||
<resource>
|
||||
<name>Default Report</name>
|
||||
<location>resources/default/report.xsl</location>
|
||||
</resource>
|
||||
</createReport>
|
||||
</scenario>
|
||||
|
||||
<scenario>
|
||||
<name>UBL 2.1 Invoice</name>
|
||||
<namespace prefix="invoice">urn:oasis:names:specification:ubl:schema:xsd:Invoice-2</namespace>
|
||||
<match>/invoice:Invoice</match>
|
||||
|
||||
<validateWithXmlSchema>
|
||||
<resource>
|
||||
<name>UBL 2.1 Invoice</name>
|
||||
<location>resources/eRechnung/UBL-2.1/xsdrt/maindoc/UBL-Invoice-2.1.xsd</location>
|
||||
</resource>
|
||||
</validateWithXmlSchema>
|
||||
<validateWithSchematron>
|
||||
<resource>
|
||||
<name>BII Rules for Invoice</name>
|
||||
<location>resources/eRechnung/BIS2.0-VA-V3.4.0/XSLT/BIIRULES-UBL-T10.xsl</location>
|
||||
</resource>
|
||||
</validateWithSchematron>
|
||||
<validateWithSchematron>
|
||||
<resource>
|
||||
<name>openPEPPOL Rules for Invoice</name>
|
||||
<location>resources/eRechnung/BIS2.0-VA-V3.4.0/XSLT/OPENPEPPOL-UBL-T10.xsl</location>
|
||||
</resource>
|
||||
</validateWithSchematron>
|
||||
<createReport>
|
||||
<resource>
|
||||
<name>Report für eRechnung</name>
|
||||
<!-- report-erechnung.xsl bindet report.xsl ein -->
|
||||
<location>resources/eRechnung/report-erechnung.xsl</location>
|
||||
</resource>
|
||||
<customLevel level="warning">EUGEN-T110-R019</customLevel>
|
||||
</createReport>
|
||||
<!--<createReport>
|
||||
<name>Report für eRechnung (Dataport-Fassung)</name>
|
||||
<location>resources/eRechnung/report-erechnung-dataport.xsl</location>
|
||||
</createReport>-->
|
||||
</scenario>
|
||||
<noScenarioReport>
|
||||
<resource>
|
||||
<name>default</name>
|
||||
<location>resources/eRechnung/report.xsl</location>
|
||||
</resource>
|
||||
</noScenarioReport>
|
||||
|
||||
</scenarios>
|
||||
Loading…
Add table
Add a link
Reference in a new issue