Package org.geoserver.config

Examples of org.geoserver.config.ContactInfo


        info.setOnlineResource( get( global, "onlineResource", String.class ) );
        info.setProxyBaseUrl( get( global, "ProxyBaseUrl", String.class ) );
       
        //contact
        Map<String,Object> contact = reader.contact();
        ContactInfo contactInfo = factory.createContact();
      
        contactInfo.setContactPerson( (String) contact.get( "ContactPerson") );
        contactInfo.setContactOrganization( (String) contact.get( "ContactOrganization") );
        contactInfo.setContactVoice( (String) contact.get( "ContactVoiceTelephone" ) );
        contactInfo.setContactFacsimile( (String) contact.get( "ContactFacsimileTelephone" ) );
        contactInfo.setContactPosition( (String) contact.get( "ContactPosition" ) );
        contactInfo.setContactEmail( (String) contact.get( "ContactElectronicMailAddress" ) );
       
        contactInfo.setAddress( (String) contact.get( "Address") );
        contactInfo.setAddressType( (String) contact.get( "AddressType") );
        contactInfo.setAddressCity( (String) contact.get( "City") );
        contactInfo.setAddressCountry( (String) contact.get( "Country") );
        contactInfo.setAddressState( (String) contact.get( "StateOrProvince") );
        contactInfo.setAddressPostalCode( (String) contact.get( "PostCode") );
        info.setContact( contactInfo );
       
        //jai
        JAIInfo jai = new JAIInfoImpl();
        jai.setMemoryCapacity( (Double) value( global.get( "JaiMemoryCapacity"),JAIInfoImpl.DEFAULT_MemoryCapacity ) );
View Full Code Here


            return true;
        if (obj == null)
            return false;
        if (!(obj instanceof ContactInfo))
            return false;
        final ContactInfo other = (ContactInfo) obj;
        if (address == null) {
            if (other.getAddress() != null)
                return false;
        } else if (!address.equals(other.getAddress()))
            return false;
        if (addressCity == null) {
            if (other.getAddressCity() != null)
                return false;
        } else if (!addressCity.equals(other.getAddressCity()))
            return false;
        if (addressCountry == null) {
            if (other.getAddressCountry() != null)
                return false;
        } else if (!addressCountry.equals(other.getAddressCountry()))
            return false;
        if (addressPostalCode == null) {
            if (other.getAddressPostalCode() != null)
                return false;
        } else if (!addressPostalCode.equals(other.getAddressPostalCode()))
            return false;
        if (addressState == null) {
            if (other.getAddressState() != null)
                return false;
        } else if (!addressState.equals(other.getAddressState()))
            return false;
        if (addressType == null) {
            if (other.getAddressType() != null)
                return false;
        } else if (!addressType.equals(other.getAddressType()))
            return false;
        if (contactEmail == null) {
            if (other.getContactEmail() != null)
                return false;
        } else if (!contactEmail.equals(other.getContactEmail()))
            return false;
        if (contactFacsimile == null) {
            if (other.getContactFacsimile() != null)
                return false;
        } else if (!contactFacsimile.equals(other.getContactFacsimile()))
            return false;
        if (contactOrganization == null) {
            if (other.getContactOrganization() != null)
                return false;
        } else if (!contactOrganization.equals(other.getContactOrganization()))
            return false;
        if (contactPerson == null) {
            if (other.getContactPerson() != null)
                return false;
        } else if (!contactPerson.equals(other.getContactPerson()))
            return false;
        if (contactPosition == null) {
            if (other.getContactPosition() != null)
                return false;
        } else if (!contactPosition.equals(other.getContactPosition()))
            return false;
        if (contactVoice == null) {
            if (other.getContactVoice()!= null)
                return false;
        } else if (!contactVoice.equals(other.getContactVoice()))
            return false;
        if (onlineResource == null) {
            if (other.getOnlineResource() != null)
                return false;
        } else if (!onlineResource.equals(other.getOnlineResource()))
            return false;
        return true;
    }
View Full Code Here

        wmsInfo.getKeywords().add("k2");
        // @REVISIT: this is not being respected, but the onlineresource is being set based on the
        // proxyBaseUrl... not sure if that's correct
        wmsInfo.setOnlineResource("http://onlineresource/fake");

        ContactInfo contactInfo = new ContactInfoImpl();
        geosInfo.setContact(contactInfo);
        contactInfo.setContactPerson("contactPerson");
        contactInfo.setContactOrganization("contactOrganization");
        contactInfo.setContactPosition("contactPosition");
        contactInfo.setAddress("address");
        contactInfo.setAddressType("addressType");
        contactInfo.setAddressCity("city");
        contactInfo.setAddressState("state");
        contactInfo.setAddressPostalCode("postCode");
        contactInfo.setAddressCountry("country");
        contactInfo.setContactVoice("voice");
        contactInfo.setContactEmail("email");
        contactInfo.setContactFacsimile("fax");

        wmsInfo.setFees("fees");
        wmsInfo.setAccessConstraints("accessConstraints");

        GetCapabilitiesTransformer tr;
View Full Code Here

*/
public class GeoServerHomePage extends GeoServerBasePage {

    public GeoServerHomePage() {
        GeoServer gs = getGeoServer();
        ContactInfo contact = gs.getGlobal().getContact();

        //add some contact info
        add(new ExternalLink("contactURL", contact.getOnlineResource())
            .add( new Label("contactName", contact.getContactOrganization())));
        {
            String version = String.valueOf(new ResourceModel("version").getObject());
            String contactEmail = contact.getContactEmail();
            HashMap<String, String>params = new HashMap<String, String>();
            params.put("version", version);
            params.put("contactEmail", contactEmail);
            Label label = new Label("footerMessage", new StringResourceModel("GeoServerHomePage.footer", this, new Model(params)));
            label.setEscapeModelStrings(false);
View Full Code Here

        service.getKeywords().add("test keyword 1");
        service.getKeywords().add("test keyword 2");
        service.setMaintainer("test maintainer");
        service.setOnlineResource("http://example.com/geoserver");
        GeoServerInfo global = getGeoServer().getGlobal();
        ContactInfo contact = global.getContact();
        contact.setAddress("__address");
        contact.setAddressCity("__city");
        contact.setAddressCountry("__country");
        contact.setAddressPostalCode("__ZIP");
        contact.setAddressState("__state");
        contact.setAddressType("__type");
        contact.setContactEmail("e@mail");
        contact.setContactOrganization("__org");
        contact.setContactFacsimile("__fax");
        contact.setContactPerson("__me");
        contact.setContactPosition("__position");
        contact.setContactVoice("__phone");
       
        getGeoServer().save(global);
        getGeoServer().save(service);

        Document doc = getAsDOM("wms?service=WMS&request=getCapabilities&version=1.3.0", true);
View Full Code Here

                 * </pre>
                 * </p>
                 *
                 */
            protected void serviceProvider(GeoServer gs) {
                ContactInfo contact = gs.getSettings().getContact();
                start("ows:ServiceProvider");

                element("ows:ProviderName", contact.getContactOrganization());
                start( "ows:ServiceContact");
                /*
                <sequence>
                <element ref="ows:IndividualName" minOccurs="0"/>
                <element ref="ows:OrganisationName" minOccurs="0"/>
                <element ref="ows:PositionName" minOccurs="0"/>
                <element ref="ows:ContactInfo" minOccurs="0"/>
                <element ref="ows:Role"/>
                </sequence>
                */
                element( "ows:IndividualName", contact.getContactPerson());
                element( "ows:PositionName", contact.getContactPosition() );

                start( "ows:ContactInfo" );
                /*
                  <sequence>
                        <element name="Phone" type="ows:TelephoneType" minOccurs="0">
                        <element name="Address" type="ows:AddressType" minOccurs="0">
                        <element name="OnlineResource" type="ows:OnlineResourceType" minOccurs="0">
                        <element name="HoursOfService" type="string" minOccurs="0">
                        <element name="ContactInstructions" type="string" minOccurs="0">
                 </sequence>
                 */
                start( "ows:Phone");
                element( "ows:Voice", contact.getContactVoice() );
                element( "ows:Facsimile", contact.getContactFacsimile() );
                end( "ows:Phone");
               
                start( "ows:Address");
                /*
                <element name="DeliveryPoint" type="string" minOccurs="0" maxOccurs="unbounded">
                <element name="City" type="string" minOccurs="0">
                <element name="AdministrativeArea" type="string" minOccurs="0">
                <element name="PostalCode" type="string" minOccurs="0">
                <element name="Country" type="string" minOccurs="0">
                <element name="ElectronicMailAddress" type="string" minOccurs="0" maxOccurs="unbounded">
                 */
                element( "ows:City", contact.getAddressCity() );
                element( "ows:AdministrativeArea", contact.getAddressState() );
                element( "ows:PostalCode", contact.getAddressPostalCode() );
                element( "ows:Country", contact.getAddressCountry() );
                end( "ows:Address" );
               
                end( "ows:ContactInfo" );
               
                end( "ows:ServiceContact");
View Full Code Here

            return true;
        if (obj == null)
            return false;
        if (!(obj instanceof ContactInfo))
            return false;
        final ContactInfo other = (ContactInfo) obj;
        if (address == null) {
            if (other.getAddress() != null)
                return false;
        } else if (!address.equals(other.getAddress()))
            return false;
        if (addressCity == null) {
            if (other.getAddressCity() != null)
                return false;
        } else if (!addressCity.equals(other.getAddressCity()))
            return false;
        if (addressCountry == null) {
            if (other.getAddressCountry() != null)
                return false;
        } else if (!addressCountry.equals(other.getAddressCountry()))
            return false;
        if (addressPostalCode == null) {
            if (other.getAddressPostalCode() != null)
                return false;
        } else if (!addressPostalCode.equals(other.getAddressPostalCode()))
            return false;
        if (addressState == null) {
            if (other.getAddressState() != null)
                return false;
        } else if (!addressState.equals(other.getAddressState()))
            return false;
        if (addressType == null) {
            if (other.getAddressType() != null)
                return false;
        } else if (!addressType.equals(other.getAddressType()))
            return false;
        if (contactEmail == null) {
            if (other.getContactEmail() != null)
                return false;
        } else if (!contactEmail.equals(other.getContactEmail()))
            return false;
        if (contactFacsimile == null) {
            if (other.getContactFacsimile() != null)
                return false;
        } else if (!contactFacsimile.equals(other.getContactFacsimile()))
            return false;
        if (contactOrganization == null) {
            if (other.getContactOrganization() != null)
                return false;
        } else if (!contactOrganization.equals(other.getContactOrganization()))
            return false;
        if (contactPerson == null) {
            if (other.getContactPerson() != null)
                return false;
        } else if (!contactPerson.equals(other.getContactPerson()))
            return false;
        if (contactPosition == null) {
            if (other.getContactPosition() != null)
                return false;
        } else if (!contactPosition.equals(other.getContactPosition()))
            return false;
        if (contactVoice == null) {
            if (other.getContactVoice()!= null)
                return false;
        } else if (!contactVoice.equals(other.getContactVoice()))
            return false;
        if (onlineResource == null) {
            if (other.getOnlineResource() != null)
                return false;
        } else if (!onlineResource.equals(other.getOnlineResource()))
            return false;
        return true;
    }
View Full Code Here

    }

    @Override
    public void encode(Object input, OutputStream os) throws IOException {

        ContactInfo contact = geoServer.getSettings().getContact();
        GpxEncoder encoder = new GpxEncoder(true);
        encoder.setCreator(contact.getContactOrganization());
        encoder.setLink(contact.getOnlineResource());

        try {
            SimpleFeatureCollection fc = (SimpleFeatureCollection) input;
            CoordinateReferenceSystem crs = fc.getSchema().getCoordinateReferenceSystem();
            // gpx is defined only in wgs84
View Full Code Here

    @Override
    protected void setUpInternal() throws Exception {
        GeoServer gs = getGeoServer();
        GeoServerInfo global = gs.getGlobal();
        SettingsInfo settings = global.getSettings();
        ContactInfo contact = settings.getContact();
        contact.setContactOrganization("GeoServer");
        contact.setOnlineResource("http://www.geoserver.org");
        gs.save(global);

        ppio = new KMLPPIO(gs);
    }
View Full Code Here

        info.setOnlineResource( get( global, "onlineResource", String.class ) );
        info.setProxyBaseUrl( get( global, "ProxyBaseUrl", String.class ) );
       
        //contact
        Map<String,Object> contact = reader.contact();
        ContactInfo contactInfo = factory.createContact();
      
        contactInfo.setContactPerson( (String) contact.get( "ContactPerson") );
        contactInfo.setContactOrganization( (String) contact.get( "ContactOrganization") );
        contactInfo.setContactVoice( (String) contact.get( "ContactVoiceTelephone" ) );
        contactInfo.setContactFacsimile( (String) contact.get( "ContactFacsimileTelephone" ) );
        contactInfo.setContactPosition( (String) contact.get( "ContactPosition" ) );
        contactInfo.setContactEmail( (String) contact.get( "ContactElectronicMailAddress" ) );
       
        contactInfo.setAddress( (String) contact.get( "Address") );
        contactInfo.setAddressType( (String) contact.get( "AddressType") );
        contactInfo.setAddressCity( (String) contact.get( "City") );
        contactInfo.setAddressCountry( (String) contact.get( "Country") );
        contactInfo.setAddressState( (String) contact.get( "StateOrProvince") );
        contactInfo.setAddressPostalCode( (String) contact.get( "PostCode") );
        info.setContact( contactInfo );
       
        //jai
        JAIInfo jai = new JAIInfoImpl();
        jai.setMemoryCapacity( (Double) value( global.get( "JaiMemoryCapacity"),JAIInfoImpl.DEFAULT_MemoryCapacity ) );
View Full Code Here

TOP

Related Classes of org.geoserver.config.ContactInfo

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.