Examples of Collective2Adapter


Examples of com.collective2.signalEntry.adapter.Collective2Adapter

        String password = "password";
        Integer systemId = 42;

        // simplest possible connection to collective2.com
        try {
            C2EntryServiceAdapter liveAdapter = new Collective2Adapter();
            C2ServiceFactory factory = new C2ServiceFactory(liveAdapter);
            C2EntryService entryService = factory.signalEntryService(password,systemId);
            assertNotNull(entryService);
        } catch (Exception e) {
            e.printStackTrace();
View Full Code Here

Examples of com.collective2.signalEntry.adapter.Collective2Adapter

        // saves the requests to disk in case of unexpected shutdown while
        // retrying to transmit.
        try {
            C2EntryServiceJournal journal = new C2EntryServiceLogFileJournal(file, rollingLogLimit);

            C2EntryServiceAdapter liveAdapter = new Collective2Adapter();
            C2ServiceFactory factory = new C2ServiceFactory(liveAdapter, journal);
            C2EntryService entryService = factory.signalEntryService(password,systemId);
            assertNotNull(entryService);
        } catch (Exception e) {
            e.printStackTrace();
View Full Code Here

Examples of com.collective2.signalEntry.adapter.Collective2Adapter

        // after .send() is called on signals the user will be prompted at the
        // console prompt for approval before transmission. The included class is just
        // an example and can be implemented with other GUI technologies.
        try {
            C2EntryServiceAdapter liveAdapter = new Collective2Adapter();
            C2EntryHumanApproval approval = new ApprovalRequestableConsole();
            C2ServiceFactory factory = new C2ServiceFactory(liveAdapter,approval);
            C2EntryService entryService = factory.signalEntryService(password,systemId);
            assertNotNull(entryService);
        } catch (Exception e) {
View Full Code Here

Examples of com.collective2.signalEntry.adapter.Collective2Adapter

    // pull system properties that will be added to the IDE and never the
    // project

    @BeforeClass
    public static void initService() {
        C2EntryServiceAdapter backEnd = new Collective2Adapter();
        C2ServiceFactory factory = new C2ServiceFactory(backEnd);

        commonSystemId = System.getProperty(PROPERTY_KEY_SYSTEM_ID);
        commonPassword = System.getProperty(PROPERTY_KEY_PASSWORD);
        commonEMail = System.getProperty(PROPERTY_KEY_EMAIL);
View Full Code Here

Examples of com.collective2.signalEntry.adapter.Collective2Adapter

    private final static long networkDownRetryDelay = 10000l;//try every 10 seconds
    protected final ResponseManager responseManager;

    public C2ServiceFactory() {
        this.responseManager = new ResponseManager(new Collective2Adapter(),
                new C2EntryServiceMemoryJournal(),
                C2EntryHumanApproval.ApproveAll,
                networkDownRetryDelay);
    }
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.