alvinalexander.com | career | drupal | java | mac | mysql | perl | scala | uml | unix  

Java example source code file (DatabindingConfig.java)

This example Java source code file (DatabindingConfig.java) is included in the alvinalexander.com "Java Source Code Warehouse" project. The intent of this project is to help you "Learn Java by Example" TM.

Learn more about this Java project at its project page.

Java - Java tags/keywords

class, classloader, entityresolver, iterable, map, mappinginfo, metadatareader, net, network, object, sax, set, source, url, util, webservicefeaturelist, wsbinding, wsdlport, xml

The DatabindingConfig.java Java example source code

/*
 * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved.
 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
 *
 * This code is free software; you can redistribute it and/or modify it
 * under the terms of the GNU General Public License version 2 only, as
 * published by the Free Software Foundation.  Oracle designates this
 * particular file as subject to the "Classpath" exception as provided
 * by Oracle in the LICENSE file that accompanied this code.
 *
 * This code is distributed in the hope that it will be useful, but WITHOUT
 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
 * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
 * version 2 for more details (a copy is included in the LICENSE file that
 * accompanied this code).
 *
 * You should have received a copy of the GNU General Public License version
 * 2 along with this work; if not, write to the Free Software Foundation,
 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
 *
 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
 * or visit www.oracle.com if you need additional information or have any
 * questions.
 */

package com.sun.xml.internal.ws.api.databinding;

import java.net.URL;
import java.util.HashMap;
import java.util.HashSet;
import java.util.Set;
import java.util.Map;

import javax.xml.transform.Source;
import javax.xml.ws.WebServiceFeature;

import org.xml.sax.EntityResolver;

import com.sun.xml.internal.ws.api.WSBinding;
import com.sun.xml.internal.ws.api.WSFeatureList;
import com.sun.xml.internal.ws.api.model.wsdl.WSDLPort;
import com.sun.xml.internal.ws.binding.WebServiceFeatureList;

/**
 * DatabindingConfig contains the initial states for Databinding. After a Databinding
 * instance is created, all it's internal states should be considered
 * 'immutable' and therefore the operations on Databinding are thread-safe.
 *
 * @author shih-chang.chen@oracle.com
 */
public class DatabindingConfig {
    protected Class contractClass;
        protected Class endpointClass;
        protected Set<Class> additionalValueTypes = new HashSet();
        protected MappingInfo mappingInfo = new MappingInfo();
        protected URL wsdlURL;
        protected ClassLoader classLoader;
        protected Iterable<WebServiceFeature> features;
        protected WSBinding wsBinding;
        protected WSDLPort wsdlPort;
        protected MetadataReader metadataReader;
        protected Map<String, Object> properties = new HashMap();
    protected Source wsdlSource;
    protected EntityResolver entityResolver;

        public Class getContractClass() {
                return contractClass;
        }
        public void setContractClass(Class contractClass) {
                this.contractClass = contractClass;
        }
        public Class getEndpointClass() {
                return endpointClass;
        }
        public void setEndpointClass(Class implBeanClass) {
                this.endpointClass = implBeanClass;
        }
        public MappingInfo getMappingInfo() {
                return mappingInfo;
        }
        public void setMappingInfo(MappingInfo mappingInfo) {
                this.mappingInfo = mappingInfo;
        }
        public URL getWsdlURL() {
                return wsdlURL;
        }
        public void setWsdlURL(URL wsdlURL) {
                this.wsdlURL = wsdlURL;
        }
        public ClassLoader getClassLoader() {
                return classLoader;
        }
        public void setClassLoader(ClassLoader classLoader) {
                this.classLoader = classLoader;
        }
        public Iterable<WebServiceFeature> getFeatures() {
            if (features == null && wsBinding != null) return wsBinding.getFeatures();
                return features;
        }
        public void setFeatures(WebServiceFeature[] features) {
                setFeatures(new WebServiceFeatureList(features));
        }
        public void setFeatures(Iterable<WebServiceFeature> features) {
                this.features = WebServiceFeatureList.toList(features);
        }
        public WSDLPort getWsdlPort() {
                return wsdlPort;
        }
        public void setWsdlPort(WSDLPort wsdlPort) {
                this.wsdlPort = wsdlPort;
        }
        public Set<Class> additionalValueTypes() {
                return additionalValueTypes;
        }
        public Map<String, Object> properties() {
                return properties;
        }
        public WSBinding getWSBinding() {
                return wsBinding;
        }
        public void setWSBinding(WSBinding wsBinding) {
                this.wsBinding = wsBinding;
        }
        public MetadataReader getMetadataReader() {
                return metadataReader;
        }
        public void setMetadataReader(MetadataReader  reader) {
                this.metadataReader = reader;
        }

    public Source getWsdlSource() {
        return wsdlSource;
    }
    public void setWsdlSource(Source wsdlSource) {
        this.wsdlSource = wsdlSource;
    }
    public EntityResolver getEntityResolver() {
        return entityResolver;
    }
    public void setEntityResolver(EntityResolver entityResolver) {
        this.entityResolver = entityResolver;
    }
}

Other Java examples (source code examples)

Here is a short list of links related to this Java DatabindingConfig.java source code file:

... this post is sponsored by my books ...

#1 New Release!

FP Best Seller

 

new blog posts

 

Copyright 1998-2021 Alvin Alexander, alvinalexander.com
All Rights Reserved.

A percentage of advertising revenue from
pages under the /java/jwarehouse URI on this website is
paid back to open source projects.