package com.stevesoltys.owl.config;

import com.stevesoltys.owl.controller.component.OwlComponentController;
import com.stevesoltys.owl.exception.OwlConfigurationException;
import com.stevesoltys.owl.model.agent.Agent;
import com.stevesoltys.owl.model.component.OwlComponent;
import org.springframework.stereotype.Component;

import java.util.*;

/**
 * @author Steve Soltys
 */
@Component
public class OwlConfiguration {

    private final Map<OwlComponent, OwlComponentController> components = new HashMap<>();

    private final Set<Agent> agents = new HashSet<>();

    public void initialize(Map<String, Object> configuration) throws OwlConfigurationException {

    }

    public Set<Agent> getAgents() {
        return agents;
    }
}

@@ -559,24 +559,52 @@
 shSet%3C%3E();%0A%0A
+    private boolean agent;%0A%0A
     public v
@@ -684,24 +684,778 @@
 Exception %7B%0A
+        setComponentConfiguration(configuration);%0A        setAgentConfiguration(configuration);%0A    %7D%0A%0A    private void setComponentConfiguration(Map%3CString, Object%3E configuration) throws OwlConfigurationException %7B%0A    %7D%0A%0A    private void setAgentConfiguration(Map%3CString, Object%3E configuration) throws OwlConfigurationException %7B%0A        if (!configuration.containsKey(%22agent%22)) %7B%0A            throw new OwlConfigurationException(%22Agent flag not found.%22);%0A        %7D%0A%0A        Object agentConfiguration = configuration.get(%22agent%22);%0A%0A        if (!(agentConfiguration instanceof Boolean)) %7B%0A            throw new OwlConfigurationException(%22Agent configuration option must be a boolean value.%22);%0A        %7D%0A%0A        this.agent = (Boolean) agentConfiguration;
 %0A    %7D%0A%0A    
@@ -1514,11 +1514,71 @@
 s;%0A    %7D
+%0A%0A    public boolean isAgent() %7B%0A        return agent;%0A    %7D
 %0A%7D%0A

Add agent flag to OwlConfiguration