public Envelope unmarshalEnvelope(EnvelopeType src) { Envelope dest = new Envelope(); if (src.isSetLowerCorner()) dest.setLowerCorner(unmarshalDirectPosition(src.getLowerCorner())); if (src.isSetUpperCorner()) dest.setUpperCorner(unmarshalDirectPosition(src.getUpperCorner())); if (src.isSetCoord()) { for (CoordType coord : src.getCoord()) dest.addCoord(unmarshalCoord(coord)); } if (src.isSetPos()) { for (DirectPositionType pos : src.getPos()) dest.addPos(unmarshalDirectPosition(pos)); } if (src.isSetCoordinates()) dest.setCoordinates(unmarshalCoordinates(src.getCoordinates())); if (src.isSetSrsName()) dest.setSrsName(src.getSrsName()); if (src.isSetSrsDimension()) dest.setSrsDimension(src.getSrsDimension().intValue()); if (src.isSetAxisLabels()) dest.setAxisLabels(src.getAxisLabels()); if (src.isSetUomLabels()) dest.setUomLabels(src.getUomLabels()); return dest; }