Examples of StSPARQLSerializer


Examples of lupos.geo.serializer.StSPARQLSerializer

    {
        if(args.length==1)
        {
            Geometry geo = GeoHelper.getStSPARQLGeometry(args[0]);
            Geometry envelope = geo.getEnvelope();
            return new StSPARQLSerializer().toLiteral(envelope);
        }
        else
        {
            throw new TypeErrorException("Envelope Function expects exactly 1 arguments: one geometry object.");
        }
View Full Code Here

Examples of lupos.geo.serializer.StSPARQLSerializer

        if(args.length==2)
        {
            Geometry geo1 = GeoHelper.getStSPARQLGeometry(args[0]);
            Geometry geo2 = GeoHelper.getStSPARQLGeometry(args[1]);
            Geometry union = geo1.union(geo2);
            return new StSPARQLSerializer().toLiteral(union);
        }
        else
        {
            throw new TypeErrorException("Union Function expects exactly 2 arguments: two geometry objects.");
        }
View Full Code Here

Examples of lupos.geo.serializer.StSPARQLSerializer

    @Override
    public Object evaluate(final Object[] args) throws TypeErrorException {
        if(args.length==1) {
            final Geometry geo = GeoHelper.getStSPARQLGeometry(args[0]);
            final Geometry boundary = geo.getBoundary();
            return new StSPARQLSerializer().toLiteral(boundary);
        }
        else {
            throw new TypeErrorException("Boundary Function expects exactly 1 arguments: one geometry object.");
        }
    }
View Full Code Here

Examples of lupos.geo.serializer.StSPARQLSerializer

        if(args.length==2)
        {
            Geometry geo1 = GeoHelper.getStSPARQLGeometry(args[0]);
            double distance = Helper.getDouble(args[1]);
            Geometry buffer = geo1.buffer(distance);
            return new StSPARQLSerializer().toLiteral(buffer);
        }
        else
        {
            throw new TypeErrorException("Buffer Function expects exactly 2 arguments: two geometry objects.");
        }
View Full Code Here

Examples of lupos.geo.serializer.StSPARQLSerializer

        if(args.length==2)
        {
            Geometry geo1 = GeoHelper.getStSPARQLGeometry(args[0]);
            Geometry geo2 = GeoHelper.getStSPARQLGeometry(args[1]);
            Geometry intersection = geo1.intersection(geo2);
            return new StSPARQLSerializer().toLiteral(intersection);
        }
        else
        {
            throw new TypeErrorException("Intersection Function expects exactly 2 arguments: two geometry objects.");
        }
View Full Code Here

Examples of lupos.geo.serializer.StSPARQLSerializer

        if(args.length==2)
        {
            Geometry geo1 = GeoHelper.getStSPARQLGeometry(args[0]);
            Geometry geo2 = GeoHelper.getStSPARQLGeometry(args[1]);
            Geometry difference = geo1.difference(geo2);
            return new StSPARQLSerializer().toLiteral(difference);
        }
        else
        {
            throw new TypeErrorException("Difference Function expects exactly 2 arguments: two geometry objects.");
        }
View Full Code Here

Examples of lupos.geo.serializer.StSPARQLSerializer

    {
        if(args.length==1)
        {
            Geometry geo = GeoHelper.getStSPARQLGeometry(args[0]);
            Geometry convexHull = geo.convexHull();
            return new StSPARQLSerializer().toLiteral(convexHull);
        }
        else
        {
            throw new TypeErrorException("ConvexHull Function expects exactly 1 arguments: one geometry object.");
        }
View Full Code Here

Examples of lupos.geo.serializer.StSPARQLSerializer

    public Object evaluate(Object[] args) throws TypeErrorException
    {
        if(args.length==1)
        {
            Geometry geo = GeoHelper.getStSPARQLGeometry(args[0]);
            StSPARQLSerializer serializer = new StSPARQLSerializer();
            return serializer.toLiteral(geo);
        }
        else
        {
            throw new TypeErrorException("SRID Function expects exactly 1 arguments: A geometry.");
        }
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.