#region Disclaimer / License // Copyright (C) 2011, Jackie Ng // http://trac.osgeo.org/mapguide/wiki/maestro, jumpinjackie@gmail.com // // This library is free software; you can redistribute it and/or // modify it under the terms of the GNU Lesser General Public // License as published by the Free Software Foundation; either // version 2.1 of the License, or (at your option) any later version. // // This library 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 // Lesser General Public License for more details. // // You should have received a copy of the GNU Lesser General Public // License along with this library; if not, write to the Free Software // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA // #endregion using System; using System.Collections.Generic; using System.Text; namespace OSGeo.MapGuide.MaestroAPI.Resource.Validation { /// /// A validation status code that is attached to a specific validation issue, allowing for programmatic handling /// of certain validation issues should they occur /// public enum ValidationStatusCode : int { /// /// Placeholder /// Dummy = 0, #region information /// /// No primary key found in feature source. Does affect layer selection if a layer is based on this feature source /// Info_FeatureSource_NoPrimaryKey = 1001, /// /// No coordinate system found in drawing source. Affects re-projection if referencing layer is housed in a Map Definition /// Info_DrawingSource_NoCoordinateSpace = 1011, /// /// A layer group has no label. Results in no text when displayed in the viewer legend /// Info_MapDefinition_GroupMissingLabelInformation = 1101, /// /// A layer group has a default label assigned to it. /// Info_MapDefinition_GroupHasDefaultLabel, /// /// /// Info_MapDefinition_MultipleSpatialContexts, /// /// One or more scale ranges overlap. Can affect presentation of data. /// Info_LayerDefinition_ScaleRangeOverlap = 1201, /// /// A referenced symbol definition contains irrelevant usage contexts for this particular layer /// Info_LayerDefinition_IrrelevantUsageContext, #endregion #region warnings /// /// Placeholder validation warning /// Warning_General_ValidationWarning = 3001, /// /// No validation was found for the specified resource and/or version /// Warning_General_NoRegisteredValidatorForResource, /// /// Feature Source has no spatial context. Affects re-projection if referencing layer is housed in a Map Definition /// Warning_FeatureSource_NoSpatialContext = 3101, /// /// Feature Source has an empty spatial context /// Warning_FeatureSource_EmptySpatialContext, /// /// Feature Source has a spatial context with what appears to be system-generated bounds. This usually makes extent queries or /// operations that rely on a data store's extents (eg. Layer Previews) unreliable /// Warning_FeatureSource_DefaultSpatialContext, /// /// No feature schemas found in feature source. Layers referencing this feature source have nothing to show and style. /// Warning_FeatureSource_NoSchemasFound, /// /// A mapagent error occurred during Feature Source validation. Most likely because of timeout. As a result, the full validity of the /// Feature Source cannot be determined /// Warning_FeatureSource_Validation_Timeout, /// /// Due to a limitation in the public APIs provided by MapGuide. Feature Sources with encrypted security credentials (MG_USER_CREDENTIALS) /// cannot be packaged by Maestro's packager without discarding the MG_USER_CREDENTIALS element. The workaround is to either re-secure these /// feature sources after loading the Maestro-created package, or to use the official packaging method which will preserve MG_USER_CREDENTIALS /// in its encrypted state /// Warning_FeatureSource_Cannot_Package_Secured_Credentials, /// /// A Feature Source whose provider contains username/password connection parameters contains login credentials in plaintext. This is not secure /// as such Feature Sources can be accessed by the Anonymous MapGuide user account. It is strongly advised that such Feature Sources can be /// re-secured with MapGuide/Infrastructure Studio or with Maestro 4.0.3 (or newer) /// Warning_FeatureSource_Plaintext_Credentials, /// /// An Extended Feature Class does not specify a join prefix. This will cause collisions if the primary and secondary classes have one or more identical /// property names /// Warning_FeatureSource_EmptyJoinPrefix, /// /// An Extended Feature Class does not specify /// Warning_FeatureSource_Potential_Bad_Join_Performance, /// /// DWG Load Procedures not supported. This is a limitation of Maestro /// Warning_LoadProcedure_DwgNotSupported = 3201, /// /// Raster Load Procedures not supported. This is a limitation of Maestro /// Warning_LoadProcedure_RasterNotSupported, /// /// SDF2 options not supported for a SDF Load Procedure. This is a limitation of Maestro /// Warning_LoadProcedure_Sdf2OptionsNotSupported, /// /// Generalization options not supported for file-based Load Procedures. This is a limitation of Maestro /// Warning_LoadProcedure_GeneralizationNotSupported, /// /// Convert to SDF (3.0) option not supported for file-based Load Procedures. This is a limitation of Maestro /// Warning_LoadProcedure_ConvertToSdf3NotSupported, /// /// A source file referenced in a Load Procedure could not be found. This can happen if executing this Load Procedure on a different client machine. /// Warning_LoadProcedure_SourceFileNotFound, /// /// A layer in a Map Definition has no legend label. Results in not text displayed in the viewer legend. /// Warning_MapDefinition_LayerMissingLegendLabel = 3301, /// /// Could not find a spatial context for a referenced layer definition in the map definition /// Warning_MapDefinition_MissingSpatialContext, /// /// One or more layers in a Map Definition have different coordinate system than the one declared in the Map Definition. This will normally incur a /// minor performance penalty when rendering due to on-the-fly reprojection of data. In some cases, this is unavoidable. /// Warning_MapDefinition_LayerReprojection, /// /// One or more layers in a Map Definition has data that lies outside of the extents in the Map Definition. This normally means the user would have /// to manually pan outside the extents to see this data. /// Warning_MapDefinition_DataOutsideMapBounds, /// /// The Map Definition does not have a coordinate system /// Warning_MapDefinition_MissingCoordinateSystem, /// /// The Map Definition contains a referenced feature source that has a null extent (usually caused by having no data in the feature source) /// Warning_MapDefinition_FeatureSourceWithNullExtent, /// /// The specified initial view parameters lie outside the referenced Map Definition's extents. Usually means you will see nothing when the Fusion viewer loads. /// Warning_Fusion_InitialViewOutsideMapExtents = 3401, /// /// The specified map definition's coordinate system is not WGS84.PseudoMercator. This is a requirement for integrating with Google/Yahoo/Bing commerical layers /// Warning_Fusion_MapCoordSysIncompatibleWithCommericalLayers, /// /// The referenced widget has no label, which may cause display problems if there is no icon specified /// Warning_Fusion_NoLabelOnWidget, /// /// A toolbar or container contains a reference to a non-UI widget /// Warning_Fusion_NonStandardUiWidgetAttachedToContainer, /// /// Unrecognised layer type /// Warning_LayerDefinition_UnsupportedLayerType = 3501, /// /// Multiple raster scale ranges were found /// Warning_LayerDefinition_MultipleGridScaleRanges, /// /// A scale range was found in a Layer Definition which has a composite style defined along side a point, line or area style. In such cases, the /// composite style will always take precedence and the point/line/area style will have no effect /// Warning_LayerDefinition_CompositeStyleDefinedAlongsideBasicStyle, /// /// A parameter override has been specified for a parameter that does not exist /// Warning_LayerDefinition_SymbolParameterOverrideToNonExistentParameter, /// /// The web layout's initial view lies outside the referenced map definition's extents. Usually means you will see nothing when the AJAX viewer loads. /// Warning_WebLayout_InitialViewOutsideMapExtents = 3601, /// /// The simple symbol definition contains a symbol parameter that is not referenced /// anywhere within the definition /// Warning_SymbolDefinition_SymbolParameterNotUsed = 3701, #endregion #region errors /// /// General validation error that couldn't be categorized /// Error_General_ValidationError = 5001, /// /// One or more connection parameters for the feature source are invalid. /// Error_FeatureSource_ConnectionTestFailed = 5101, /// /// Unclassified error when reading spatial contexts /// Error_FeatureSource_SpatialContextReadError, /// /// Unclassified error when describing a schema /// Error_FeatureSource_SchemaReadError, /// /// The validator found the %MG_USERNAME% and %MG_PASSWORD% placeholder tokens in the Feature Source content, but could not find the /// matching MG_USER_CREDENTIALS resource data item that contains the encrypted credentials /// Error_FeatureSource_SecuredCredentialTokensWithoutSecuredCredentialData, /// /// No finite display scales defined for a map definition that contains tiled layers. /// Error_MapDefinition_NoFiniteDisplayScales = 5201, /// /// A raster layer in a Map Definition has a different coordinate system from the one that is declared in the /// Map Definition and the MapGuide Server we're connecting to does not support the raster re-projection feature (MGOS 2.0 or earlier) /// Error_MapDefinition_RasterReprojection, /// /// Unclassified error when reading a resource /// Error_MapDefinition_ResourceRead, /// /// Unclassified error when reading a feature source /// Error_MapDefinition_FeatureSourceRead, /// /// Unclassified error when reading a layer definition /// Error_MapDefinition_LayerRead, /// /// A layer belongs to a layer group that doesn't exist /// Error_MapDefinition_LayerWithNonExistentGroup, /// /// A layer group belongs to a layer group that doesn't exist /// Error_MapDefinition_GroupWithNonExistentGroup, /// /// A layer with an already existing name was found. Layer names must be unique /// Error_MapDefinition_DuplicateLayerName = 3301, /// /// The Fusion Application Definition has no Maps or Map Groups /// Error_Fusion_MissingMap = 5301, /// /// The referenced Map definition doesn't exist /// Error_Fusion_InvalidMap, /// /// Unclassified error validating the referenced map definition /// Error_Fusion_MapValidationError, /// /// A toolbar or container contains a reference to a non-existent widget /// Error_Fusion_InvalidWidgetReference, /// /// Unclassifed validation error /// Error_LayerDefinition_Generic = 5401, /// /// The specified geometry property does not exist in the specified feature class /// Error_LayerDefinition_GeometryNotFound, /// /// The specified feature class does not exist in the specified feature source /// Error_LayerDefinition_ClassNotFound, /// /// Unclassified error loading the referenced feature source /// Error_LayerDefinition_FeatureSourceLoadError, /// /// A specified drawing source sheet layer does not exist in the specified sheet of the specified Drawing Source /// Error_LayerDefinition_DrawingSourceSheetLayerNotFound, /// /// The specified sheet does not exist in the specified Drawing Source. /// Error_LayerDefinition_DrawingSourceSheetNotFound, /// /// Unclassified error validating or loading the referenced Drawing Source /// Error_LayerDefinition_DrawingSourceError, /// /// No Grid scale ranges were found in this Raster Layer /// Error_LayerDefinition_NoGridScaleRanges, /// /// The min scale and max scale values are swapped. /// Error_LayerDefinition_MinMaxScaleSwapped, /// /// The vector layer has no scale ranges. /// Error_LayerDefinition_MissingScaleRanges, /// /// There is no specified geometry property (as opposed to a geometry property specified, but doesn't exist) /// Error_LayerDefinition_MissingGeometry, /// /// There is no specified feature source (as opposed to a feature source specified, but doesn't exist) /// Error_LayerDefinition_MissingFeatureSource, /// /// Cannot determine the layer sub-type /// Error_LayerDefinition_LayerNull, /// /// The Layer Definition contains a composite rule pointing to a non-existent symbol definition /// Error_LayerDefinition_SymbolDefintionReferenceNotFound, /// /// Unclassified validation error /// Error_WebLayout_Generic = 5501, /// /// A toolbar item references a command that doesn't exist /// Error_WebLayout_NonExistentToolbarCommandReference, /// /// A task pane item references a command that doesn't exist /// Error_WebLayout_NonExistentTaskPaneCommandReference, /// /// A context menu item references a command that doesn't exist /// Error_WebLayout_NonExistentContextMenuCommandReference, /// /// A search result column references the same feature property. /// Error_WebLayout_DuplicateSearchCommandResultColumn, /// /// One or more commands have the same name /// Error_WebLayout_DuplicateCommandName, /// /// No Map Definition specified. /// Error_WebLayout_MissingMap, /// /// Source DWF file not specified /// Error_DrawingSource_NoSourceDwf = 5601, /// /// The simple symbol definition has no geometry usage contexts /// Error_SymbolDefinition_NoGeometryUsageContexts = 5701, /// /// The simple symbol definition contains an image graphic that references /// a non-existent resource id /// Error_SymbolDefinition_ImageGraphicReferenceResourceIdNotFound, /// /// The simple symbol definition contains an image graphic that references /// a non-existent resource data item /// Error_SymbolDefinition_ImageGraphicReferenceResourceDataNotFound, #endregion } }