Geo::GDAL  2.4
Geo::OGR::FeatureDefn Class Reference

The schema of a feature or a layer.
More...

+ Inheritance diagram for Geo::OGR::FeatureDefn:
+ Collaboration diagram for Geo::OGR::FeatureDefn:

Public Member Functions

public method AddField (hash params)
 
public method DeleteField (scalar name)
 
public method Feature ()
 
public scalar GetFieldDefn (scalar name)
 
public list GetFieldNames ()
 
public scalar GetGeomFieldDefn (scalar name)
 
public scalar GetName ()
 
public hash reference GetSchema ()
 Get the schema of this feature or layer definition.

More...
 
public method IsSame (Geo::OGR::FeatureDefn defn)
 
public scalar IsStyleIgnored ()
 
public method SetStyleIgnored (scalar IgnoreState)
 
public Geo::OGR::FeatureDefn new (hash schema)
 
- 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 ()
 

Detailed Description

The schema of a feature or a layer.

A FeatureDefn object is a collection of field definition objects. A
read-only FeatureDefn object can be obtained from a layer
(Geo::OGR::Layer::GetDefn()) or a feature
(Geo::OGR::Feature::GetDefn()).

Definition at line 9533 of file all.dox.

Member Function Documentation

public method Geo::OGR::FeatureDefn::AddField ( hash  params)

Object method.

Parameters
paramsNamed parameters to create a new Geo::OGR::FieldDefn
or Geo::OGR::GeomFieldDefn object.

Code:
click to view

public method Geo::OGR::FeatureDefn::DeleteField ( scalar  name)

Object method.

Note
Currently only geometry fields can be deleted.
Parameters
indexthe index of the geometry field to be deleted.

Code:
click to view

public method Geo::OGR::FeatureDefn::Feature ( )


Code:
click to view

public scalar Geo::OGR::FeatureDefn::GetFieldDefn ( scalar  name)

Object method.
Get the definition of a field.

Parameters
namethe name of the field.
Returns
a Geo::OGR::FieldDefn object.

Code:
click to view

public list Geo::OGR::FeatureDefn::GetFieldNames ( )

Object method.
The names of the fields in this layer or feature definition.

Returns
the list of field names.

Code:
click to view

public scalar Geo::OGR::FeatureDefn::GetGeomFieldDefn ( scalar  name)

Object method.
Get the definition of a spatial field.

Parameters
namethe name of the spatial field.
Returns
a Geo::OGR::GeomFieldDefn object.

Code:
click to view

public scalar Geo::OGR::FeatureDefn::GetName ( )

Object method.

Returns
the name of this layer or feature definition.

Code:
click to view

public hash reference Geo::OGR::FeatureDefn::GetSchema ( )

Get the schema of this feature or layer definition.

Object method.

Returns
the schema as a hash whose keywords are Name, StyleIgnored
and Fields. Fields is an anonymous array of first non-spatial and
then spatial field schemas as in Geo::OGR::FieldDefn::Schema() and
Geo::OGR::GeomFieldDefn::Schema().

Code:
click to view

public method Geo::OGR::FeatureDefn::IsSame ( Geo::OGR::FeatureDefn  defn)

Object method.

Returns
true if this definition is similar to the other definition,
false otherwise.

Code:
click to view

public scalar Geo::OGR::FeatureDefn::IsStyleIgnored ( )

Object method.
Get the ignore status of style information when fetching features.

Returns
the ignore status of style information
Since
1.9.0

Code:
click to view

public Geo::OGR::FeatureDefn Geo::OGR::FeatureDefn::new ( hash  schema)

Class method.
Creates a new layer or feature definition. The new definition is
either initialized to the given schema or it will contain no
non-spatial fields and one spatial field, whose Name is '' and
GeometryType is 'Unknown' or the value of the named parameter
GeometryType.

Parameters
schema[optional] The schema for the new feature definition,
as in Geo::OGR::FeatureDefn::Schema().
Returns
a Geo::OGR::FeatureDefn object

Example usage:
<br> Name => "name",
<br> Fields => [{ Name => 'field1', Type => 'String' },
<br> { Name => 'geom', GeometryType => 'Point' }] );
<br>


Code:
click to view

public method Geo::OGR::FeatureDefn::SetStyleIgnored ( scalar  IgnoreState)

Object method.
Set the ignore status of style information when fetching features.

Since
1.9.0

Code:
click to view


The documentation for this class was generated from the following file: