You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@felix.apache.org by da...@apache.org on 2016/07/01 16:04:56 UTC

svn commit: r1750973 - in /felix/trunk/converter/src/main/java/org/osgi/service/converter/util: ./ ConverterFactory.java

Author: davidb
Date: Fri Jul  1 16:04:56 2016
New Revision: 1750973

URL: http://svn.apache.org/viewvc?rev=1750973&view=rev
Log:
Felix Converter Service - add static factory.

Added:
    felix/trunk/converter/src/main/java/org/osgi/service/converter/util/
    felix/trunk/converter/src/main/java/org/osgi/service/converter/util/ConverterFactory.java

Added: felix/trunk/converter/src/main/java/org/osgi/service/converter/util/ConverterFactory.java
URL: http://svn.apache.org/viewvc/felix/trunk/converter/src/main/java/org/osgi/service/converter/util/ConverterFactory.java?rev=1750973&view=auto
==============================================================================
--- felix/trunk/converter/src/main/java/org/osgi/service/converter/util/ConverterFactory.java (added)
+++ felix/trunk/converter/src/main/java/org/osgi/service/converter/util/ConverterFactory.java Fri Jul  1 16:04:56 2016
@@ -0,0 +1,36 @@
+/*
+ * Copyright (c) OSGi Alliance (2015, 2016). All Rights Reserved.
+ *
+ * Licensed 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.osgi.service.converter.util;
+
+import org.apache.felix.converter.impl.ConverterService;
+import org.osgi.service.converter.Converter;
+
+/**
+ * Static factory class for obtaining a converter. A converter is normally
+ * obtained from the Service Registry.
+ */
+public class ConverterFactory {
+	/**
+	 * Return the standard converter
+	 *
+	 * @return The converter.
+	 */
+	Converter standardConverter() {
+        // Implementations must replace this class to return the actual
+        // implementation.
+	    return new ConverterService();
+	}
+}