GeoPrisma logo

XMLWorkspaceConfig

The XMLWorkspaceConfig config driver extends the XMLConfig driver and adds the workspace concept

Geoprisma setting

<?php

org_geoprisma_SettingImpl::setConfig('org_geoprisma_config_XMLWorkspaceConfig');

?>

Driver extra parameter

This driver needs the current workspace name to use.

<?php

org_geoprisma_config_XMLWorkspaceConfig::setCurrentWorkspace('workspace1');

?>
keyword:workspace

Workspace

Workspaces allow to define subsets of the set of allowed actions/resources for a given user.

  • Workspace change XMLConfig structure ressources

With this driver widgets are defined in workspace resources

<resources>
    <resource>
        <name>ResourceVMap0</name>
        <datastores>
            <datastore>DSVMap0</datastore>
        </datastores>
        <!-- No widgets node here -->
    </resource>
</resources>
  • Exemple of workspace nodes

    • workspace contains many resource

    • resource options add or replace options defined in the resource node

    • resource widgets have two define type

      <widgets>
          <widget>LegendDemo</widget>     <!-- Simple type -->
          <widget>
              <name>GeoExtToolbar</name>  <!-- More complex type -->
              <options>
                  <option1></option1>
                  <option2></option2>
              </options>
          </widget>
      </widgets>
      
    • widgets of complex type are renamed in the “config secure” with $WidgetName_$ResourceName

      And options are added or replace original widget options

    <workspaces>
        <workspace>
            <name>workspace1</name>
            <resources>
                <resource>
                    <name>ResourceVMap0</name>
                    <widgets>
                        <widget>LegendDemo</widget>
                        <widget>
                            <name>GeoExtToolbar</name>
                            <options>
                                <widgets>
                                    <widget>LengthWidget</widget>
                                    <widget>AreaWidget</widget>
                                    <widget>MyShortcutWidget_Title_ResourceScribble</widget>
                                </widgets>
                            </options>
                        </widget>
                        <widget>MousePositionBDGA</widget>
                        <widget>LengthWidget</widget>
                        <widget>AreaWidget</widget>
                    </widgets>
                    <options>
                        <title>Maps</title>
                        <option1>value</option1>
                        <option2><node>node value</node></option2>
                    </options>
                </resource>
                <resource>
                    <name>ResourceScribble</name>
                    <widgets>
                        <widget>
                            <name>MyShortcutWidget_Title</name>
                            <options>
                                <emptyText>Zoom to scribble author...</emptyText>
                            </options>
                        </widget>
                        <widget>MyShortcutWidget_Author</widget>
                    </widgets>
                    <options>
                        <title>Overide title</title>
                    </options>
                </resource>
            </resources>
        </workspace>
        <workspace>
            <name>workspace2</name>
            <resources>
                <resource>
                    <name>ResourceVMap0</name>
                    <widgets>
                        <widget>GeoExtToolbar</widget>
                    </widgets>
                </resource>
            </resources>
        </workspace>
    </workspaces>
    

Table Of Contents

Previous topic

XMLConfig

Next topic

PGSQLMapContextConfig

This Page