Package org.netmelody.cieye.core.observation

Examples of org.netmelody.cieye.core.observation.ObservationAgency


        this.directory = directory;
        this.foreignAgencies = foreignAgencies;
    }

    private PollingSpyHandler spyFor(Feature feature) {
        ObservationAgency latestAgency = foreignAgencies.agencyFor(feature.type());
        ObservationAgency currentAgency = agencies.get(feature.type());

        if (currentAgency != latestAgency) {
            agencies.put(feature.type(), latestAgency);
            handlers.invalidate(feature);
        }
View Full Code Here


        return handlers.getUnchecked(feature);
    }

    private PollingSpyHandler createSpyFor(Feature feature) {
        final ObservationAgency agency = foreignAgencies.agencyFor(feature.type());
        final CiSpy spy = agency.provideSpyFor(feature, network, directory);
        return new PollingSpyHandler(spy, feature);
    }
View Full Code Here

    private ObservationAgency makeAgencyFor(CiServerType type) {
        final String typeName = type.name();
        Iterator<ObservationAgency> agencies = available();
       
        while (agencies.hasNext()) {
            ObservationAgency agency = agencies.next();
            if (agency.canProvideSpyFor(type)) {
                return agency;
            }
        }
       
        throw new IllegalStateException("No CI Observation Module for " + typeName);
View Full Code Here

TOP

Related Classes of org.netmelody.cieye.core.observation.ObservationAgency

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.