KDE 4.2 PyKDE API Reference for Marble

- KDE's Python API

# GeoDataLatLonBox Class Reference

`from PyKDE4.marble import *`

Inherits: Marble.GeoDataObject → Marble.GeoNode
Subclasses: Marble.GeoDataLatLonAltBox
Namespace: Marble

## Detailed Description

A class that defines a 2D bounding box for geographic data.

GeoDataLatLonBox is a 2D bounding box that describes a geographic area in terms of latitude and longitude.

The bounding box gets described by assigning the northern, southern, eastern and western boundary. So usually the value of the eastern boundary is bigger than the value of the western boundary. Only if the bounding box crosses the date line then the eastern boundary has got a smaller value than the western one.

## Methods
| __init__ (self)
| __init__ (self, float north, float south, float east, float west, Marble.GeoDataCoordinates.Unit unit=GeoDataCoordinates.Radian)
| __init__ (self, Marble.GeoDataLatLonBox a0)
| boundaries (self, float north, float south, float east, float west, Marble.GeoDataCoordinates.Unit unit=GeoDataCoordinates.Radian)
bool | contains (self, Marble.GeoDataPoint a0)
bool | contains (self, Marble.GeoDataCoordinates a0)
bool | contains (self, Marble.GeoDataLatLonBox a0)
bool | crossesDateLine (self)
float | east (self, Marble.GeoDataCoordinates.Unit unit=GeoDataCoordinates.Radian)
float | height (self, Marble.GeoDataCoordinates.Unit unit=GeoDataCoordinates.Radian)
bool | intersects (self, Marble.GeoDataLatLonBox a0)
bool | isFolder (self)
bool | isNull (self)
float | north (self, Marble.GeoDataCoordinates.Unit unit=GeoDataCoordinates.Radian)
| pack (self, QDataStream stream)
float | rotation (self, Marble.GeoDataCoordinates.Unit unit=GeoDataCoordinates.Radian)
| setBoundaries (self, float north, float south, float east, float west, Marble.GeoDataCoordinates.Unit unit=GeoDataCoordinates.Radian)
| setEast (self, float east, Marble.GeoDataCoordinates.Unit unit=GeoDataCoordinates.Radian)
| setNorth (self, float north, Marble.GeoDataCoordinates.Unit unit=GeoDataCoordinates.Radian)
| setRotation (self, float rotation, Marble.GeoDataCoordinates.Unit unit=GeoDataCoordinates.Radian)
| setSouth (self, float south, Marble.GeoDataCoordinates.Unit unit=GeoDataCoordinates.Radian)
| setWest (self, float west, Marble.GeoDataCoordinates.Unit unit=GeoDataCoordinates.Radian)
float | south (self, Marble.GeoDataCoordinates.Unit unit=GeoDataCoordinates.Radian)
QString | toString (self, Marble.GeoDataCoordinates.Unit unit=GeoDataCoordinates.Radian)
| unpack (self, QDataStream stream)
float | west (self, Marble.GeoDataCoordinates.Unit unit=GeoDataCoordinates.Radian)
float | width (self, Marble.GeoDataCoordinates.Unit unit=GeoDataCoordinates.Radian)
## Static Methods
Marble.GeoDataLatLonBox | fromCoordinates (QVector
Marble.GeoDataLatLonBox | fromLineString (Marble.GeoDataLineString lineString)

## Method Documentation

__init__ | ( |  | self ) |

__init__ | ( | self, |
|  | float | north,
|  | float | south,
|  | float | east,
|  | float | west,
|  | Marble.GeoDataCoordinates.Unit | unit=GeoDataCoordinates.Radian
| ) |  |  |

__init__ | ( | self, |
|  | Marble.GeoDataLatLonBox | a0
| ) |  |  |

boundaries | ( | self, |
|  | float | north,
|  | float | south,
|  | float | east,
|  | float | west,
|  | Marble.GeoDataCoordinates.Unit | unit=GeoDataCoordinates.Radian
| ) |  |  |

bool contains | ( | self, |
|  | Marble.GeoDataPoint | a0
| ) |  |  |

bool contains | ( | self, |
|  | Marble.GeoDataCoordinates | a0
| ) |  |  |

bool contains | ( | self, |
|  | Marble.GeoDataLatLonBox | a0
| ) |  |  |

bool crossesDateLine | ( |  | self ) |

Detect whether the bounding box crosses the IDL.

Returns:
  true the bounding box crosses the +/-180 deg longitude.

false the bounding box doesn't cross the +/-180 deg longitude.

float east | ( | self, |
|  | Marble.GeoDataCoordinates.Unit | unit=GeoDataCoordinates.Radian
| ) |  |  |

Get the eastern boundary of the bounding box.

Returns:
  the longitude of the eastern boundary.

Marble.GeoDataLatLonBox fromCoordinates | ( | QVector | coordinates
| ) |  |  |

Create a bounding box from a set of geographic points.

Returns:
  the bounding box that contains the geographic points. NOTE: Use fromLineString for line strings!

Marble.GeoDataLatLonBox fromLineString | ( | Marble.GeoDataLineString | lineString
| ) |  |  |

Create the smallest bounding box from a line string.

Returns:
  the smallest bounding box that contains the linestring.

float height | ( | self, |
|  | Marble.GeoDataCoordinates.Unit | unit=GeoDataCoordinates.Radian
| ) |  |  |

Get the height of the latitude interval

Returns:
  the angle covered by the latitude range.

bool intersects | ( | self, |
|  | Marble.GeoDataLatLonBox | a0
| ) |  |  |

bool isFolder | ( |  | self ) |

bool isNull | ( |  | self ) |

Indicates whether the bounding box only contains a single 2D point ("singularity").

Returns:
  Return value is true if the height and the width of the bounding box equal zero.

float north | ( | self, |
|  | Marble.GeoDataCoordinates.Unit | unit=GeoDataCoordinates.Radian
| ) |  |  |

Get the northern boundary of the bounding box.

Returns:
  the latitude of the northern boundary.

pack | ( | self, |
|  | QDataStream | stream
| ) |  |  |

Serialize the contents of the feature to stream.

float rotation | ( | self, |
|  | Marble.GeoDataCoordinates.Unit | unit=GeoDataCoordinates.Radian
| ) |  |  |

Get the rotation of the bounding box.

Returns:
  the rotation of the bounding box.

setBoundaries | ( | self, |
|  | float | north,
|  | float | south,
|  | float | east,
|  | float | west,
|  | Marble.GeoDataCoordinates.Unit | unit=GeoDataCoordinates.Radian
| ) |  |  |

setEast | ( | self, |
|  | float | east,
|  | Marble.GeoDataCoordinates.Unit | unit=GeoDataCoordinates.Radian
| ) |  |  |

setNorth | ( | self, |
|  | float | north,
|  | Marble.GeoDataCoordinates.Unit | unit=GeoDataCoordinates.Radian
| ) |  |  |

setRotation | ( | self, |
|  | float | rotation,
|  | Marble.GeoDataCoordinates.Unit | unit=GeoDataCoordinates.Radian
| ) |  |  |

setSouth | ( | self, |
|  | float | south,
|  | Marble.GeoDataCoordinates.Unit | unit=GeoDataCoordinates.Radian
| ) |  |  |

setWest | ( | self, |
|  | float | west,
|  | Marble.GeoDataCoordinates.Unit | unit=GeoDataCoordinates.Radian
| ) |  |  |

float south | ( | self, |
|  | Marble.GeoDataCoordinates.Unit | unit=GeoDataCoordinates.Radian
| ) |  |  |

Get the southern boundary of the bounding box.

Returns:
  the latitude of the southern boundary.

QString toString | ( | self, |
|  | Marble.GeoDataCoordinates.Unit | unit=GeoDataCoordinates.Radian
| ) |  |  |

Creates a text string of the bounding box

unpack | ( | self, |
|  | QDataStream | stream
| ) |  |  |

Unserialize the contents of the feature from stream.

float west | ( | self, |
|  | Marble.GeoDataCoordinates.Unit | unit=GeoDataCoordinates.Radian
| ) |  |  |

Get the western boundary of the bounding box.

Returns:
  the longitude of the western boundary.

float width | ( | self, |
|  | Marble.GeoDataCoordinates.Unit | unit=GeoDataCoordinates.Radian
| ) |  |  |

Get the width of the longitude interval

Returns:
  the angle covered by the longitude range.