29 results <<
ValidationResult( QObject::tr(
"identifier" ), QObject::tr(
"Identifier element is required." ) );
35 results <<
ValidationResult( QObject::tr(
"language" ), QObject::tr(
"Language element is required." ) );
38 if ( metadata.
type().isEmpty() )
41 results <<
ValidationResult( QObject::tr(
"type" ), QObject::tr(
"Type element is required." ) );
44 if ( metadata.
title().isEmpty() )
47 results <<
ValidationResult( QObject::tr(
"title" ), QObject::tr(
"Title element is required." ) );
53 results <<
ValidationResult( QObject::tr(
"abstract" ), QObject::tr(
"Abstract element is required." ) );
59 results <<
ValidationResult( QObject::tr(
"license" ), QObject::tr(
"At least one license is required." ) );
65 results <<
ValidationResult( QObject::tr(
"crs" ), QObject::tr(
"A valid CRS element is required." ) );
74 results <<
ValidationResult( QObject::tr(
"extent" ), QObject::tr(
"A valid CRS element for the spatial extent is required." ), index );
80 results <<
ValidationResult( QObject::tr(
"extent" ), QObject::tr(
"A valid spatial extent is required." ), index );
88 results <<
ValidationResult( QObject::tr(
"contacts" ), QObject::tr(
"At least one contact is required." ) );
91 if ( metadata.
links().isEmpty() )
94 results <<
ValidationResult( QObject::tr(
"links" ), QObject::tr(
"At least one link is required." ) );
99 QgsLayerMetadata::KeywordMap::const_iterator keywordIt = keywords.constBegin();
101 for ( ; keywordIt != keywords.constEnd(); ++keywordIt )
103 if ( keywordIt.key().isEmpty() )
106 results <<
ValidationResult( QObject::tr(
"keywords" ), QObject::tr(
"Keyword vocabulary cannot be empty." ), index );
108 if ( keywordIt.value().isEmpty() )
111 results <<
ValidationResult( QObject::tr(
"keywords" ), QObject::tr(
"Keyword list cannot be empty." ), index );
120 if ( contact.
name.isEmpty() )
123 results <<
ValidationResult( QObject::tr(
"contacts" ), QObject::tr(
"Contact name cannot be empty." ), index );
132 if ( link.
name.isEmpty() )
135 results <<
ValidationResult( QObject::tr(
"links" ), QObject::tr(
"Link name cannot be empty." ), index );
137 if ( link.
type.isEmpty() )
140 results <<
ValidationResult( QObject::tr(
"links" ), QObject::tr(
"Link type cannot be empty." ), index );
142 if ( link.
url.isEmpty() )
145 results <<
ValidationResult( QObject::tr(
"links" ), QObject::tr(
"Link url cannot be empty." ), index );
double height() const
Returns the height of the box.
double width() const
Returns the width of the box.
bool isValid() const
Returns whether this CRS is correctly initialized and usable.