Package org.apache.wink.common.model.app

Examples of org.apache.wink.common.model.app.AppAccept


        collection.setTitle(title);

        // Add Accept Media Types
        List<AppAccept> acceptMediaTypes = collection.getAccept();
        if (serviceDocumentCollection.getAccepts().isEmpty()) {
            AppAccept appAccept = new AppAccept();
            acceptMediaTypes.add(appAccept);
        } else {
            for (MediaType acceptMediaType : serviceDocumentCollection.getAccepts()) {
                AppAccept appAccept = new AppAccept();
                String appAcceptString = acceptMediaType.toString();
                appAccept.setValue(appAcceptString);
                acceptMediaTypes.add(appAccept);
            }
        }

        // Add Inline and OutOfline categories
View Full Code Here


        collection.setTitle(title);

        // Add Accept Media Types
        List<AppAccept> acceptMediaTypes = collection.getAccept();
        if (serviceDocumentCollection.getAccepts().isEmpty()) {
            AppAccept appAccept = new AppAccept();
            acceptMediaTypes.add(appAccept);
        } else {
            for (MediaType acceptMediaType : serviceDocumentCollection.getAccepts()) {
                AppAccept appAccept = new AppAccept();
                String appAcceptString = acceptMediaType.toString();
                appAccept.setValue(appAcceptString);
                acceptMediaTypes.add(appAccept);
            }
        }

        // Add Inline and OutOfline categories
View Full Code Here

        col.setBase("http://base/collection");
        col.setTitle(new AtomText("collection" + id));
        col.getOtherAttributes().put(new QName("anyAttirbCollection"), "anyAttribValueCollection");
        col.setHref("href" + id);

        AppAccept accept1 = new AppAccept();
        accept1.setValue("accept1");
        AppAccept accept2 = new AppAccept();
        accept2.setValue("accept2");
        col.getAccept().add(accept1);
        col.getAccept().add(accept2);

        col.getCategories().add(getInlineCategories());
        col.getCategories().add(getOutOfLineCategories());
View Full Code Here

TOP

Related Classes of org.apache.wink.common.model.app.AppAccept

Copyright © 2018 www.massapicom. 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.