Commit 6de12c17 authored by etj's avatar etj
Browse files

GeoFence: add custom XStreamPersisterInitializer

parent 7ba3121b
/* (c) 2015 Open Source Geospatial Foundation - all rights reserved
* (c) 2015 OpenPlans
* This code is licensed under the GPL 2.0 license, available at the root
* application directory.
*/
package org.geoserver.geoserver.authentication;
import com.thoughtworks.xstream.XStream;
import org.geoserver.config.util.XStreamPersister;
import org.geoserver.config.util.XStreamPersisterInitializer;
import org.geoserver.geoserver.authentication.auth.GeoFenceAuthenticationProviderConfig;
/**
*
* @author ETj (etj at geo-solutions.it)
*/
public class GeoFenceXStreamPersisterInitializer implements XStreamPersisterInitializer {
@Override
public void init(XStreamPersister persister) {
XStream xs = persister.getXStream();
xs.alias("geoFenceAuthenticationProviderConfig", GeoFenceAuthenticationProviderConfig.class);
xs.allowTypes(
new Class[]{GeoFenceAuthenticationProviderConfig.class});
}
}
......@@ -184,5 +184,7 @@
<property name="titleKey" value="GeoFenceAuthProviderPanel.title"/>
<property name="descriptionKey" value="GeoFenceAuthProviderPanel.description"/>
</bean>
<bean id="geoFenceXStreamInitializer" class="org.geoserver.geoserver.authentication.GeoFenceXStreamPersisterInitializer" lazy-init="false">
</bean>
</beans>
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment