Package com.vividsolutions.jts.io

Examples of com.vividsolutions.jts.io.ByteOrderDataInStream.readInt()


    public Geometry read(InStream is) throws IOException {
        ByteOrderDataInStream dis = new ByteOrderDataInStream(is);
        dis.setOrder(ByteOrderValues.LITTLE_ENDIAN);

        srid = dis.readInt();
        version = dis.readByte();
        serializationProps = dis.readByte();
        hasZ = (serializationProps & 1) == 1;
        hasM = (serializationProps & 2) == 2;
        singlePoint = (serializationProps & 8) == 8;
View Full Code Here


        singleLine = (serializationProps & 16) == 16;
        numberOfPoints = 1;
        if (singleLine) {
            numberOfPoints = 2;
        } else if (!singlePoint) {
            numberOfPoints = dis.readInt();
        }
        //dimensionalFlag = DimensionalFlag.XY;
        dimensionalFlag = DimensionalFlag.d2D;
        if (hasM) {
            if (hasZ) {
View Full Code Here

            PointSequence points = createPoints(0, 2);
            return new LineString(points);

        } else {
            // figures
            int numberOfFigures = dis.readInt();
            figures = readFigures(dis, numberOfFigures);
            // shapes
            int numberOfShapes = dis.readInt();
            shapes = readShapes(dis, numberOfShapes);
            return decode(0);
View Full Code Here

        } else {
            // figures
            int numberOfFigures = dis.readInt();
            figures = readFigures(dis, numberOfFigures);
            // shapes
            int numberOfShapes = dis.readInt();
            shapes = readShapes(dis, numberOfShapes);
            return decode(0);
        }
    }
View Full Code Here

    byte byteOrder = dis.readByte();
    // default is big endian
    if (byteOrder == WKBConstants.wkbNDR)
      dis.setOrder(ByteOrderValues.LITTLE_ENDIAN);

    int geometryType = dis.readInt();
    if (geometryType==1001)
        di.setHasOGCWkbZTyps(true);
    rs.close();
    ps.close();
    } catch (SQLException e) {
View Full Code Here

        // set endianness
        ByteOrderDataInStream din = new ByteOrderDataInStream(in);
        din.setOrder(h.flags.getEndianess());

        // read the srid
        h.srid = din.readInt();

        // read the envlope
        if (h.flags.getEnvelopeIndicator() != EnvelopeType.NONE) {
            double x1 = din.readDouble();
            double x2 = din.readDouble();
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.