Geo::GDAL
2.3
|
A collection of similar features.
More...
Public Member Functions | |
public method | AlterFieldDefn (scalar name, hash params) |
public list | Capabilities () |
public method | Clip (Geo::OGR::Layer method, Geo::OGR::Layer result, hashref options, coderef callback, scalar callback_data) |
public method | CommitTransaction () |
public method | CreateFeature () |
public method | CreateField (hash params) |
public method | DataSource () |
public method | Dataset () |
public method | DeleteFeature (scalar fid) |
public method | DeleteField (scalar field) |
public method | Erase (Geo::OGR::Layer method, Geo::OGR::Layer result, hashref options, coderef callback, scalar callback_data) |
public Geo::OGR::Feature | Feature (scalar f) |
public scalar | FeatureCount (scalar force=1) |
public method | Features () |
public method | ForFeatures (scalar code, scalar in_place) |
public method | ForGeometries (scalar code, scalar in_place) |
public method | Geometries () |
public scalar | GeometryType (scalar field) |
public Geo::OGR::DataSource | GetDataSource () |
public Geo::OGR::FeatureDefn | GetDefn () |
public list | GetExtent (scalar force=1) |
public scalar | GetFIDColumn () |
public Geo::OGR::Feature | GetFeature (scalar fid) |
public method | GetFeatureCount () |
public scalar | GetFeaturesRead () |
public scalar | GetFieldDefn (scalar name) |
public list | GetFieldNames () |
public scalar | GetGeomFieldDefn (scalar name) |
public scalar | GetName () |
public Geo::OGR::Feature | GetNextFeature () |
public hash reference | GetSchema () |
Get the schema of this layer. More... | |
public Geo::OGR::Geometry | GetSpatialFilter () |
public method | GetStyleTable () |
public method | Identity (Geo::OGR::Layer method, Geo::OGR::Layer result, hashref options, coderef callback, scalar callback_data) |
public method | InsertFeature (scalar feature) |
public method | Intersection (Geo::OGR::Layer method, Geo::OGR::Layer result, hashref options, coderef callback, scalar callback_data) |
public method | ReorderField () |
public method | ReorderFields () |
public method | ResetReading () |
public method | RollbackTransaction () |
public hash reference | Row (hash row) |
public method | SetAttributeFilter (scalar filter_string) |
public method | SetFeature (scalar feature) |
public method | SetIgnoredFields (array fields) |
public method | SetNextByIndex (scalar new_index) |
public method | SetSpatialFilter (scalar filter) |
public method | SetSpatialFilterRect (scalar minx, scalar miny, scalar maxx, scalar maxy) |
public method | SetStyleTable () |
public Geo::OGR::Geometry | SpatialFilter (array filter) |
public Geo::OSR::SpatialReference | SpatialReference (scalar name, Geo::OSR::SpatialReference sr) |
public method | StartTransaction () |
public method | SymDifference (Geo::OGR::Layer method, Geo::OGR::Layer result, hashref options, coderef callback, scalar callback_data) |
public method | SyncToDisk () |
public scalar | TestCapability (scalar cap) |
public list | Tuple (array tuple) |
public method | Union (Geo::OGR::Layer method, Geo::OGR::Layer result, hashref options, coderef callback, scalar callback_data) |
public method | Update (Geo::OGR::Layer method, Geo::OGR::Layer result, hashref options, coderef callback, scalar callback_data) |
Public Member Functions inherited from Geo::GDAL::MajorObject | |
public scalar | Description (scalar description) |
public method | Domains () |
public scalar | GetDescription () |
public hash reference | GetMetadata (scalar domain="") |
public method | GetMetadataDomainList () |
public hash reference | Metadata (hashref metadata=undef, scalar domain= '') |
public method | SetDescription (scalar NewDesc) |
public method | SetMetadata (hashref metadata, scalar domain="") |
Public Member Functions inherited from Geo::GDAL | |
public method | ApplyVerticalShiftGrid () |
public method | BuildVRT () |
public method | CPLBinaryToHex () |
public method | CPLHexToBinary () |
public method | CreatePansharpenedVRT () |
public scalar | DataTypeIsComplex (scalar DataType) |
public list | DataTypeValueRange (scalar DataType) |
public list | DataTypes () |
public scalar | DecToDMS (scalar angle, scalar axis, scalar precision=2) |
public scalar | DecToPackedDMS (scalar dec) |
public method | DontUseExceptions () |
public Geo::GDAL::Driver | Driver (scalar Name) |
public list | DriverNames () |
public list | Drivers () |
public method | EscapeString () |
public scalar | FindFile (scalar basename) |
public method | FinderClean () |
public method | GOA2GetAccessToken () |
public method | GOA2GetAuthorizationURL () |
public method | GOA2GetRefreshToken () |
public method | GetActualURL () |
public scalar | GetCacheMax () |
public scalar | GetCacheUsed () |
public scalar | GetConfigOption (scalar key) |
public scalar | GetDataTypeSize (scalar DataType) |
public method | GetErrorCounter () |
public method | GetFileSystemOptions () |
public method | GetFileSystemsPrefixes () |
public method | GetJPEG2000StructureAsString () |
public method | GetSignedURL () |
public Geo::GDAL::Driver | IdentifyDriver (scalar path, scalar siblings) |
public method | IdentifyDriverEx () |
public method | MkdirRecursive () |
public Geo::GDAL::Dataset | Open (hash params) |
public Geo::GDAL::Dataset | OpenEx (hash params) |
public list | OpenFlags () |
public scalar | PackCharacter (scalar DataType) |
public scalar | PackedDMSToDec (scalar packed) |
public method | PopFinderLocation () |
public method | PushFinderLocation (scalar path) |
public list | RIOResamplingTypes () |
public list | ResamplingTypes () |
public method | RmdirRecursive () |
public method | SetCacheMax (scalar Bytes) |
public method | SetConfigOption (scalar key, scalar value) |
public method | UseExceptions () |
public method | VSICurlClearCache () |
public method | VSIFEofL () |
public method | VSIFOpenExL () |
public method | VSIGetLastErrorMsg () |
public method | VSIGetLastErrorNo () |
public scalar | VersionInfo (scalar request= 'VERSION_NUM') |
public scalar | errstr () |
Public Member Functions inherited from Geo::OGR | |
public list | ByteOrders () |
public Geo::GDAL::Driver | Driver (scalar name) |
public list | DriverNames () |
public list | Drivers () |
public method | Flatten () |
public scalar | GeometryTypeModify (scalar type, scalar modifier) |
public scalar | GeometryTypeTest (scalar type, scalar test, scalar type2) |
public list | GeometryTypes () |
public method | GetNonLinearGeometriesEnabledFlag () |
public method | GetOpenDSCount () |
public method | HasM () |
public method | HasZ () |
public Geo::GDAL::Dataset | Open (scalar name, scalar update=0) |
public Geo::GDAL::Dataset | OpenShared (scalar name, scalar update=0) |
public method | SetGenerate_DB2_V72_BYTE_ORDER (scalar Generate_DB2_V72_BYTE_ORDER) |
public method | SetNonLinearGeometriesEnabledFlag () |
A collection of similar features.
A layer object is typically obtained with a data source object. A
layer has a data model (a schema), which is maintained in a
definition object, and a set of features, which contain data
according to the data model. The schema is typically set when the
layer is created or opened, but it may be altered somewhat with
methods Geo::OGR::Layer::CreateField,
Geo::OGR::Layer::AlterFieldDefn, and
Geo::OGR::Layer::DeleteField. Features and/or their data can be
read, inserted and deleted. Reading can be filtered. Layers can be
compared to each other with methods Clip, Erase, Identity,
Intersection, SymDifference, Union, and Update.
A layer may have metadata OLMD_FID64 => 'YES' if it holds features
with 64 bit FIDs. The metadata of a layer can be obtained with
GetMetadata method.
public method Geo::OGR::Layer::AlterFieldDefn | ( | scalar | name, |
hash | params | ||
) |
Object method.
field | the name of the field to be altered. |
params | as in Geo::OGR::FieldDefn::new. Width and Precision should be both or neither. |
public list Geo::OGR::Layer::Capabilities | ( | ) |
Object method.
Both a package subroutine and an object method.
public method Geo::OGR::Layer::Clip | ( | Geo::OGR::Layer | method, |
Geo::OGR::Layer | result, | ||
hashref | options, | ||
coderef | callback, | ||
scalar | callback_data | ||
) |
Object method.
Clip off areas that are not covered by the method layer. The schema
of the result layer can be set before calling this method, or is
initialized to to contain all fields from
this and method layer.
method | method layer. |
result | result layer. |
options | a reference to an options hash. |
callback | [optional] a reference to a subroutine, which will be called with parameters (number progress, string msg, callback_data) |
callback_data | [optional] |
public method Geo::OGR::Layer::CommitTransaction | ( | ) |
Object method.
public method Geo::OGR::Layer::CreateFeature | ( | ) |
public method Geo::OGR::Layer::CreateField | ( | hash | params | ) |
Object method.
Create a field.
params | as in Geo::OGR::FieldDefn::new or Geo::OGR::GeomFieldDefn::new, plus ApproxOK (whose default is true). |
public method Geo::OGR::Layer::Dataset | ( | ) |
public method Geo::OGR::Layer::DataSource | ( | ) |
public method Geo::OGR::Layer::DeleteFeature | ( | scalar | fid | ) |
Object method.
fid | feature id |
public method Geo::OGR::Layer::DeleteField | ( | scalar | field | ) |
Object method.
Delete an existing field from a layer.
field | name (or index) of the field which is deleted |
public method Geo::OGR::Layer::Erase | ( | Geo::OGR::Layer | method, |
Geo::OGR::Layer | result, | ||
hashref | options, | ||
coderef | callback, | ||
scalar | callback_data | ||
) |
Object method.
The result layer contains features whose geometries represent areas
that are in the input layer but not in the method layer. The
features in the result layer have attributes from the input
layer. The schema of the result layer can be set by the user or, if
it is empty, is initialized to contain all fields in the input
layer.
method | method layer. |
result | result layer. |
options | a reference to an options hash. |
callback | [optional] a reference to a subroutine, which will be called with parameters (number progress, string msg, callback_data) |
callback_data | [optional] |
public Geo::OGR::Feature Geo::OGR::Layer::Feature | ( | scalar | f | ) |
Object method.
f | [optional] feature id, a feature, a row, or a tuple |
public scalar Geo::OGR::Layer::FeatureCount | ( | scalar | force = 1 | ) |
Object method.
A.k.a GetFeatureCount
force |
public method Geo::OGR::Layer::Features | ( | ) |
public method Geo::OGR::Layer::ForFeatures | ( | scalar | code, |
scalar | in_place | ||
) |
Object method.
code | a reference to a subroutine, which is called with each feature as an argument |
in_place | if set to true, the feature is stored back to the layer |
public method Geo::OGR::Layer::ForGeometries | ( | scalar | code, |
scalar | in_place | ||
) |
Object method.
code | a reference to a subroutine, which is called with each geometry as an argument |
in_place | if set to true, the geometry is stored back to the layer |
public method Geo::OGR::Layer::Geometries | ( | ) |
public scalar Geo::OGR::Layer::GeometryType | ( | scalar | field | ) |
Object method.
field | the name or index of the spatial field. |
public Geo::OGR::DataSource Geo::OGR::Layer::GetDataSource | ( | ) |
Object method.
public Geo::OGR::FeatureDefn Geo::OGR::Layer::GetDefn | ( | ) |
public list Geo::OGR::Layer::GetExtent | ( | scalar | force = 1 | ) |
Object method.
force | compute the extent even if it is expensive |
force |
public Geo::OGR::Feature Geo::OGR::Layer::GetFeature | ( | scalar | fid | ) |
Object method.
fid | feature id |
public method Geo::OGR::Layer::GetFeatureCount | ( | ) |
public scalar Geo::OGR::Layer::GetFeaturesRead | ( | ) |
Object method.
public scalar Geo::OGR::Layer::GetFIDColumn | ( | ) |
Object method.
public scalar Geo::OGR::Layer::GetFieldDefn | ( | scalar | name | ) |
Object method.
Get the definition of a field.
name | the name of the field. |
public list Geo::OGR::Layer::GetFieldNames | ( | ) |
Object method.
public scalar Geo::OGR::Layer::GetGeomFieldDefn | ( | scalar | name | ) |
Object method.
Get the definition of a spatial field.
name | the name of the spatial field. |
public scalar Geo::OGR::Layer::GetName | ( | ) |
Object method.
public Geo::OGR::Feature Geo::OGR::Layer::GetNextFeature | ( | ) |
Object method.
public hash reference Geo::OGR::Layer::GetSchema | ( | ) |
Get the schema of this layer.
Object method.
public Geo::OGR::Geometry Geo::OGR::Layer::GetSpatialFilter | ( | ) |
public method Geo::OGR::Layer::GetStyleTable | ( | ) |
public method Geo::OGR::Layer::Identity | ( | Geo::OGR::Layer | method, |
Geo::OGR::Layer | result, | ||
hashref | options, | ||
coderef | callback, | ||
scalar | callback_data | ||
) |
Object method.
The result layer contains features whose geometries represent areas
that are in the input layer. The features in the result layer have
attributes from both input and method layers. The schema of the
result layer can be set by the user or, if it is empty, is
initialized to contain all fields in input and method layers.
method | method layer. |
result | result layer. |
options | a reference to an options hash. |
callback | [optional] a reference to a subroutine, which will be called with parameters (number progress, string msg, callback_data) |
callback_data | [optional] |
public method Geo::OGR::Layer::InsertFeature | ( | scalar | feature | ) |
Object method.
Creates a new feature which has the schema of the layer and
initializes it with data from the argument. Then inserts the feature
into the layer (using CreateFeature). Uses Geo::OGR::Feature::Row or
Geo::OGR::Feature::Tuple.
feature | a Geo::OGR::Feature object or reference to feature data in a hash (as in Geo::OGR::Feature::Row) or in an array (as in Geo::OGR::Feature::Tuple) |
public method Geo::OGR::Layer::Intersection | ( | Geo::OGR::Layer | method, |
Geo::OGR::Layer | result, | ||
hashref | options, | ||
coderef | callback, | ||
scalar | callback_data | ||
) |
Object method.
The result layer contains features whose geometries represent areas
that are common between features in the input layer and in the
method layer. The schema of the result layer can be set before
calling this method, or is initialized to contain all fields from
this and method layer.
method | method layer. |
result | result layer. |
options | a reference to an options hash. |
callback | [optional] a reference to a subroutine, which will be called with parameters (number progress, string msg, callback_data) |
callback_data | [optional] |
public method Geo::OGR::Layer::ReorderField | ( | ) |
public method Geo::OGR::Layer::ReorderFields | ( | ) |
public method Geo::OGR::Layer::ResetReading | ( | ) |
Object method.
Initialize the layer object for iterative reading.
public method Geo::OGR::Layer::RollbackTransaction | ( | ) |
Object method.
public hash reference Geo::OGR::Layer::Row | ( | hash | row | ) |
Object method.
Get and/or set the data of a feature that has the supplied feature
id (the next feature obtained with GetNextFeature is used if feature
id is not given). Calls Geo::OGR::Feature::Row.
row | [optional] feature data |
public method Geo::OGR::Layer::SetAttributeFilter | ( | scalar | filter_string | ) |
Object method.
Set or clear the attribute filter.
filter_string | a SQL WHERE clause or undef to clear the filter. |
public method Geo::OGR::Layer::SetFeature | ( | scalar | feature | ) |
Object method.
feature | a Geo::OGR::Feature object |
public method Geo::OGR::Layer::SetIgnoredFields | ( | array | fields | ) |
Object method.
fields | a list of field names |
public method Geo::OGR::Layer::SetNextByIndex | ( | scalar | new_index | ) |
Object method.
new_index | the index to which set the read cursor in the current iteration |
public method Geo::OGR::Layer::SetSpatialFilter | ( | scalar | filter | ) |
Object method.
filter | [optional] a Geo::OGR::Geometry object. If not given, removes the filter if there is one. |
public method Geo::OGR::Layer::SetSpatialFilterRect | ( | scalar | minx, |
scalar | miny, | ||
scalar | maxx, | ||
scalar | maxy | ||
) |
Object method.
minx | |
miny | |
maxx | |
maxy |
public method Geo::OGR::Layer::SetStyleTable | ( | ) |
public Geo::OGR::Geometry Geo::OGR::Layer::SpatialFilter | ( | array | filter | ) |
Object method.
filter | [optional] a Geo::OGR::Geometry object or a string. An undefined value removes the filter if there is one. |
filter | [optional] a rectangle ($minx, $miny, $maxx, $maxy). |
public Geo::OSR::SpatialReference Geo::OGR::Layer::SpatialReference | ( | scalar | name, |
Geo::OSR::SpatialReference | sr | ||
) |
Object method.
name | [optional] a name of a spatial field in this layer. |
sr | [optional] a Geo::OSR::SpatialReference object, which replaces the existing projection. |
public method Geo::OGR::Layer::StartTransaction | ( | ) |
Object method.
public method Geo::OGR::Layer::SymDifference | ( | Geo::OGR::Layer | method, |
Geo::OGR::Layer | result, | ||
hashref | options, | ||
coderef | callback, | ||
scalar | callback_data | ||
) |
Object method.
The result layer contains features whose geometries represent areas
that are in either in the input layer or in the method layer but not
in both. The features in the result layer have attributes from both
input and method layers. For features which represent areas that are
only in the input or in the method layer the respective attributes
have undefined values. The schema of the result layer can be set by
the user or, if it is empty, is initialized to contain all fields in
the input and method layers.
method | method layer. |
result | result layer. |
options | a reference to an options hash. |
callback | [optional] a reference to a subroutine, which will be called with parameters (number progress, string msg, callback_data) |
callback_data | [optional] |
public method Geo::OGR::Layer::SyncToDisk | ( | ) |
Object method.
public scalar Geo::OGR::Layer::TestCapability | ( | scalar | cap | ) |
Object method.
cap | A capability string. |
public list Geo::OGR::Layer::Tuple | ( | array | tuple | ) |
Object method.
Get and/set the data of a feature that has the supplied feature id
(the next feature obtained with GetNextFeature is used if feature id
is not given). The expected data in the tuple is: ([feature id,]
non-spatial fields, spatial fields). Calls Geo::OGR::Feature::Tuple.
tuple | [optional] feature data |
public method Geo::OGR::Layer::Union | ( | Geo::OGR::Layer | method, |
Geo::OGR::Layer | result, | ||
hashref | options, | ||
coderef | callback, | ||
scalar | callback_data | ||
) |
Object method.
The result layer contains features whose geometries represent areas
that are in either in the input layer or in the method layer. The
schema of the result layer can be set before calling this method, or
is initialized to contain all fields from this and method layer.
method | method layer. |
result | result layer. |
options | a reference to an options hash. |
callback | [optional] a reference to a subroutine, which will be called with parameters (number progress, string msg, callback_data) |
callback_data | [optional] |
public method Geo::OGR::Layer::Update | ( | Geo::OGR::Layer | method, |
Geo::OGR::Layer | result, | ||
hashref | options, | ||
coderef | callback, | ||
scalar | callback_data | ||
) |
Object method.
The result layer contains features whose geometries represent areas
that are either in the input layer or in the method layer. The
features in the result layer have areas of the features of the
method layer or those ares of the features of the input layer that
are not covered by the method layer. The features of the result
layer get their attributes from the input layer. The schema of the
result layer can be set by the user or, if it is empty, is
initialized to contain all fields in the input layer.
method | method layer. |
result | result layer. |
options | a reference to an options hash. |
callback | [optional] a reference to a subroutine, which will be called with parameters (number progress, string msg, callback_data) |
callback_data | [optional] |