Examples of object()


Examples of org.apache.isis.viewer.restfulobjects.applib.domainobjects.DomainObjectResource.object()

   
    private DomainObjectRepresentation givenDomainObjectRepresentationFor(final String domainType, String instanceId) throws JsonParseException, JsonMappingException, IOException {
        final DomainObjectResource domainObjectResource = client.getDomainObjectResource();

        final Response domainObjectResp = domainObjectResource.object(domainType, instanceId);
        final RestfulResponse<DomainObjectRepresentation> domainObjectJsonResp = RestfulResponse.ofT(domainObjectResp);
        assertThat(domainObjectJsonResp.getStatus().getFamily(), is(Family.SUCCESSFUL));

        final DomainObjectRepresentation domainObjectRepr = domainObjectJsonResp.getEntity();
        return domainObjectRepr;
View Full Code Here

Examples of org.apache.jackrabbit.mk.json.JsopBuilder.object()

        for (Revision rev : list) {
            if (!rev.hasPathChanged(path)) {
                if (count++ > maxEntries) {
                    break;
                }
                json.object();
                json.key("id").value(rev.id);
                json.key("ts").value(rev.timestamp);
                json.key("msg").value(rev.message);
                json.endObject();
            }
View Full Code Here

Examples of org.apache.jackrabbit.mk.json.JsopBuilder.object()

        JsopBuilder json = new JsopBuilder();
        json.array();
        for (Revision rev : list) {
            String jsop = rev.getPathChanges(path, blobSerializer);
            if (!jsop.isEmpty()) {
                json.object();
                json.key("id").value(rev.id);
                json.key("ts").value(rev.timestamp);
                json.key("msg").value(rev.message);
                json.key("changes").value(jsop);
                json.endObject();
View Full Code Here

Examples of org.apache.jackrabbit.mk.json.JsopBuilder.object()

            jsop.tag('+').key(s).object().key(s).value("x").endObject();
            rev = mk.commit("/", jsop.toString(),
                    null, null);
            nodes = mk.getNodes("/" + s, rev, 0, 0, 100, null);
            jsop = new JsopBuilder();
            jsop.object().key(s).value("x").
                    key(":childNodeCount").value(0).endObject();
            String n = jsop.toString();
            assertEquals(n, nodes);
            nodes = mk.getNodes("/", rev, 0, 0, 100, null);
            jsop = new JsopBuilder();
View Full Code Here

Examples of org.apache.jackrabbit.mk.json.JsopBuilder.object()

                    key(":childNodeCount").value(0).endObject();
            String n = jsop.toString();
            assertEquals(n, nodes);
            nodes = mk.getNodes("/", rev, 0, 0, 100, null);
            jsop = new JsopBuilder();
            jsop.object().key(s).object().endObject().
            key(":childNodeCount").value(1).endObject();
            n = jsop.toString();
            assertEquals(n, nodes);
            jsop = new JsopBuilder();
            jsop.tag('-').value(s);
View Full Code Here

Examples of org.apache.jackrabbit.mk.json.JsopBuilder.object()

            jsop.tag('+').key(s).object().key(s).value("x").endObject();
            rev = mk.commit("/", jsop.toString(),
                    null, null);
            nodes = mk.getNodes("/" + s, rev, 0, 0, 10, null);
            jsop = new JsopBuilder();
            jsop.object().key(s).value("x").
                    key(":childNodeCount").value(0).endObject();
            String n = jsop.toString();
            assertEquals(n, nodes);
            nodes = mk.getNodes("/", rev, 0, 0, 10, null);
            jsop = new JsopBuilder();
View Full Code Here

Examples of org.apache.jackrabbit.mk.json.JsopBuilder.object()

                    key(":childNodeCount").value(0).endObject();
            String n = jsop.toString();
            assertEquals(n, nodes);
            nodes = mk.getNodes("/", rev, 0, 0, 10, null);
            jsop = new JsopBuilder();
            jsop.object().key(s).object().endObject().
            key(":childNodeCount").value(1).endObject();
            n = jsop.toString();
            assertEquals(n, nodes);
            jsop = new JsopBuilder();
            jsop.tag('-').value(s);
View Full Code Here

Examples of org.apache.jackrabbit.mk.json.JsopBuilder.object()

                        // recurse
                        super.childNodeChanged(changed, newId);
                    } else {
                        buff.tag('^');
                        buff.key(p);
                        buff.object().endObject();
                        buff.newline();
                    }
                    ++levels;
                }
            }
View Full Code Here

Examples of org.apache.jackrabbit.mk.json.JsopBuilder.object()

        ArrayList<String> list = new ArrayList<String>();
        String root = new File(dir).getAbsolutePath();
        String parent = new File(dir).getParentFile().getAbsolutePath();
        addFiles(list, new File(root));
        JsopBuilder listing = new JsopBuilder();
        listing.object();
        for (String f : list) {
            FileInputStream in = new FileInputStream(f);
            String id = store.writeBlob(in);
            in.close();
            String name = f.substring(parent.length());
View Full Code Here

Examples of org.apache.jackrabbit.mk.json.JsopStream.object()

            return null;
        }
        JsopStream json = new JsopStream();
        boolean includeId = filter != null && filter.contains(":id");
        includeId |= filter != null && filter.contains(":hash");
        json.object();
        n.append(json, includeId);
        int max;
        if (maxChildNodes == -1) {
            max = Integer.MAX_VALUE;
            maxChildNodes = Integer.MAX_VALUE;
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.