mirror of
https://github.com/qgis/QGIS.git
synced 2025-03-24 00:06:24 -04:00
added missing docstrings
This commit is contained in:
parent
02cf6f3bb6
commit
3e75f92d86
@ -767,9 +767,9 @@ void QgsWcsCapabilities::parseCoverageOfferingBrief( QDomElement const &e, QgsWc
|
|||||||
QgsDebugMsg( QStringLiteral( "coverage orderId = %1 identifier = %2" ).arg( coverageSummary.orderId ).arg( coverageSummary.identifier ) );
|
QgsDebugMsg( QStringLiteral( "coverage orderId = %1 identifier = %2" ).arg( coverageSummary.orderId ).arg( coverageSummary.identifier ) );
|
||||||
}
|
}
|
||||||
|
|
||||||
void QgsWcsCapabilities::parseMetadataLink( QDomElement const &e, QgsWcsMetadataLinkProperty &metadataLink )
|
void QgsWcsCapabilities::parseMetadataLink( const QDomElement &element, QgsWcsMetadataLinkProperty &metadataLink )
|
||||||
{
|
{
|
||||||
QDomElement metadataElement = firstChild( e, QStringLiteral( "metadataLink" ) );
|
QDomElement metadataElement = firstChild( element, QStringLiteral( "metadataLink" ) );
|
||||||
|
|
||||||
if ( !metadataElement.isNull() )
|
if ( !metadataElement.isNull() )
|
||||||
{
|
{
|
||||||
|
@ -34,7 +34,7 @@
|
|||||||
class QNetworkAccessManager;
|
class QNetworkAccessManager;
|
||||||
class QNetworkReply;
|
class QNetworkReply;
|
||||||
|
|
||||||
//! Metadata Link Property structure
|
//! Metadata link property structure
|
||||||
struct QgsWcsMetadataLinkProperty
|
struct QgsWcsMetadataLinkProperty
|
||||||
{
|
{
|
||||||
QString metadataType;
|
QString metadataType;
|
||||||
@ -55,12 +55,14 @@ struct QgsWcsCoverageSummary
|
|||||||
QList<double> nullValues;
|
QList<double> nullValues;
|
||||||
QgsRectangle wgs84BoundingBox; // almost useless, we need the native
|
QgsRectangle wgs84BoundingBox; // almost useless, we need the native
|
||||||
QString nativeCrs;
|
QString nativeCrs;
|
||||||
//Optional metadataLink
|
//! Optional metadataLink
|
||||||
QgsWcsMetadataLinkProperty metadataLink;
|
QgsWcsMetadataLinkProperty metadataLink;
|
||||||
// Map of bounding boxes, key is CRS name (srsName), e.g. EPSG:4326
|
|
||||||
|
//! Map of bounding boxes, key is CRS name (srsName), e.g. EPSG:4326
|
||||||
QMap<QString, QgsRectangle> boundingBoxes;
|
QMap<QString, QgsRectangle> boundingBoxes;
|
||||||
QgsRectangle nativeBoundingBox;
|
QgsRectangle nativeBoundingBox;
|
||||||
// timePosition or timePeriod (beginPosition/endPosition[/timeResolution] - used in KVP request)
|
|
||||||
|
//! timePosition or timePeriod (beginPosition/endPosition[/timeResolution] - used in KVP request)
|
||||||
QStringList times;
|
QStringList times;
|
||||||
QVector<QgsWcsCoverageSummary> coverageSummary;
|
QVector<QgsWcsCoverageSummary> coverageSummary;
|
||||||
// non reflecting Capabilities structure:
|
// non reflecting Capabilities structure:
|
||||||
@ -123,7 +125,7 @@ class QgsWcsCapabilities : public QObject
|
|||||||
*/
|
*/
|
||||||
void coverageParents( QMap<int, int> &parents, QMap<int, QStringList> &parentNames ) const;
|
void coverageParents( QMap<int, int> &parents, QMap<int, QStringList> &parentNames ) const;
|
||||||
|
|
||||||
// Parse metadata element from the document
|
//! Parse metadata element from the document
|
||||||
void parseMetadataLink( QDomElement const &e, QgsWcsMetadataLinkProperty &metadataLink );
|
void parseMetadataLink( QDomElement const &e, QgsWcsMetadataLinkProperty &metadataLink );
|
||||||
|
|
||||||
//! Gets coverage summary for identifier
|
//! Gets coverage summary for identifier
|
||||||
|
@ -789,7 +789,7 @@ void QgsWmsCapabilities::parseMetadataUrl( QDomElement const &e, QgsWmsMetadataU
|
|||||||
QDomNode n1 = e.firstChild();
|
QDomNode n1 = e.firstChild();
|
||||||
while ( !n1.isNull() )
|
while ( !n1.isNull() )
|
||||||
{
|
{
|
||||||
QDomElement e1 = n1.toElement(); // try to convert the node to an element.
|
QDomElement e1 = n1.toElement();
|
||||||
if ( !e1.isNull() )
|
if ( !e1.isNull() )
|
||||||
{
|
{
|
||||||
QString tagName = e1.tagName();
|
QString tagName = e1.tagName();
|
||||||
@ -807,8 +807,6 @@ void QgsWmsCapabilities::parseMetadataUrl( QDomElement const &e, QgsWmsMetadataU
|
|||||||
}
|
}
|
||||||
n1 = n1.nextSibling();
|
n1 = n1.nextSibling();
|
||||||
}
|
}
|
||||||
|
|
||||||
QgsDebugMsg( QStringLiteral( "exiting." ) );
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void QgsWmsCapabilities::parseLayer( QDomElement const &e, QgsWmsLayerProperty &layerProperty,
|
void QgsWmsCapabilities::parseLayer( QDomElement const &e, QgsWmsLayerProperty &layerProperty,
|
||||||
|
@ -1813,13 +1813,17 @@ QString QgsWmsProvider::layerMetadata( QgsWmsLayerProperty &layer )
|
|||||||
if ( !layer.metadataUrl.isEmpty() )
|
if ( !layer.metadataUrl.isEmpty() )
|
||||||
{
|
{
|
||||||
metadata += QStringLiteral( "<tr><th>" ) %
|
metadata += QStringLiteral( "<tr><th>" ) %
|
||||||
tr( "MetadataURLs" ) %
|
tr( "Metadata URLs" ) %
|
||||||
QStringLiteral( "</th>"
|
QStringLiteral( "</th>"
|
||||||
"<td><table class=\"tabular-view\">"
|
"<td><table class=\"tabular-view\">"
|
||||||
"<tr><th>Format</th><th>URL</th></tr>" );
|
"<tr><th>" ) %
|
||||||
for ( int k = 0; k < layer.metadataUrl.size(); k++ )
|
tr( "Format" ) %
|
||||||
|
QStringLiteral("</th><th>") %
|
||||||
|
tr( "URL" ) %
|
||||||
|
QStringLiteral("</th></tr>" );
|
||||||
|
|
||||||
|
for ( const QgsWmsMetadataUrlProperty &l : qgis::as_const( layer.metadataUrl ) )
|
||||||
{
|
{
|
||||||
const QgsWmsMetadataUrlProperty &l = layer.metadataUrl[k];
|
|
||||||
metadata += QStringLiteral( "<tr><td>" ) % l.format % QStringLiteral( "</td><td>" ) % l.onlineResource.xlinkHref % QStringLiteral( "</td></tr>" );
|
metadata += QStringLiteral( "<tr><td>" ) % l.format % QStringLiteral( "</td><td>" ) % l.onlineResource.xlinkHref % QStringLiteral( "</td></tr>" );
|
||||||
}
|
}
|
||||||
metadata += QStringLiteral( "</table>"
|
metadata += QStringLiteral( "</table>"
|
||||||
|
Loading…
x
Reference in New Issue
Block a user