You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@polygene.apache.org by pa...@apache.org on 2017/03/13 10:35:12 UTC
[20/50] [abbrv] polygene-java git commit: New (de)serialization API
and SPI & new implementations
http://git-wip-us.apache.org/repos/asf/polygene-java/blob/c9dd7229/extensions/serialization-msgpack/src/main/java/org/apache/polygene/serialization/msgpack/package.html
----------------------------------------------------------------------
diff --git a/extensions/serialization-msgpack/src/main/java/org/apache/polygene/serialization/msgpack/package.html b/extensions/serialization-msgpack/src/main/java/org/apache/polygene/serialization/msgpack/package.html
new file mode 100644
index 0000000..16c905a
--- /dev/null
+++ b/extensions/serialization-msgpack/src/main/java/org/apache/polygene/serialization/msgpack/package.html
@@ -0,0 +1,24 @@
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF 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.
+ ~
+ ~
+ -->
+<html>
+ <body>
+ <h2>MessagePack Serialization.</h2>
+ </body>
+</html>
http://git-wip-us.apache.org/repos/asf/polygene-java/blob/c9dd7229/extensions/serialization-msgpack/src/test/java/org/apache/polygene/serialization/msgpack/MessagePackCollectionSerializationTest.java
----------------------------------------------------------------------
diff --git a/extensions/serialization-msgpack/src/test/java/org/apache/polygene/serialization/msgpack/MessagePackCollectionSerializationTest.java b/extensions/serialization-msgpack/src/test/java/org/apache/polygene/serialization/msgpack/MessagePackCollectionSerializationTest.java
new file mode 100644
index 0000000..6ade37f
--- /dev/null
+++ b/extensions/serialization-msgpack/src/test/java/org/apache/polygene/serialization/msgpack/MessagePackCollectionSerializationTest.java
@@ -0,0 +1,31 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF 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 org.apache.polygene.serialization.msgpack;
+
+import org.apache.polygene.bootstrap.ModuleAssembly;
+import org.apache.polygene.test.serialization.AbstractCollectionSerializationTest;
+
+public class MessagePackCollectionSerializationTest extends AbstractCollectionSerializationTest
+{
+ @Override
+ public void assemble( ModuleAssembly module )
+ {
+ new MessagePackSerializationAssembler().assemble( module );
+ super.assemble( module );
+ }
+}
http://git-wip-us.apache.org/repos/asf/polygene-java/blob/c9dd7229/extensions/serialization-msgpack/src/test/java/org/apache/polygene/serialization/msgpack/MessagePackDateFormatSerializationTest.java
----------------------------------------------------------------------
diff --git a/extensions/serialization-msgpack/src/test/java/org/apache/polygene/serialization/msgpack/MessagePackDateFormatSerializationTest.java b/extensions/serialization-msgpack/src/test/java/org/apache/polygene/serialization/msgpack/MessagePackDateFormatSerializationTest.java
new file mode 100644
index 0000000..083d418
--- /dev/null
+++ b/extensions/serialization-msgpack/src/test/java/org/apache/polygene/serialization/msgpack/MessagePackDateFormatSerializationTest.java
@@ -0,0 +1,33 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF 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 org.apache.polygene.serialization.msgpack;
+
+import org.apache.polygene.bootstrap.ModuleAssembly;
+import org.apache.polygene.test.serialization.AbstractDateFormatSerializationTest;
+import org.junit.Ignore;
+
+@Ignore( "Super test assume text" )
+public class MessagePackDateFormatSerializationTest extends AbstractDateFormatSerializationTest
+{
+ @Override
+ public void assemble( ModuleAssembly module )
+ {
+ new MessagePackSerializationAssembler().assemble( module );
+ super.assemble( module );
+ }
+}
http://git-wip-us.apache.org/repos/asf/polygene-java/blob/c9dd7229/extensions/serialization-msgpack/src/test/java/org/apache/polygene/serialization/msgpack/MessagePackPlainValueSerializationTest.java
----------------------------------------------------------------------
diff --git a/extensions/serialization-msgpack/src/test/java/org/apache/polygene/serialization/msgpack/MessagePackPlainValueSerializationTest.java b/extensions/serialization-msgpack/src/test/java/org/apache/polygene/serialization/msgpack/MessagePackPlainValueSerializationTest.java
new file mode 100644
index 0000000..3940b64
--- /dev/null
+++ b/extensions/serialization-msgpack/src/test/java/org/apache/polygene/serialization/msgpack/MessagePackPlainValueSerializationTest.java
@@ -0,0 +1,35 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF 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 org.apache.polygene.serialization.msgpack;
+
+import org.apache.polygene.bootstrap.ModuleAssembly;
+import org.apache.polygene.test.serialization.AbstractPlainValueSerializationTest;
+import org.junit.Ignore;
+
+@Ignore( "Super test assume text" )
+public class MessagePackPlainValueSerializationTest extends AbstractPlainValueSerializationTest
+{
+ @Override
+ public void assemble( ModuleAssembly module )
+ {
+ new MessagePackSerializationAssembler().assemble( module );
+ super.assemble( module );
+ }
+}
http://git-wip-us.apache.org/repos/asf/polygene-java/blob/c9dd7229/extensions/serialization-msgpack/src/test/java/org/apache/polygene/serialization/msgpack/MessagePackValueCompositeSerializationTest.java
----------------------------------------------------------------------
diff --git a/extensions/serialization-msgpack/src/test/java/org/apache/polygene/serialization/msgpack/MessagePackValueCompositeSerializationTest.java b/extensions/serialization-msgpack/src/test/java/org/apache/polygene/serialization/msgpack/MessagePackValueCompositeSerializationTest.java
new file mode 100644
index 0000000..204f991
--- /dev/null
+++ b/extensions/serialization-msgpack/src/test/java/org/apache/polygene/serialization/msgpack/MessagePackValueCompositeSerializationTest.java
@@ -0,0 +1,31 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF 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 org.apache.polygene.serialization.msgpack;
+
+import org.apache.polygene.bootstrap.ModuleAssembly;
+import org.apache.polygene.test.serialization.AbstractValueCompositeSerializationTest;
+
+public class MessagePackValueCompositeSerializationTest extends AbstractValueCompositeSerializationTest
+{
+ @Override
+ public void assemble( ModuleAssembly module )
+ {
+ new MessagePackSerializationAssembler().assemble( module );
+ super.assemble( module );
+ }
+}
http://git-wip-us.apache.org/repos/asf/polygene-java/blob/c9dd7229/extensions/valueserialization-jackson/build.gradle
----------------------------------------------------------------------
diff --git a/extensions/valueserialization-jackson/build.gradle b/extensions/valueserialization-jackson/build.gradle
deleted file mode 100644
index fa23ac3..0000000
--- a/extensions/valueserialization-jackson/build.gradle
+++ /dev/null
@@ -1,37 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF 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.
- *
- *
- */
-
-apply plugin: 'polygene-extension'
-
-description = "Apache Polygene\u2122 Jackson ValueSerialization Extension"
-
-jar { manifest { name = "Apache Polygene\u2122 Extension - ValueSerialization - Jackson" } }
-
-dependencies {
- api polygene.core.bootstrap
-
- implementation libraries.jackson_mapper
-
- runtimeOnly polygene.core.runtime
-
- testImplementation polygene.core.testsupport
-
- testRuntimeOnly libraries.logback
-}
http://git-wip-us.apache.org/repos/asf/polygene-java/blob/c9dd7229/extensions/valueserialization-jackson/dev-status.xml
----------------------------------------------------------------------
diff --git a/extensions/valueserialization-jackson/dev-status.xml b/extensions/valueserialization-jackson/dev-status.xml
deleted file mode 100644
index 7fa50ff..0000000
--- a/extensions/valueserialization-jackson/dev-status.xml
+++ /dev/null
@@ -1,36 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!--
- ~ Licensed to the Apache Software Foundation (ASF) under one
- ~ or more contributor license agreements. See the NOTICE file
- ~ distributed with this work for additional information
- ~ regarding copyright ownership. The ASF 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.
- ~
- ~
- -->
-<module xmlns="http://polygene.apache.org/schemas/2008/dev-status/1"
- xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:schemaLocation="http://polygene.apache.org/schemas/2008/dev-status/1
- http://polygene.apache.org/schemas/2008/dev-status/1/dev-status.xsd">
- <status>
- <codebase>beta</codebase>
- <!--none,early,beta,stable,mature-->
- <documentation>good</documentation>
- <!-- none, brief, good, complete -->
- <unittests>complete</unittests>
- <!-- none, some, good, complete -->
- </status>
- <licenses>
- <license>ALv2</license>
- </licenses>
-</module>
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/polygene-java/blob/c9dd7229/extensions/valueserialization-jackson/src/docs/vs-jackson.txt
----------------------------------------------------------------------
diff --git a/extensions/valueserialization-jackson/src/docs/vs-jackson.txt b/extensions/valueserialization-jackson/src/docs/vs-jackson.txt
deleted file mode 100644
index 8605125..0000000
--- a/extensions/valueserialization-jackson/src/docs/vs-jackson.txt
+++ /dev/null
@@ -1,43 +0,0 @@
-///////////////////////////////////////////////////////////////
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF 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.
-///////////////////////////////////////////////////////////////
-
-[[extension-vs-jackson, Jackson ValueSerialization]]
-= Jackson ValueSerialization =
-
-[devstatus]
---------------
-source=extensions/valueserialization-jackson/dev-status.xml
---------------
-
-ValueSerialization Service backed by http://wiki.fasterxml.com/JacksonHome[Jackson].
-
-include::../../build/docs/buildinfo/artifact.txt[]
-
-== Assembly ==
-
-Assembly is done as follows:
-
-[snippet,java]
-----
-source=extensions/valueserialization-jackson/src/test/java/org/apache/polygene/valueserialization/jackson/JacksonPlainValueSerializationTest.java
-tag=assembly
-----
-
-See the ValueSerialization <<core-api-value,API>> and <<core-spi-valueserialization,SPI>> documentation for details and
-usage.
http://git-wip-us.apache.org/repos/asf/polygene-java/blob/c9dd7229/extensions/valueserialization-jackson/src/main/java/org/apache/polygene/valueserialization/jackson/JacksonValueDeserializer.java
----------------------------------------------------------------------
diff --git a/extensions/valueserialization-jackson/src/main/java/org/apache/polygene/valueserialization/jackson/JacksonValueDeserializer.java b/extensions/valueserialization-jackson/src/main/java/org/apache/polygene/valueserialization/jackson/JacksonValueDeserializer.java
deleted file mode 100644
index 256cbe7..0000000
--- a/extensions/valueserialization-jackson/src/main/java/org/apache/polygene/valueserialization/jackson/JacksonValueDeserializer.java
+++ /dev/null
@@ -1,379 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF 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 org.apache.polygene.valueserialization.jackson;
-
-import com.fasterxml.jackson.core.JsonFactory;
-import com.fasterxml.jackson.core.JsonParser;
-import com.fasterxml.jackson.core.JsonToken;
-import com.fasterxml.jackson.databind.JsonNode;
-import com.fasterxml.jackson.databind.MappingJsonFactory;
-import com.fasterxml.jackson.databind.node.ArrayNode;
-import com.fasterxml.jackson.databind.node.ObjectNode;
-import java.io.InputStream;
-import java.util.Collection;
-import java.util.Iterator;
-import java.util.Map;
-import java.util.function.Function;
-import org.apache.polygene.api.structure.ModuleDescriptor;
-import org.apache.polygene.api.type.ValueType;
-import org.apache.polygene.api.value.ValueSerializationException;
-import org.apache.polygene.spi.value.ValueDeserializerAdapter;
-
-/**
- * ValueDeserializer reading Values from JSON documents using Jackson.
- */
-public class JacksonValueDeserializer
- extends ValueDeserializerAdapter<JsonParser, JsonNode>
-{
-
- private final JsonFactory jsonFactory = new MappingJsonFactory();
-
- @Override
- protected JsonParser adaptInput( ModuleDescriptor module, InputStream input )
- throws Exception
- {
- return jsonFactory.createParser( input );
- }
-
- @Override
- protected void onDeserializationEnd( ModuleDescriptor module, ValueType valueType, JsonParser input )
- throws Exception
- {
- input.close();
- }
-
- @Override
- protected Object readPlainValue( ModuleDescriptor module, JsonParser input )
- throws Exception
- {
- JsonNode jsonNode = input.readValueAsTree();
- if( jsonNode.isArray() || jsonNode.isObject() )
- {
- throw new ValueSerializationException( "Asked for a Value but found an Object or an Array at "
- + input.getCurrentLocation().toString() );
- }
- if( jsonNode.isDouble() )
- {
- return jsonNode.asDouble();
- }
- if( jsonNode.isLong() )
- {
- return jsonNode.asLong();
- }
- if( jsonNode.isInt() )
- {
- return jsonNode.asInt();
- }
- if( jsonNode.isBoolean() )
- {
- return jsonNode.asBoolean();
- }
- if( jsonNode.isNull() )
- {
- return null;
- }
- return jsonNode.asText();
- }
-
- @Override
- protected <T> Collection<T> readArrayInCollection( ModuleDescriptor module,
- JsonParser input,
- Function<JsonParser, T> deserializer,
- Collection<T> collection
- )
- throws Exception
- {
- JsonToken token = input.getCurrentToken();
- if( token == JsonToken.VALUE_NULL )
- {
- return null;
- }
- if( token != JsonToken.START_ARRAY )
- {
- token = input.nextToken();
- }
- if( token == JsonToken.VALUE_NULL )
- {
- return null;
- }
- if( token != JsonToken.START_ARRAY )
- {
- throw new ValueSerializationException( "Expected an array start at "
- + input.getCurrentLocation().toString() );
- }
- while( input.nextToken() != JsonToken.END_ARRAY )
- {
- T element = deserializer.apply( input );
- collection.add( element );
- }
- return collection;
- }
-
- @Override
- protected <K, V> Map<K, V> readMapInMap( ModuleDescriptor module,
- JsonParser input,
- Function<JsonParser, K> keyDeserializer,
- Function<JsonParser, V> valueDeserializer,
- Map<K, V> map
- )
- throws Exception
- {
- JsonToken token = input.getCurrentToken();
- if( token == JsonToken.VALUE_NULL )
- {
- return null;
- }
- if( token != JsonToken.START_ARRAY )
- {
- token = input.nextToken();
- }
- if( token == JsonToken.VALUE_NULL )
- {
- return null;
- }
- if( token != JsonToken.START_ARRAY )
- {
- throw new ValueSerializationException( "Expected an array start at "
- + input.getCurrentLocation().toString() );
- }
- JsonToken currentToken = input.nextToken();
- while( currentToken != JsonToken.END_ARRAY )
- {
- if( currentToken != JsonToken.START_OBJECT )
- {
- throw new ValueSerializationException( "Expected an object start at "
- + input.getCurrentLocation().toString() );
- }
- currentToken = input.nextToken();
- K key = null;
- V value = null;
- while( currentToken != JsonToken.END_OBJECT )
- {
- String objectKey = input.getCurrentName();
- input.nextToken();
- if( "key".equals( objectKey ) )
- {
- key = keyDeserializer.apply( input );
- }
- else if( "value".equals( objectKey ) )
- {
- value = valueDeserializer.apply( input );
- }
- else
- {
- //input.nextToken();
- input.skipChildren();
- }
- currentToken = input.nextToken();
- }
- if( key != null )
- {
- map.put( key, value );
- }
- currentToken = input.nextToken();
- }
- return map;
- }
-
- @Override
- protected ObjectNode readObjectTree( ModuleDescriptor module, JsonParser input )
- throws Exception
- {
- JsonToken token = input.getCurrentToken();
- if( token == JsonToken.VALUE_NULL )
- {
- return null;
- }
- if( token != JsonToken.START_OBJECT )
- {
- token = input.nextToken();
- }
- if( token != JsonToken.START_OBJECT )
- {
- String message = "Expected an object start at " + input.getCurrentLocation().toString();
- throw new ValueSerializationException( message );
- }
- return (ObjectNode) input.readValueAsTree();
- }
-
- @Override
- protected Object asSimpleValue( ModuleDescriptor module, JsonNode inputNode )
- throws Exception
- {
- if( isNullOrMissing( inputNode ) )
- {
- return null;
- }
- if( !inputNode.isValueNode() )
- {
- throw new ValueSerializationException( "Expected a value node but got a container node " + inputNode );
- }
- if( inputNode.isDouble() )
- {
- return inputNode.asDouble();
- }
- if( inputNode.isLong() )
- {
- return inputNode.asLong();
- }
- if( inputNode.isInt() )
- {
- return inputNode.asInt();
- }
- if( inputNode.isBoolean() )
- {
- return inputNode.asBoolean();
- }
- return inputNode.asText();
- }
-
- @Override
- @SuppressWarnings( "SimplifiableIfStatement" )
- protected boolean isObjectValue( ModuleDescriptor module, JsonNode inputNode )
- throws Exception
- {
- if( isNullOrMissing( inputNode ) )
- {
- return false;
- }
- return inputNode.isObject();
- }
-
- @Override
- protected boolean objectHasField( ModuleDescriptor module, JsonNode inputNode, String key )
- throws Exception
- {
- if( isNullOrMissing( inputNode ) )
- {
- return false;
- }
- if( !inputNode.isObject() )
- {
- throw new ValueSerializationException( "Expected an object but got " + inputNode );
- }
- return inputNode.has( key );
- }
-
- @Override
- protected <T> T getObjectFieldValue( ModuleDescriptor module,
- JsonNode inputNode,
- String key,
- Function<JsonNode, T> valueDeserializer
- )
- throws Exception
- {
- JsonNode valueNode = inputNode.get( key );
- if( isNullOrMissing( valueNode ) )
- {
- return null;
- }
- return valueDeserializer.apply( valueNode );
- }
-
- @Override
- protected <T> void putArrayNodeInCollection( ModuleDescriptor module,
- JsonNode inputNode,
- Function<JsonNode, T> deserializer,
- Collection<T> collection
- )
- throws Exception
- {
- if( isNullOrMissing( inputNode ) )
- {
- return;
- }
- if( !inputNode.isArray() )
- {
- throw new ValueSerializationException( "Expected an array but got " + inputNode );
- }
- ArrayNode array = (ArrayNode) inputNode;
- for( JsonNode item : array )
- {
- T value = deserializer.apply( item );
- collection.add( value );
- }
- }
-
- @Override
- protected <K, V> void putArrayNodeInMap( ModuleDescriptor module,
- JsonNode inputNode,
- Function<JsonNode, K> keyDeserializer,
- Function<JsonNode, V> valueDeserializer,
- Map<K, V> map
- )
- throws Exception
- {
- if( isNullOrMissing( inputNode ) )
- {
- return;
- }
- if( !inputNode.isArray() )
- {
- throw new ValueSerializationException( "Expected an array but got " + inputNode );
- }
- ArrayNode array = (ArrayNode) inputNode;
- for( JsonNode item : array )
- {
- if( !item.isObject() )
- {
- throw new ValueSerializationException( "Expected an object but got " + inputNode );
- }
- JsonNode keyNode = item.get( "key" );
- JsonNode valueNode = item.get( "value" );
- K key = keyDeserializer.apply( keyNode );
- V value = valueDeserializer.apply( valueNode );
- if( key != null )
- {
- map.put( key, value );
- }
- }
- }
-
- @Override
- protected <V> void putObjectNodeInMap( ModuleDescriptor module,
- JsonNode inputNode,
- Function<JsonNode, V> valueDeserializer,
- Map<String, V> map
- )
- throws Exception
- {
- if( isNullOrMissing( inputNode ) )
- {
- return;
- }
- if( !inputNode.isObject() )
- {
- throw new ValueSerializationException( "Expected an object but got " + inputNode );
- }
- ObjectNode object = (ObjectNode) inputNode;
- Iterator<Map.Entry<String, JsonNode>> fields = object.fields();
- while( fields.hasNext() )
- {
- Map.Entry<String, JsonNode> entry = fields.next();
- V value = valueDeserializer.apply( entry.getValue() );
- map.put( entry.getKey(), value );
- }
- }
-
- private static boolean isNullOrMissing( JsonNode inputNode )
- {
- return inputNode == null || inputNode.isNull() || inputNode.isMissingNode();
- }
-}
http://git-wip-us.apache.org/repos/asf/polygene-java/blob/c9dd7229/extensions/valueserialization-jackson/src/main/java/org/apache/polygene/valueserialization/jackson/JacksonValueSerializationService.java
----------------------------------------------------------------------
diff --git a/extensions/valueserialization-jackson/src/main/java/org/apache/polygene/valueserialization/jackson/JacksonValueSerializationService.java b/extensions/valueserialization-jackson/src/main/java/org/apache/polygene/valueserialization/jackson/JacksonValueSerializationService.java
deleted file mode 100644
index b05c7d9..0000000
--- a/extensions/valueserialization-jackson/src/main/java/org/apache/polygene/valueserialization/jackson/JacksonValueSerializationService.java
+++ /dev/null
@@ -1,32 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF 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 org.apache.polygene.valueserialization.jackson;
-
-import org.apache.polygene.api.mixin.Mixins;
-import org.apache.polygene.api.value.ValueSerialization;
-
-/**
- * ValueSerialization Service producing and consuming JSON documents using Jackson.
- */
-@Mixins( { JacksonValueSerializer.class, JacksonValueDeserializer.class } )
-public interface JacksonValueSerializationService
- extends ValueSerialization
-{
-}
http://git-wip-us.apache.org/repos/asf/polygene-java/blob/c9dd7229/extensions/valueserialization-jackson/src/main/java/org/apache/polygene/valueserialization/jackson/JacksonValueSerializer.java
----------------------------------------------------------------------
diff --git a/extensions/valueserialization-jackson/src/main/java/org/apache/polygene/valueserialization/jackson/JacksonValueSerializer.java b/extensions/valueserialization-jackson/src/main/java/org/apache/polygene/valueserialization/jackson/JacksonValueSerializer.java
deleted file mode 100644
index a52b030..0000000
--- a/extensions/valueserialization-jackson/src/main/java/org/apache/polygene/valueserialization/jackson/JacksonValueSerializer.java
+++ /dev/null
@@ -1,92 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF 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 org.apache.polygene.valueserialization.jackson;
-
-import com.fasterxml.jackson.core.JsonFactory;
-import com.fasterxml.jackson.core.JsonGenerator;
-import com.fasterxml.jackson.databind.MappingJsonFactory;
-import java.io.OutputStream;
-import org.apache.polygene.spi.value.ValueSerializerAdapter;
-
-/**
- * ValueSerializer producing Values state as JSON documents using Jackson.
- */
-public class JacksonValueSerializer
- extends ValueSerializerAdapter<JsonGenerator>
-{
-
- private final JsonFactory jsonFactory = new MappingJsonFactory();
-
- @Override
- protected JsonGenerator adaptOutput( OutputStream output )
- throws Exception
- {
- return jsonFactory.createGenerator( output );
- }
-
- @Override
- protected void onSerializationEnd( Object object, JsonGenerator output )
- throws Exception
- {
- output.close();
- }
-
- @Override
- protected void onArrayStart( JsonGenerator output )
- throws Exception
- {
- output.writeStartArray();
- }
-
- @Override
- protected void onArrayEnd( JsonGenerator output )
- throws Exception
- {
- output.writeEndArray();
- }
-
- @Override
- protected void onObjectStart( JsonGenerator output )
- throws Exception
- {
- output.writeStartObject();
- }
-
- @Override
- protected void onObjectEnd( JsonGenerator output )
- throws Exception
- {
- output.writeEndObject();
- }
-
- @Override
- protected void onFieldStart( JsonGenerator output, String fieldName )
- throws Exception
- {
- output.writeFieldName( fieldName );
- }
-
- @Override
- protected void onValue( JsonGenerator output, Object value )
- throws Exception
- {
- output.writeObject( value );
- }
-}
http://git-wip-us.apache.org/repos/asf/polygene-java/blob/c9dd7229/extensions/valueserialization-jackson/src/main/java/org/apache/polygene/valueserialization/jackson/assembly/JacksonValueSerializationAssembler.java
----------------------------------------------------------------------
diff --git a/extensions/valueserialization-jackson/src/main/java/org/apache/polygene/valueserialization/jackson/assembly/JacksonValueSerializationAssembler.java b/extensions/valueserialization-jackson/src/main/java/org/apache/polygene/valueserialization/jackson/assembly/JacksonValueSerializationAssembler.java
deleted file mode 100644
index 7bff000..0000000
--- a/extensions/valueserialization-jackson/src/main/java/org/apache/polygene/valueserialization/jackson/assembly/JacksonValueSerializationAssembler.java
+++ /dev/null
@@ -1,42 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF 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 org.apache.polygene.valueserialization.jackson.assembly;
-
-import org.apache.polygene.api.value.ValueSerialization;
-import org.apache.polygene.bootstrap.Assemblers;
-import org.apache.polygene.bootstrap.AssemblyException;
-import org.apache.polygene.bootstrap.ModuleAssembly;
-import org.apache.polygene.valueserialization.jackson.JacksonValueSerializationService;
-
-/**
- * Assemble a ValueSerialization Service producing and consuming JSON documents.
- */
-public class JacksonValueSerializationAssembler
- extends Assemblers.Visibility<JacksonValueSerializationAssembler>
-{
- @Override
- public void assemble( ModuleAssembly module )
- throws AssemblyException
- {
- module.services( JacksonValueSerializationService.class )
- .visibleIn( visibility() )
- .taggedWith( ValueSerialization.Formats.JSON );
- }
-}
http://git-wip-us.apache.org/repos/asf/polygene-java/blob/c9dd7229/extensions/valueserialization-jackson/src/main/java/org/apache/polygene/valueserialization/jackson/package.html
----------------------------------------------------------------------
diff --git a/extensions/valueserialization-jackson/src/main/java/org/apache/polygene/valueserialization/jackson/package.html b/extensions/valueserialization-jackson/src/main/java/org/apache/polygene/valueserialization/jackson/package.html
deleted file mode 100644
index d229040..0000000
--- a/extensions/valueserialization-jackson/src/main/java/org/apache/polygene/valueserialization/jackson/package.html
+++ /dev/null
@@ -1,24 +0,0 @@
-<!--
- ~ Licensed to the Apache Software Foundation (ASF) under one
- ~ or more contributor license agreements. See the NOTICE file
- ~ distributed with this work for additional information
- ~ regarding copyright ownership. The ASF 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.
- ~
- ~
- -->
-<html>
- <body>
- <h2>Jackson Value Serializer.</h2>
- </body>
-</html>
http://git-wip-us.apache.org/repos/asf/polygene-java/blob/c9dd7229/extensions/valueserialization-jackson/src/test/java/org/apache/polygene/valueserialization/jackson/JacksonCollectionSerializationTest.java
----------------------------------------------------------------------
diff --git a/extensions/valueserialization-jackson/src/test/java/org/apache/polygene/valueserialization/jackson/JacksonCollectionSerializationTest.java b/extensions/valueserialization-jackson/src/test/java/org/apache/polygene/valueserialization/jackson/JacksonCollectionSerializationTest.java
deleted file mode 100644
index f4069c3..0000000
--- a/extensions/valueserialization-jackson/src/test/java/org/apache/polygene/valueserialization/jackson/JacksonCollectionSerializationTest.java
+++ /dev/null
@@ -1,38 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF 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 org.apache.polygene.valueserialization.jackson;
-
-import org.apache.polygene.bootstrap.AssemblyException;
-import org.apache.polygene.bootstrap.ModuleAssembly;
-import org.apache.polygene.test.value.AbstractCollectionSerializationTest;
-import org.apache.polygene.valueserialization.jackson.assembly.JacksonValueSerializationAssembler;
-
-public class JacksonCollectionSerializationTest
- extends AbstractCollectionSerializationTest
-{
-
- @Override
- public void assemble( ModuleAssembly module )
- throws AssemblyException
- {
- super.assemble( module );
- new JacksonValueSerializationAssembler().assemble( module );
- }
-}
http://git-wip-us.apache.org/repos/asf/polygene-java/blob/c9dd7229/extensions/valueserialization-jackson/src/test/java/org/apache/polygene/valueserialization/jackson/JacksonConfigurationDeserializationTest.java
----------------------------------------------------------------------
diff --git a/extensions/valueserialization-jackson/src/test/java/org/apache/polygene/valueserialization/jackson/JacksonConfigurationDeserializationTest.java b/extensions/valueserialization-jackson/src/test/java/org/apache/polygene/valueserialization/jackson/JacksonConfigurationDeserializationTest.java
deleted file mode 100644
index 1948d62..0000000
--- a/extensions/valueserialization-jackson/src/test/java/org/apache/polygene/valueserialization/jackson/JacksonConfigurationDeserializationTest.java
+++ /dev/null
@@ -1,39 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF 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 org.apache.polygene.valueserialization.jackson;
-
-import org.apache.polygene.bootstrap.AssemblyException;
-import org.apache.polygene.bootstrap.ModuleAssembly;
-import org.apache.polygene.test.entity.AbstractConfigurationDeserializationTest;
-import org.apache.polygene.valueserialization.jackson.assembly.JacksonValueSerializationAssembler;
-
-public class JacksonConfigurationDeserializationTest
- extends AbstractConfigurationDeserializationTest
-{
- @Override
- public void assemble( final ModuleAssembly module )
- throws AssemblyException
- {
- super.assemble( module );
- new JacksonValueSerializationAssembler()
- .assemble( module );
- }
-}
http://git-wip-us.apache.org/repos/asf/polygene-java/blob/c9dd7229/extensions/valueserialization-jackson/src/test/java/org/apache/polygene/valueserialization/jackson/JacksonJsonDateFormatTest.java
----------------------------------------------------------------------
diff --git a/extensions/valueserialization-jackson/src/test/java/org/apache/polygene/valueserialization/jackson/JacksonJsonDateFormatTest.java b/extensions/valueserialization-jackson/src/test/java/org/apache/polygene/valueserialization/jackson/JacksonJsonDateFormatTest.java
deleted file mode 100644
index bbc141d..0000000
--- a/extensions/valueserialization-jackson/src/test/java/org/apache/polygene/valueserialization/jackson/JacksonJsonDateFormatTest.java
+++ /dev/null
@@ -1,38 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF 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 org.apache.polygene.valueserialization.jackson;
-
-import org.apache.polygene.bootstrap.AssemblyException;
-import org.apache.polygene.bootstrap.ModuleAssembly;
-import org.apache.polygene.test.value.AbstractJsonDateFormatTest;
-import org.apache.polygene.valueserialization.jackson.assembly.JacksonValueSerializationAssembler;
-
-public class JacksonJsonDateFormatTest
- extends AbstractJsonDateFormatTest
-{
-
- @Override
- public void assemble( ModuleAssembly module )
- throws AssemblyException
- {
- super.assemble( module );
- new JacksonValueSerializationAssembler().assemble( module );
- }
-}
http://git-wip-us.apache.org/repos/asf/polygene-java/blob/c9dd7229/extensions/valueserialization-jackson/src/test/java/org/apache/polygene/valueserialization/jackson/JacksonPlainValueSerializationTest.java
----------------------------------------------------------------------
diff --git a/extensions/valueserialization-jackson/src/test/java/org/apache/polygene/valueserialization/jackson/JacksonPlainValueSerializationTest.java b/extensions/valueserialization-jackson/src/test/java/org/apache/polygene/valueserialization/jackson/JacksonPlainValueSerializationTest.java
deleted file mode 100644
index cdcce17..0000000
--- a/extensions/valueserialization-jackson/src/test/java/org/apache/polygene/valueserialization/jackson/JacksonPlainValueSerializationTest.java
+++ /dev/null
@@ -1,36 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF 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 org.apache.polygene.valueserialization.jackson;
-
-import org.apache.polygene.bootstrap.ModuleAssembly;
-import org.apache.polygene.test.value.AbstractPlainValueSerializationTest;
-import org.apache.polygene.valueserialization.jackson.assembly.JacksonValueSerializationAssembler;
-
-public class JacksonPlainValueSerializationTest
- extends AbstractPlainValueSerializationTest
-{
- // START SNIPPET: assembly
- @Override
- public void assemble( ModuleAssembly module )
- {
- new JacksonValueSerializationAssembler().assemble( module );
- }
- // END SNIPPET: assembly
-}
http://git-wip-us.apache.org/repos/asf/polygene-java/blob/c9dd7229/extensions/valueserialization-jackson/src/test/java/org/apache/polygene/valueserialization/jackson/JacksonValueCompositeSerializationTest.java
----------------------------------------------------------------------
diff --git a/extensions/valueserialization-jackson/src/test/java/org/apache/polygene/valueserialization/jackson/JacksonValueCompositeSerializationTest.java b/extensions/valueserialization-jackson/src/test/java/org/apache/polygene/valueserialization/jackson/JacksonValueCompositeSerializationTest.java
deleted file mode 100644
index 2a757ab..0000000
--- a/extensions/valueserialization-jackson/src/test/java/org/apache/polygene/valueserialization/jackson/JacksonValueCompositeSerializationTest.java
+++ /dev/null
@@ -1,38 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF 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 org.apache.polygene.valueserialization.jackson;
-
-import org.apache.polygene.bootstrap.AssemblyException;
-import org.apache.polygene.bootstrap.ModuleAssembly;
-import org.apache.polygene.test.value.AbstractValueCompositeSerializationTest;
-import org.apache.polygene.valueserialization.jackson.assembly.JacksonValueSerializationAssembler;
-
-public class JacksonValueCompositeSerializationTest
- extends AbstractValueCompositeSerializationTest
-{
-
- @Override
- public void assemble( ModuleAssembly module )
- throws AssemblyException
- {
- super.assemble( module );
- new JacksonValueSerializationAssembler().assemble( module );
- }
-}
http://git-wip-us.apache.org/repos/asf/polygene-java/blob/c9dd7229/extensions/valueserialization-jackson/src/test/resources/configtest.json
----------------------------------------------------------------------
diff --git a/extensions/valueserialization-jackson/src/test/resources/configtest.json b/extensions/valueserialization-jackson/src/test/resources/configtest.json
deleted file mode 100644
index d48a241..0000000
--- a/extensions/valueserialization-jackson/src/test/resources/configtest.json
+++ /dev/null
@@ -1,8 +0,0 @@
-{
- "identity" : "configtest",
- "host": {
- "ip": "12.23.34.45",
- "port": 1234
- },
- "name": "main"
-}
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/polygene-java/blob/c9dd7229/extensions/valueserialization-orgjson/build.gradle
----------------------------------------------------------------------
diff --git a/extensions/valueserialization-orgjson/build.gradle b/extensions/valueserialization-orgjson/build.gradle
deleted file mode 100644
index 5431ec5..0000000
--- a/extensions/valueserialization-orgjson/build.gradle
+++ /dev/null
@@ -1,35 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF 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.
- *
- *
- */
-
-apply plugin: 'polygene-extension'
-
-description = "Apache Polygene\u2122 org.json ValueSerialization Extension"
-
-jar { manifest { name = "Apache Polygene\u2122 Extension - ValueSerialization - org.json" } }
-
-dependencies {
- api polygene.core.bootstrap
-
- runtimeOnly polygene.core.runtime
-
- testImplementation polygene.core.testsupport
-
- testRuntimeOnly libraries.logback
-}
http://git-wip-us.apache.org/repos/asf/polygene-java/blob/c9dd7229/extensions/valueserialization-orgjson/dev-status.xml
----------------------------------------------------------------------
diff --git a/extensions/valueserialization-orgjson/dev-status.xml b/extensions/valueserialization-orgjson/dev-status.xml
deleted file mode 100644
index dbb4472..0000000
--- a/extensions/valueserialization-orgjson/dev-status.xml
+++ /dev/null
@@ -1,36 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!--
- ~ Licensed to the Apache Software Foundation (ASF) under one
- ~ or more contributor license agreements. See the NOTICE file
- ~ distributed with this work for additional information
- ~ regarding copyright ownership. The ASF 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.
- ~
- ~
- -->
-<module xmlns="http://polygene.apache.org/schemas/2008/dev-status/1"
- xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:schemaLocation="http://polygene.apache.org/schemas/2008/dev-status/1
- http://polygene.apache.org/schemas/2008/dev-status/1/dev-status.xsd">
- <status>
- <codebase>stable</codebase>
- <!--none,early,beta,stable,mature-->
- <documentation>good</documentation>
- <!-- none, brief, good, complete -->
- <unittests>complete</unittests>
- <!-- none, some, good, complete -->
- </status>
- <licenses>
- <license>ALv2</license>
- </licenses>
-</module>
http://git-wip-us.apache.org/repos/asf/polygene-java/blob/c9dd7229/extensions/valueserialization-orgjson/src/docs/vs-orgjson.txt
----------------------------------------------------------------------
diff --git a/extensions/valueserialization-orgjson/src/docs/vs-orgjson.txt b/extensions/valueserialization-orgjson/src/docs/vs-orgjson.txt
deleted file mode 100644
index bbf50f7..0000000
--- a/extensions/valueserialization-orgjson/src/docs/vs-orgjson.txt
+++ /dev/null
@@ -1,43 +0,0 @@
-///////////////////////////////////////////////////////////////
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF 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.
-///////////////////////////////////////////////////////////////
-
-[[extension-vs-orgjson, org.json ValueSerialization]]
-= org.json ValueSerialization =
-
-[devstatus]
---------------
-source=extensions/valueserialization-orgjson/dev-status.xml
---------------
-
-ValueSerialization Service backed by https://github.com/douglascrockford/JSON-java[org.json].
-
-include::../../build/docs/buildinfo/artifact.txt[]
-
-== Assembly ==
-
-Assembly is done as follows:
-
-[snippet,java]
-----
-source=extensions/valueserialization-orgjson/src/test/java/org/apache/polygene/valueserialization/orgjson/OrgJsonPlainValueSerializationTest.java
-tag=assembly
-----
-
-See the ValueSerialization <<core-api-value,API>> and <<core-spi-valueserialization,SPI>> documentation for details and
-usage.
http://git-wip-us.apache.org/repos/asf/polygene-java/blob/c9dd7229/extensions/valueserialization-orgjson/src/main/java/org/apache/polygene/valueserialization/orgjson/OrgJsonValueSerializationAssembler.java
----------------------------------------------------------------------
diff --git a/extensions/valueserialization-orgjson/src/main/java/org/apache/polygene/valueserialization/orgjson/OrgJsonValueSerializationAssembler.java b/extensions/valueserialization-orgjson/src/main/java/org/apache/polygene/valueserialization/orgjson/OrgJsonValueSerializationAssembler.java
deleted file mode 100644
index 07e5151..0000000
--- a/extensions/valueserialization-orgjson/src/main/java/org/apache/polygene/valueserialization/orgjson/OrgJsonValueSerializationAssembler.java
+++ /dev/null
@@ -1,41 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF 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 org.apache.polygene.valueserialization.orgjson;
-
-import org.apache.polygene.api.value.ValueSerialization;
-import org.apache.polygene.bootstrap.Assemblers;
-import org.apache.polygene.bootstrap.AssemblyException;
-import org.apache.polygene.bootstrap.ModuleAssembly;
-
-/**
- * Assemble a ValueSerialization Service producing and consuming JSON documents.
- */
-public class OrgJsonValueSerializationAssembler
- extends Assemblers.Visibility<OrgJsonValueSerializationAssembler>
-{
- @Override
- public void assemble( ModuleAssembly module )
- throws AssemblyException
- {
- module.services( OrgJsonValueSerializationService.class ).
- visibleIn( visibility() ).
- taggedWith( ValueSerialization.Formats.JSON );
- }
-}
http://git-wip-us.apache.org/repos/asf/polygene-java/blob/c9dd7229/extensions/valueserialization-orgjson/src/main/java/org/apache/polygene/valueserialization/orgjson/package.html
----------------------------------------------------------------------
diff --git a/extensions/valueserialization-orgjson/src/main/java/org/apache/polygene/valueserialization/orgjson/package.html b/extensions/valueserialization-orgjson/src/main/java/org/apache/polygene/valueserialization/orgjson/package.html
deleted file mode 100644
index 4799b58..0000000
--- a/extensions/valueserialization-orgjson/src/main/java/org/apache/polygene/valueserialization/orgjson/package.html
+++ /dev/null
@@ -1,24 +0,0 @@
-<!--
- ~ Licensed to the Apache Software Foundation (ASF) under one
- ~ or more contributor license agreements. See the NOTICE file
- ~ distributed with this work for additional information
- ~ regarding copyright ownership. The ASF 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.
- ~
- ~
- -->
-<html>
- <body>
- <h2>org.json Value Serialization.</h2>
- </body>
-</html>
http://git-wip-us.apache.org/repos/asf/polygene-java/blob/c9dd7229/extensions/valueserialization-orgjson/src/test/java/org/apache/polygene/valueserialization/orgjson/OrgJsonCollectionSerializationTest.java
----------------------------------------------------------------------
diff --git a/extensions/valueserialization-orgjson/src/test/java/org/apache/polygene/valueserialization/orgjson/OrgJsonCollectionSerializationTest.java b/extensions/valueserialization-orgjson/src/test/java/org/apache/polygene/valueserialization/orgjson/OrgJsonCollectionSerializationTest.java
deleted file mode 100644
index a109c5f..0000000
--- a/extensions/valueserialization-orgjson/src/test/java/org/apache/polygene/valueserialization/orgjson/OrgJsonCollectionSerializationTest.java
+++ /dev/null
@@ -1,37 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF 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 org.apache.polygene.valueserialization.orgjson;
-
-import org.apache.polygene.bootstrap.AssemblyException;
-import org.apache.polygene.bootstrap.ModuleAssembly;
-import org.apache.polygene.test.value.AbstractCollectionSerializationTest;
-
-public class OrgJsonCollectionSerializationTest
- extends AbstractCollectionSerializationTest
-{
-
- @Override
- public void assemble( ModuleAssembly module )
- throws AssemblyException
- {
- super.assemble( module );
- new OrgJsonValueSerializationAssembler().assemble( module );
- }
-}
http://git-wip-us.apache.org/repos/asf/polygene-java/blob/c9dd7229/extensions/valueserialization-orgjson/src/test/java/org/apache/polygene/valueserialization/orgjson/OrgJsonConfigurationDeserializationTest.java
----------------------------------------------------------------------
diff --git a/extensions/valueserialization-orgjson/src/test/java/org/apache/polygene/valueserialization/orgjson/OrgJsonConfigurationDeserializationTest.java b/extensions/valueserialization-orgjson/src/test/java/org/apache/polygene/valueserialization/orgjson/OrgJsonConfigurationDeserializationTest.java
deleted file mode 100644
index c22f58f..0000000
--- a/extensions/valueserialization-orgjson/src/test/java/org/apache/polygene/valueserialization/orgjson/OrgJsonConfigurationDeserializationTest.java
+++ /dev/null
@@ -1,38 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF 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 org.apache.polygene.valueserialization.orgjson;
-
-import org.apache.polygene.bootstrap.AssemblyException;
-import org.apache.polygene.bootstrap.ModuleAssembly;
-import org.apache.polygene.test.entity.AbstractConfigurationDeserializationTest;
-
-public class OrgJsonConfigurationDeserializationTest
- extends AbstractConfigurationDeserializationTest
-{
- @Override
- public void assemble( final ModuleAssembly module )
- throws AssemblyException
- {
- super.assemble( module );
- new OrgJsonValueSerializationAssembler()
- .assemble( module );
- }
-}
http://git-wip-us.apache.org/repos/asf/polygene-java/blob/c9dd7229/extensions/valueserialization-orgjson/src/test/java/org/apache/polygene/valueserialization/orgjson/OrgJsonDateFormatTest.java
----------------------------------------------------------------------
diff --git a/extensions/valueserialization-orgjson/src/test/java/org/apache/polygene/valueserialization/orgjson/OrgJsonDateFormatTest.java b/extensions/valueserialization-orgjson/src/test/java/org/apache/polygene/valueserialization/orgjson/OrgJsonDateFormatTest.java
deleted file mode 100644
index 23695ff..0000000
--- a/extensions/valueserialization-orgjson/src/test/java/org/apache/polygene/valueserialization/orgjson/OrgJsonDateFormatTest.java
+++ /dev/null
@@ -1,37 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF 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 org.apache.polygene.valueserialization.orgjson;
-
-import org.apache.polygene.bootstrap.AssemblyException;
-import org.apache.polygene.bootstrap.ModuleAssembly;
-import org.apache.polygene.test.value.AbstractJsonDateFormatTest;
-
-public class OrgJsonDateFormatTest
- extends AbstractJsonDateFormatTest
-{
-
- @Override
- public void assemble( ModuleAssembly module )
- throws AssemblyException
- {
- super.assemble( module );
- new OrgJsonValueSerializationAssembler().assemble( module );
- }
-}
http://git-wip-us.apache.org/repos/asf/polygene-java/blob/c9dd7229/extensions/valueserialization-orgjson/src/test/java/org/apache/polygene/valueserialization/orgjson/OrgJsonPlainValueSerializationTest.java
----------------------------------------------------------------------
diff --git a/extensions/valueserialization-orgjson/src/test/java/org/apache/polygene/valueserialization/orgjson/OrgJsonPlainValueSerializationTest.java b/extensions/valueserialization-orgjson/src/test/java/org/apache/polygene/valueserialization/orgjson/OrgJsonPlainValueSerializationTest.java
deleted file mode 100644
index ef1f928..0000000
--- a/extensions/valueserialization-orgjson/src/test/java/org/apache/polygene/valueserialization/orgjson/OrgJsonPlainValueSerializationTest.java
+++ /dev/null
@@ -1,35 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF 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 org.apache.polygene.valueserialization.orgjson;
-
-import org.apache.polygene.bootstrap.ModuleAssembly;
-import org.apache.polygene.test.value.AbstractPlainValueSerializationTest;
-
-public class OrgJsonPlainValueSerializationTest
- extends AbstractPlainValueSerializationTest
-{
- // START SNIPPET: assembly
- @Override
- public void assemble( ModuleAssembly module )
- {
- new OrgJsonValueSerializationAssembler().assemble( module );
- }
- // END SNIPPET: assembly
-}
http://git-wip-us.apache.org/repos/asf/polygene-java/blob/c9dd7229/extensions/valueserialization-orgjson/src/test/java/org/apache/polygene/valueserialization/orgjson/OrgJsonValueCompositeSerializationTest.java
----------------------------------------------------------------------
diff --git a/extensions/valueserialization-orgjson/src/test/java/org/apache/polygene/valueserialization/orgjson/OrgJsonValueCompositeSerializationTest.java b/extensions/valueserialization-orgjson/src/test/java/org/apache/polygene/valueserialization/orgjson/OrgJsonValueCompositeSerializationTest.java
deleted file mode 100644
index ca791a4..0000000
--- a/extensions/valueserialization-orgjson/src/test/java/org/apache/polygene/valueserialization/orgjson/OrgJsonValueCompositeSerializationTest.java
+++ /dev/null
@@ -1,37 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF 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 org.apache.polygene.valueserialization.orgjson;
-
-import org.apache.polygene.bootstrap.AssemblyException;
-import org.apache.polygene.bootstrap.ModuleAssembly;
-import org.apache.polygene.test.value.AbstractValueCompositeSerializationTest;
-
-public class OrgJsonValueCompositeSerializationTest
- extends AbstractValueCompositeSerializationTest
-{
-
- @Override
- public void assemble( ModuleAssembly module )
- throws AssemblyException
- {
- super.assemble( module );
- new OrgJsonValueSerializationAssembler().assemble( module );
- }
-}
http://git-wip-us.apache.org/repos/asf/polygene-java/blob/c9dd7229/extensions/valueserialization-orgjson/src/test/resources/configtest.json
----------------------------------------------------------------------
diff --git a/extensions/valueserialization-orgjson/src/test/resources/configtest.json b/extensions/valueserialization-orgjson/src/test/resources/configtest.json
deleted file mode 100644
index d48a241..0000000
--- a/extensions/valueserialization-orgjson/src/test/resources/configtest.json
+++ /dev/null
@@ -1,8 +0,0 @@
-{
- "identity" : "configtest",
- "host": {
- "ip": "12.23.34.45",
- "port": 1234
- },
- "name": "main"
-}
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/polygene-java/blob/c9dd7229/extensions/valueserialization-stax/build.gradle
----------------------------------------------------------------------
diff --git a/extensions/valueserialization-stax/build.gradle b/extensions/valueserialization-stax/build.gradle
deleted file mode 100644
index 83e6175..0000000
--- a/extensions/valueserialization-stax/build.gradle
+++ /dev/null
@@ -1,37 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF 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.
- *
- *
- */
-
-apply plugin: 'polygene-extension'
-
-description = "Apache Polygene\u2122 StaX ValueSerialization Extension"
-
-jar { manifest { name = "Apache Polygene\u2122 Extension - ValueSerialization - StaX" } }
-
-dependencies {
- api polygene.core.bootstrap
-
- implementation libraries.commons_lang
-
- runtimeOnly polygene.core.runtime
-
- testImplementation polygene.core.testsupport
-
- testRuntimeOnly libraries.logback
-}
http://git-wip-us.apache.org/repos/asf/polygene-java/blob/c9dd7229/extensions/valueserialization-stax/dev-status.xml
----------------------------------------------------------------------
diff --git a/extensions/valueserialization-stax/dev-status.xml b/extensions/valueserialization-stax/dev-status.xml
deleted file mode 100644
index 7fa50ff..0000000
--- a/extensions/valueserialization-stax/dev-status.xml
+++ /dev/null
@@ -1,36 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!--
- ~ Licensed to the Apache Software Foundation (ASF) under one
- ~ or more contributor license agreements. See the NOTICE file
- ~ distributed with this work for additional information
- ~ regarding copyright ownership. The ASF 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.
- ~
- ~
- -->
-<module xmlns="http://polygene.apache.org/schemas/2008/dev-status/1"
- xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:schemaLocation="http://polygene.apache.org/schemas/2008/dev-status/1
- http://polygene.apache.org/schemas/2008/dev-status/1/dev-status.xsd">
- <status>
- <codebase>beta</codebase>
- <!--none,early,beta,stable,mature-->
- <documentation>good</documentation>
- <!-- none, brief, good, complete -->
- <unittests>complete</unittests>
- <!-- none, some, good, complete -->
- </status>
- <licenses>
- <license>ALv2</license>
- </licenses>
-</module>
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/polygene-java/blob/c9dd7229/extensions/valueserialization-stax/src/docs/vs-stax.txt
----------------------------------------------------------------------
diff --git a/extensions/valueserialization-stax/src/docs/vs-stax.txt b/extensions/valueserialization-stax/src/docs/vs-stax.txt
deleted file mode 100644
index 416caf4..0000000
--- a/extensions/valueserialization-stax/src/docs/vs-stax.txt
+++ /dev/null
@@ -1,43 +0,0 @@
-///////////////////////////////////////////////////////////////
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF 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.
-///////////////////////////////////////////////////////////////
-
-[[extension-vs-stax, StAX ValueSerialization]]
-= StAX ValueSerialization =
-
-[devstatus]
---------------
-source=extensions/valueserialization-stax/dev-status.xml
---------------
-
-ValueSerialization Service backed by http://jcp.org/en/jsr/detail?id=173[StAX].
-
-include::../../build/docs/buildinfo/artifact.txt[]
-
-== Assembly ==
-
-Assembly is done as follows:
-
-[snippet,java]
-----
-source=extensions/valueserialization-stax/src/test/java/org/apache/polygene/valueserialization/stax/StaxPlainValueSerializationTest.java
-tag=assembly
-----
-
-See the ValueSerialization <<core-api-value,API>> and <<core-spi-valueserialization,SPI>> documentation for details and
-usage.