Checkstyle enforcer 57/457/3
authorGiovanni Meo <gmeo@cisco.com>
Wed, 12 Jun 2013 15:43:29 +0000 (17:43 +0200)
committerGiovanni Meo <gmeo@cisco.com>
Wed, 12 Jun 2013 15:43:29 +0000 (17:43 +0200)
Started to enforce checkstyle, if the code style doesn't match the
checkstyle settings build will break. This is needed in order to make
sure folks comply to one code style and don't start diverging.

For now the enforcement is only limited to:
- make sure no TABS are present in the java files
- make sure that no trailing whitespaces are present

Along with code style enforcement updates all the files that didn't
comply else compilation would not be successful.

Added new exclusion in .gitignore

Added new parent for commons.opendaylight, please read the README in
the commons.parent project for the reason for it.

Make sure the violation of checkstyle are reported on the console to
avoid for a developer to be able to dig through the log in the target
directory

Change-Id: I4e35aa74e685e5cebb8182caf0b3b39da0906948
Signed-off-by: Giovanni Meo <gmeo@cisco.com>
229 files changed:
.gitignore
opendaylight/arphandler/src/test/java/org/opendaylight/controller/arphandler/internal/ArphandlerTest.java
opendaylight/clustering/integrationtest/src/test/resources/logback.xml
opendaylight/clustering/test/src/test/java/org/opendaylight/controller/clustering/test/internal/TestClusteringTest.java
opendaylight/commons/concepts/pom.xml
opendaylight/commons/concepts/src/main/java/org/opendaylight/controller/concepts/transform/Acceptor.java
opendaylight/commons/concepts/src/main/java/org/opendaylight/controller/concepts/transform/AggregateTransformer.java
opendaylight/commons/concepts/src/main/java/org/opendaylight/controller/concepts/transform/CompositeClassBasedTransformer.java
opendaylight/commons/concepts/src/main/java/org/opendaylight/controller/concepts/transform/InputClassBasedTransformer.java
opendaylight/commons/concepts/src/main/java/org/opendaylight/controller/concepts/transform/RuleBasedTransformer.java
opendaylight/commons/concepts/src/main/java/org/opendaylight/controller/concepts/transform/SimpleConditionalTransformer.java
opendaylight/commons/concepts/src/main/java/org/opendaylight/controller/concepts/transform/Transformer.java
opendaylight/commons/integrationtest/pom.xml
opendaylight/commons/opendaylight/pom.xml
opendaylight/commons/opendaylight/space_and_tabs_checks.xml [new file with mode: 0644]
opendaylight/commons/parent/README [new file with mode: 0644]
opendaylight/commons/parent/logback.xml [new file with mode: 0644]
opendaylight/commons/parent/pom.xml [new file with mode: 0644]
opendaylight/commons/parent/space_and_tabs_checks.xml [new file with mode: 0644]
opendaylight/commons/parent/sun_coding_style.xml [new file with mode: 0644]
opendaylight/configuration/implementation/src/main/java/org/opendaylight/controller/configuration/internal/ConfigurationContainerImpl.java
opendaylight/configuration/implementation/src/main/java/org/opendaylight/controller/configuration/internal/ConfigurationImpl.java
opendaylight/configuration/implementation/src/test/java/org/opendaylight/controller/configuration/internal/ConfigurationAwareTest.java
opendaylight/configuration/implementation/src/test/java/org/opendaylight/controller/configuration/internal/ConfigurationContainerAwareTest.java
opendaylight/configuration/implementation/src/test/java/org/opendaylight/controller/configuration/internal/ConfigurationContainerImplTest.java
opendaylight/configuration/implementation/src/test/java/org/opendaylight/controller/configuration/internal/ConfigurationImplTest.java
opendaylight/containermanager/api/src/main/java/org/opendaylight/controller/containermanager/IContainerManager.java
opendaylight/containermanager/implementation/src/test/java/org/opendaylight/controller/containermanager/internal/ContainerImplTest.java
opendaylight/containermanager/implementation/src/test/java/org/opendaylight/controller/containermanager/internal/ContainerManagerTest.java
opendaylight/forwarding/staticrouting/src/main/java/org/opendaylight/controller/forwarding/staticrouting/IForwardingStaticRouting.java
opendaylight/forwarding/staticrouting/src/main/java/org/opendaylight/controller/forwarding/staticrouting/StaticRouteConfig.java
opendaylight/forwarding/staticrouting/src/main/java/org/opendaylight/controller/forwarding/staticrouting/internal/StaticRoutingImplementation.java
opendaylight/forwarding/staticrouting/src/test/java/org/opendaylight/controller/forwarding/staticrouting/StaticRouteConfigTest.java
opendaylight/forwarding/staticrouting/src/test/java/org/opendaylight/controller/forwarding/staticrouting/StaticRouteTest.java
opendaylight/forwarding/staticrouting/src/test/java/org/opendaylight/controller/forwarding/staticrouting/internal/StaticRoutingImplementationTest.java
opendaylight/forwardingrulesmanager/api/src/main/java/org/opendaylight/controller/forwardingrulesmanager/FlowEntry.java
opendaylight/forwardingrulesmanager/api/src/main/java/org/opendaylight/controller/forwardingrulesmanager/FlowEntryInstall.java
opendaylight/forwardingrulesmanager/api/src/main/java/org/opendaylight/controller/forwardingrulesmanager/IForwardingRulesManager.java
opendaylight/forwardingrulesmanager/api/src/main/java/org/opendaylight/controller/forwardingrulesmanager/IForwardingRulesManagerAware.java
opendaylight/forwardingrulesmanager/api/src/main/java/org/opendaylight/controller/forwardingrulesmanager/PortGroup.java
opendaylight/forwardingrulesmanager/api/src/main/java/org/opendaylight/controller/forwardingrulesmanager/PortGroupChangeListener.java
opendaylight/forwardingrulesmanager/api/src/main/java/org/opendaylight/controller/forwardingrulesmanager/PortGroupConfig.java
opendaylight/forwardingrulesmanager/api/src/main/java/org/opendaylight/controller/forwardingrulesmanager/PortGroupProvider.java
opendaylight/forwardingrulesmanager/implementation/src/main/java/org/opendaylight/controller/forwardingrulesmanager/internal/Activator.java
opendaylight/forwardingrulesmanager/implementation/src/main/java/org/opendaylight/controller/forwardingrulesmanager/internal/ForwardingRulesManagerImpl.java
opendaylight/hosttracker/api/src/main/java/org/opendaylight/controller/hosttracker/IfHostListener.java
opendaylight/hosttracker/api/src/main/java/org/opendaylight/controller/hosttracker/IfIptoHost.java
opendaylight/hosttracker/api/src/main/java/org/opendaylight/controller/hosttracker/IfNewHostNotify.java
opendaylight/hosttracker/api/src/main/java/org/opendaylight/controller/hosttracker/hostAware/IHostFinder.java
opendaylight/hosttracker/api/src/test/java/org/opendaylight/controller/hosttracker/hostAware/HostNodeConnectorTest.java
opendaylight/hosttracker/implementation/src/main/java/org/opendaylight/controller/hosttracker/internal/HostTrackerCallable.java
opendaylight/hosttracker/implementation/src/test/java/org/opendaylight/controller/hosttracker/internal/HostTrackerTest.java
opendaylight/logging/bridge/src/main/java/org/opendaylight/controller/logging/bridge/internal/Activator.java
opendaylight/northbound/commons/src/main/java/org/opendaylight/controller/northbound/commons/exception/package-info.java
opendaylight/northbound/commons/src/main/java/org/opendaylight/controller/northbound/commons/utils/NorthboundUtils.java
opendaylight/northbound/flowprogrammer/src/main/java/org/opendaylight/controller/flowprogrammer/northbound/FlowConfigs.java
opendaylight/northbound/flowprogrammer/src/main/java/org/opendaylight/controller/flowprogrammer/northbound/FlowProgrammerNorthbound.java
opendaylight/northbound/hosttracker/src/main/java/org/opendaylight/controller/hosttracker/northbound/HostTrackerNorthbound.java
opendaylight/northbound/hosttracker/src/main/java/org/opendaylight/controller/hosttracker/northbound/Hosts.java
opendaylight/northbound/integrationtest/src/test/java/org/opendaylight/controller/northbound/integrationtest/NorthboundIT.java
opendaylight/northbound/staticrouting/src/main/java/org/opendaylight/controller/forwarding/staticrouting/northbound/StaticRoutes.java
opendaylight/northbound/staticrouting/src/main/java/org/opendaylight/controller/forwarding/staticrouting/northbound/StaticRoutingNorthbound.java
opendaylight/northbound/statistics/src/main/java/org/opendaylight/controller/statistics/northbound/AllFlowStatistics.java
opendaylight/northbound/statistics/src/main/java/org/opendaylight/controller/statistics/northbound/AllPortStatistics.java
opendaylight/northbound/statistics/src/main/java/org/opendaylight/controller/statistics/northbound/FlowStatistics.java
opendaylight/northbound/statistics/src/main/java/org/opendaylight/controller/statistics/northbound/PortStatistics.java
opendaylight/northbound/statistics/src/main/java/org/opendaylight/controller/statistics/northbound/StatisticsNorthbound.java
opendaylight/northbound/subnets/src/main/java/org/opendaylight/controller/subnets/northbound/SubnetConfigs.java
opendaylight/northbound/subnets/src/main/java/org/opendaylight/controller/subnets/northbound/SubnetsNorthboundJAXRS.java
opendaylight/northbound/switchmanager/src/main/java/org/opendaylight/controller/switchmanager/northbound/NodeConnectors.java
opendaylight/northbound/switchmanager/src/main/java/org/opendaylight/controller/switchmanager/northbound/Nodes.java
opendaylight/northbound/switchmanager/src/test/java/org/opendaylight/controller/switchmanager/northbound/SwitchManagerNorthboundTest.java
opendaylight/northbound/topology/src/main/java/org/opendaylight/controller/topology/northbound/Topology.java
opendaylight/northbound/topology/src/main/java/org/opendaylight/controller/topology/northbound/TopologyNorthboundJAXRS.java
opendaylight/northbound/topology/src/main/java/org/opendaylight/controller/topology/northbound/TopologyUserLinks.java
opendaylight/northbound/topology/src/test/java/org/opendaylight/controller/topology/northbound/TopologyTest.java
opendaylight/protocol_plugins/openflow/src/main/java/org/opendaylight/controller/protocol_plugin/openflow/IInventoryShimInternalListener.java
opendaylight/protocol_plugins/openflow/src/main/java/org/opendaylight/controller/protocol_plugin/openflow/IOFStatisticsManager.java
opendaylight/protocol_plugins/openflow/src/main/java/org/opendaylight/controller/protocol_plugin/openflow/IRefreshInternalProvider.java
opendaylight/protocol_plugins/openflow/src/main/java/org/opendaylight/controller/protocol_plugin/openflow/IStatisticsListener.java
opendaylight/protocol_plugins/openflow/src/main/java/org/opendaylight/controller/protocol_plugin/openflow/ITopologyServiceShimListener.java
opendaylight/protocol_plugins/openflow/src/main/java/org/opendaylight/controller/protocol_plugin/openflow/core/IController.java
opendaylight/protocol_plugins/openflow/src/main/java/org/opendaylight/controller/protocol_plugin/openflow/core/IMessageReadWrite.java
opendaylight/protocol_plugins/openflow/src/main/java/org/opendaylight/controller/protocol_plugin/openflow/core/ISwitch.java
opendaylight/protocol_plugins/openflow/src/main/java/org/opendaylight/controller/protocol_plugin/openflow/core/internal/Controller.java
opendaylight/protocol_plugins/openflow/src/main/java/org/opendaylight/controller/protocol_plugin/openflow/core/internal/MessageReadWriteService.java
opendaylight/protocol_plugins/openflow/src/main/java/org/opendaylight/controller/protocol_plugin/openflow/core/internal/PriorityMessage.java
opendaylight/protocol_plugins/openflow/src/main/java/org/opendaylight/controller/protocol_plugin/openflow/core/internal/SecureMessageReadWriteService.java
opendaylight/protocol_plugins/openflow/src/main/java/org/opendaylight/controller/protocol_plugin/openflow/internal/DataPacketMuxDemux.java
opendaylight/protocol_plugins/openflow/src/main/java/org/opendaylight/controller/protocol_plugin/openflow/internal/DescStatisticsConverter.java
opendaylight/protocol_plugins/openflow/src/main/java/org/opendaylight/controller/protocol_plugin/openflow/internal/DiscoveryService.java
opendaylight/protocol_plugins/openflow/src/main/java/org/opendaylight/controller/protocol_plugin/openflow/internal/FlowProgrammerNotifier.java
opendaylight/protocol_plugins/openflow/src/main/java/org/opendaylight/controller/protocol_plugin/openflow/internal/FlowProgrammerService.java
opendaylight/protocol_plugins/openflow/src/main/java/org/opendaylight/controller/protocol_plugin/openflow/internal/FlowStatisticsConverter.java
opendaylight/protocol_plugins/openflow/src/main/java/org/opendaylight/controller/protocol_plugin/openflow/internal/InventoryServiceHelper.java
opendaylight/protocol_plugins/openflow/src/main/java/org/opendaylight/controller/protocol_plugin/openflow/internal/OFStatisticsManager.java
opendaylight/protocol_plugins/openflow/src/main/java/org/opendaylight/controller/protocol_plugin/openflow/internal/PortConverter.java
opendaylight/protocol_plugins/openflow/src/main/java/org/opendaylight/controller/protocol_plugin/openflow/internal/PortStatisticsConverter.java
opendaylight/protocol_plugins/openflow/src/main/java/org/opendaylight/controller/protocol_plugin/openflow/internal/ReadServiceFilter.java
opendaylight/protocol_plugins/openflow/src/main/java/org/opendaylight/controller/protocol_plugin/openflow/internal/TopologyServices.java
opendaylight/protocol_plugins/openflow/src/main/java/org/opendaylight/controller/protocol_plugin/openflow/internal/Utils.java
opendaylight/protocol_plugins/openflow/src/main/java/org/opendaylight/controller/protocol_plugin/openflow/vendorextension/v6extension/V6Error.java
opendaylight/protocol_plugins/openflow/src/main/java/org/opendaylight/controller/protocol_plugin/openflow/vendorextension/v6extension/V6FlowMod.java
opendaylight/protocol_plugins/openflow/src/main/java/org/opendaylight/controller/protocol_plugin/openflow/vendorextension/v6extension/V6Match.java
opendaylight/protocol_plugins/openflow/src/main/java/org/opendaylight/controller/protocol_plugin/openflow/vendorextension/v6extension/V6StatsReply.java
opendaylight/protocol_plugins/openflow/src/main/java/org/opendaylight/controller/protocol_plugin/openflow/vendorextension/v6extension/V6StatsRequest.java
opendaylight/protocol_plugins/stub/src/main/java/org/opendaylight/controller/protocol_plugins/stub/internal/Activator.java
opendaylight/protocol_plugins/stub/src/main/java/org/opendaylight/controller/protocol_plugins/stub/internal/FlowProgrammerService.java
opendaylight/protocol_plugins/stub/src/main/java/org/opendaylight/controller/protocol_plugins/stub/internal/InventoryService.java
opendaylight/protocol_plugins/stub/src/main/java/org/opendaylight/controller/protocol_plugins/stub/internal/ReadService.java
opendaylight/protocol_plugins/stub/src/main/java/org/opendaylight/controller/protocol_plugins/stub/internal/StubNodeConnectorFactory.java
opendaylight/protocol_plugins/stub/src/main/java/org/opendaylight/controller/protocol_plugins/stub/internal/StubNodeFactory.java
opendaylight/routing/dijkstra_implementation/src/main/java/org/opendaylight/controller/routing/dijkstra_implementation/internal/DijkstraImplementation.java
opendaylight/sal/api/src/main/java/org/opendaylight/controller/sal/action/Action.java
opendaylight/sal/api/src/main/java/org/opendaylight/controller/sal/action/Output.java
opendaylight/sal/api/src/main/java/org/opendaylight/controller/sal/action/PushVlan.java
opendaylight/sal/api/src/main/java/org/opendaylight/controller/sal/action/SetDlDst.java
opendaylight/sal/api/src/main/java/org/opendaylight/controller/sal/action/SetDlSrc.java
opendaylight/sal/api/src/main/java/org/opendaylight/controller/sal/action/SetDlType.java
opendaylight/sal/api/src/main/java/org/opendaylight/controller/sal/action/SetNwDst.java
opendaylight/sal/api/src/main/java/org/opendaylight/controller/sal/action/SetNwSrc.java
opendaylight/sal/api/src/main/java/org/opendaylight/controller/sal/action/SetNwTos.java
opendaylight/sal/api/src/main/java/org/opendaylight/controller/sal/action/SetTpDst.java
opendaylight/sal/api/src/main/java/org/opendaylight/controller/sal/action/SetTpSrc.java
opendaylight/sal/api/src/main/java/org/opendaylight/controller/sal/action/SetVlanCfi.java
opendaylight/sal/api/src/main/java/org/opendaylight/controller/sal/action/SetVlanId.java
opendaylight/sal/api/src/main/java/org/opendaylight/controller/sal/action/SetVlanPcp.java
opendaylight/sal/api/src/main/java/org/opendaylight/controller/sal/authorization/AppRoleLevel.java
opendaylight/sal/api/src/main/java/org/opendaylight/controller/sal/authorization/IResourceAuthorization.java
opendaylight/sal/api/src/main/java/org/opendaylight/controller/sal/authorization/UserLevel.java
opendaylight/sal/api/src/main/java/org/opendaylight/controller/sal/core/Actions.java
opendaylight/sal/api/src/main/java/org/opendaylight/controller/sal/core/AdvertisedBandwidth.java
opendaylight/sal/api/src/main/java/org/opendaylight/controller/sal/core/Bandwidth.java
opendaylight/sal/api/src/main/java/org/opendaylight/controller/sal/core/Buffers.java
opendaylight/sal/api/src/main/java/org/opendaylight/controller/sal/core/Capabilities.java
opendaylight/sal/api/src/main/java/org/opendaylight/controller/sal/core/ComponentActivatorAbstractBase.java
opendaylight/sal/api/src/main/java/org/opendaylight/controller/sal/core/Config.java
opendaylight/sal/api/src/main/java/org/opendaylight/controller/sal/core/ContainerFlow.java
opendaylight/sal/api/src/main/java/org/opendaylight/controller/sal/core/PeerBandwidth.java
opendaylight/sal/api/src/main/java/org/opendaylight/controller/sal/core/SupportedBandwidth.java
opendaylight/sal/api/src/main/java/org/opendaylight/controller/sal/core/Tables.java
opendaylight/sal/api/src/main/java/org/opendaylight/controller/sal/discovery/IDiscoveryService.java
opendaylight/sal/api/src/main/java/org/opendaylight/controller/sal/flowprogrammer/Flow.java
opendaylight/sal/api/src/main/java/org/opendaylight/controller/sal/flowprogrammer/IFlowProgrammerService.java
opendaylight/sal/api/src/main/java/org/opendaylight/controller/sal/flowprogrammer/IPluginInFlowProgrammerService.java
opendaylight/sal/api/src/main/java/org/opendaylight/controller/sal/flowprogrammer/IPluginOutFlowProgrammerService.java
opendaylight/sal/api/src/main/java/org/opendaylight/controller/sal/inventory/IListenInventoryUpdates.java
opendaylight/sal/api/src/main/java/org/opendaylight/controller/sal/inventory/IPluginOutInventoryService.java
opendaylight/sal/api/src/main/java/org/opendaylight/controller/sal/match/Match.java
opendaylight/sal/api/src/main/java/org/opendaylight/controller/sal/match/MatchField.java
opendaylight/sal/api/src/main/java/org/opendaylight/controller/sal/match/MatchType.java
opendaylight/sal/api/src/main/java/org/opendaylight/controller/sal/packet/BitBufferHelper.java
opendaylight/sal/api/src/main/java/org/opendaylight/controller/sal/packet/ICMP.java
opendaylight/sal/api/src/main/java/org/opendaylight/controller/sal/packet/IPv4.java
opendaylight/sal/api/src/main/java/org/opendaylight/controller/sal/packet/LLDP.java
opendaylight/sal/api/src/main/java/org/opendaylight/controller/sal/packet/PacketException.java
opendaylight/sal/api/src/main/java/org/opendaylight/controller/sal/packet/RawPacket.java
opendaylight/sal/api/src/main/java/org/opendaylight/controller/sal/packet/UDP.java
opendaylight/sal/api/src/main/java/org/opendaylight/controller/sal/reader/FlowOnNode.java
opendaylight/sal/api/src/main/java/org/opendaylight/controller/sal/reader/NodeConnectorStatistics.java
opendaylight/sal/api/src/main/java/org/opendaylight/controller/sal/reader/NodeDescription.java
opendaylight/sal/api/src/main/java/org/opendaylight/controller/sal/reader/NodeTableStatistics.java
opendaylight/sal/api/src/main/java/org/opendaylight/controller/sal/topology/IListenTopoUpdates.java
opendaylight/sal/api/src/main/java/org/opendaylight/controller/sal/topology/IPluginOutTopologyService.java
opendaylight/sal/api/src/main/java/org/opendaylight/controller/sal/utils/GlobalConstants.java
opendaylight/sal/api/src/main/java/org/opendaylight/controller/sal/utils/HexEncode.java
opendaylight/sal/api/src/main/java/org/opendaylight/controller/sal/utils/IPProtocols.java
opendaylight/sal/api/src/main/java/org/opendaylight/controller/sal/utils/NetUtils.java
opendaylight/sal/api/src/main/java/org/opendaylight/controller/sal/utils/Status.java
opendaylight/sal/api/src/main/java/org/opendaylight/controller/sal/utils/StatusCode.java
opendaylight/sal/api/src/test/java/org/opendaylight/controller/sal/authorization/AuthorizationTest.java
opendaylight/sal/api/src/test/java/org/opendaylight/controller/sal/core/NodeTest.java
opendaylight/sal/api/src/test/java/org/opendaylight/controller/sal/match/MatchTest.java
opendaylight/sal/api/src/test/java/org/opendaylight/controller/sal/packet/BitBufferHelperTest.java
opendaylight/sal/api/src/test/java/org/opendaylight/controller/sal/packet/PacketTest.java
opendaylight/sal/api/src/test/java/org/opendaylight/controller/sal/reader/FlowOnNodeTest.java
opendaylight/sal/api/src/test/java/org/opendaylight/controller/sal/reader/NodeConnectorStatisticsTest.java
opendaylight/sal/api/src/test/java/org/opendaylight/controller/sal/reader/NodeDescriptionTest.java
opendaylight/sal/api/src/test/java/org/opendaylight/controller/sal/utils/EtherTypesTest.java
opendaylight/sal/api/src/test/java/org/opendaylight/controller/sal/utils/HexEncodeTest.java
opendaylight/sal/implementation/src/main/java/org/opendaylight/controller/sal/implementation/internal/Activator.java
opendaylight/sal/implementation/src/main/java/org/opendaylight/controller/sal/implementation/internal/FlowProgrammerService.java
opendaylight/sal/implementation/src/main/java/org/opendaylight/controller/sal/implementation/internal/Topology.java
opendaylight/sal/implementation/src/test/java/org/opendaylight/controller/sal/implementation/DataPacketServiceTest.java
opendaylight/samples/loadbalancer/src/main/java/org/opendaylight/controller/samples/loadbalancer/ConfigManager.java
opendaylight/samples/loadbalancer/src/main/java/org/opendaylight/controller/samples/loadbalancer/IConfigManager.java
opendaylight/samples/loadbalancer/src/main/java/org/opendaylight/controller/samples/loadbalancer/LBConst.java
opendaylight/samples/loadbalancer/src/main/java/org/opendaylight/controller/samples/loadbalancer/LBUtil.java
opendaylight/samples/loadbalancer/src/main/java/org/opendaylight/controller/samples/loadbalancer/entities/Client.java
opendaylight/samples/loadbalancer/src/main/java/org/opendaylight/controller/samples/loadbalancer/entities/Pool.java
opendaylight/samples/loadbalancer/src/main/java/org/opendaylight/controller/samples/loadbalancer/entities/PoolMember.java
opendaylight/samples/loadbalancer/src/main/java/org/opendaylight/controller/samples/loadbalancer/entities/VIP.java
opendaylight/samples/loadbalancer/src/main/java/org/opendaylight/controller/samples/loadbalancer/internal/Activator.java
opendaylight/samples/loadbalancer/src/main/java/org/opendaylight/controller/samples/loadbalancer/internal/LoadBalancerService.java
opendaylight/samples/loadbalancer/src/main/java/org/opendaylight/controller/samples/loadbalancer/policies/ILoadBalancingPolicy.java
opendaylight/samples/loadbalancer/src/main/java/org/opendaylight/controller/samples/loadbalancer/policies/RandomLBPolicy.java
opendaylight/samples/loadbalancer/src/main/java/org/opendaylight/controller/samples/loadbalancer/policies/RoundRobinLBPolicy.java
opendaylight/samples/loadbalancer/src/test/java/org/opendaylight/controller/samples/loadbalancer/internal/LoadBalancerTest.java
opendaylight/samples/northbound/loadbalancer/src/main/java/org/opendaylight/controller/samples/loadbalancer/northbound/LoadBalancerNorthbound.java
opendaylight/samples/northbound/loadbalancer/src/main/java/org/opendaylight/controller/samples/loadbalancer/northbound/NBConst.java
opendaylight/samples/northbound/loadbalancer/src/main/java/org/opendaylight/controller/samples/loadbalancer/northbound/Pools.java
opendaylight/samples/northbound/loadbalancer/src/main/java/org/opendaylight/controller/samples/loadbalancer/northbound/VIPs.java
opendaylight/samples/simpleforwarding/src/main/java/org/opendaylight/controller/samples/simpleforwarding/internal/SimpleForwardingImpl.java
opendaylight/statisticsmanager/api/src/main/java/org/opendaylight/controller/statisticsmanager/IStatisticsManager.java
opendaylight/switchmanager/api/src/main/java/org/opendaylight/controller/switchmanager/IInventoryListener.java
opendaylight/switchmanager/api/src/main/java/org/opendaylight/controller/switchmanager/ISpanAware.java
opendaylight/switchmanager/api/src/main/java/org/opendaylight/controller/switchmanager/ISwitchManager.java
opendaylight/switchmanager/api/src/main/java/org/opendaylight/controller/switchmanager/SwitchConfig.java
opendaylight/switchmanager/api/src/test/java/org/opendaylight/controller/switchmanager/SwitchTest.java
opendaylight/topologymanager/src/main/java/org/opendaylight/controller/topologymanager/TopologyUserLinkConfig.java
opendaylight/topologymanager/src/main/java/org/opendaylight/controller/topologymanager/internal/TopologyManagerImpl.java
opendaylight/topologymanager/src/test/java/org/opendaylight/controller/topologymanager/internal/TopologyManagerImplTest.java
opendaylight/usermanager/src/main/java/org/opendaylight/controller/usermanager/IAAAProvider.java
opendaylight/usermanager/src/main/java/org/opendaylight/controller/usermanager/ISessionManager.java
opendaylight/usermanager/src/main/java/org/opendaylight/controller/usermanager/ODLUserLevel.java
opendaylight/usermanager/src/main/java/org/opendaylight/controller/usermanager/internal/ServerConfig.java
opendaylight/usermanager/src/main/java/org/opendaylight/controller/usermanager/internal/UserConfig.java
opendaylight/usermanager/src/main/java/org/opendaylight/controller/usermanager/security/SessionManager.java
opendaylight/usermanager/src/test/java/org/opendaylight/controller/usermanager/AuthResponseTest.java
opendaylight/usermanager/src/test/java/org/opendaylight/controller/usermanager/internal/AuthenticatedUserTest.java
opendaylight/usermanager/src/test/java/org/opendaylight/controller/usermanager/internal/AuthorizationUserConfigTest.java
opendaylight/usermanager/src/test/java/org/opendaylight/controller/usermanager/internal/ServerConfigTest.java
opendaylight/web/flows/src/main/java/org/opendaylight/controller/flows/web/Flows.java
opendaylight/web/root/src/main/java/org/opendaylight/controller/web/DaylightWebAdmin.java
opendaylight/web/root/src/main/java/org/opendaylight/controller/web/DaylightWebUtil.java
opendaylight/web/root/src/main/java/org/opendaylight/controller/web/IDaylightWeb.java
opendaylight/web/topology/src/main/java/org/opendaylight/controller/topology/web/Topology.java
opendaylight/web/topology/src/test/java/org/opendaylight/controller/topology/web/TopologyTest.java
opendaylight/web/troubleshoot/src/main/java/org/opendaylight/controller/troubleshoot/web/Troubleshoot.java

index b92845c..d1b8261 100644 (file)
@@ -12,3 +12,4 @@ target
 .project
 .settings
 MANIFEST.MF
+opendaylight/northbound/integrationtest/logs/*
index 5a6641c..19c8b4d 100644 (file)
@@ -16,14 +16,14 @@ import org.junit.Assert;
 import org.junit.Test;\r
 \r
 public class ArphandlerTest extends TestCase {\r
-        \r
-       @Test\r
-       public void testArphandlerCreation() {\r
-                       \r
-               ArpHandler ah = null;\r
-               ah = new ArpHandler();\r
-               Assert.assertTrue(ah != null);\r
-                       \r
-       }\r
+\r
+        @Test\r
+        public void testArphandlerCreation() {\r
+\r
+                ArpHandler ah = null;\r
+                ah = new ArpHandler();\r
+                Assert.assertTrue(ah != null);\r
+\r
+        }\r
 \r
 }\r
index 2d63ce5..6d9dfda 100644 (file)
@@ -1,5 +1,4 @@
 <configuration scan="true">
-
   <appender name="STDOUT" class="ch.qos.logback.core.ConsoleAppender">
     <encoder>
       <pattern>%d{HH:mm:ss.SSS} [%thread] %-5level %logger{36} - %msg%n
index fa00c7f..1142909 100644 (file)
@@ -17,51 +17,51 @@ import junit.framework.TestCase;
 \r
 public class TestClusteringTest extends TestCase {\r
 \r
-       @Test\r
-       public void testComplexClass() {\r
-               ComplexClass cc = new ComplexClass("cplxc1");\r
-               Assert.assertTrue(cc.whoAmI().equals("ComplexClass_cplxc1"));\r
-               cc.IAm("cplxc2");\r
-               Assert.assertTrue(cc.whoAmI().equals("ComplexClass_cplxc2"));\r
-       }\r
-               \r
-       @Test\r
-       public void testComplexClass1() {\r
-               ComplexClass1 cc1 = new ComplexClass1("cplxc1a");\r
-               Assert.assertTrue(cc1.whoAmI().equals("ComplexClass1_cplxc1a"));\r
-               cc1.IAm("cplxc1b");\r
-               Assert.assertTrue(cc1.whoAmI().equals("ComplexClass1_cplxc1b"));\r
-       }\r
-               \r
-               \r
-       @Test\r
-       public void testComplexContainer() {\r
-               ComplexContainer cplxcontnr1 = new ComplexContainer("cct1", 5);\r
-               Assert.assertTrue(cplxcontnr1.getIdentity().equals("[ComplexClass_cct1]-[ComplexClass1_cct1]"));\r
-               Assert.assertTrue(cplxcontnr1.getState() == 5);\r
-               \r
-               cplxcontnr1.setIdentity("cct2");\r
-               Assert.assertTrue(cplxcontnr1.getIdentity().equals("[ComplexClass_cct2]-[ComplexClass1_cct2]"));\r
-               \r
-               Assert.assertTrue(cplxcontnr1.toString().equals(\r
-                               "{ID:[ComplexClass_cct2]-[ComplexClass1_cct2],STATE:5}"));\r
-       }\r
-               \r
-       @Test\r
-       public void testStringContainer() {\r
-               StringContainer strcontainer1 = new StringContainer();\r
-               Assert.assertTrue(strcontainer1.getMystring() == null);\r
-               Assert.assertTrue(strcontainer1.hashCode() == 0);\r
-               \r
-               StringContainer strcontainer2 = new StringContainer("foo");\r
-               Assert.assertTrue(strcontainer2.getMystring() != null);\r
-               Assert.assertTrue(strcontainer2.hashCode() != 0);\r
-               \r
-               strcontainer1.setMystring("foo");\r
-               Assert.assertTrue(strcontainer2.equals(strcontainer1));\r
-               \r
-               Assert.assertTrue(strcontainer2.toString().equals("{foo}"));\r
-       }\r
-               \r
+        @Test\r
+        public void testComplexClass() {\r
+                ComplexClass cc = new ComplexClass("cplxc1");\r
+                Assert.assertTrue(cc.whoAmI().equals("ComplexClass_cplxc1"));\r
+                cc.IAm("cplxc2");\r
+                Assert.assertTrue(cc.whoAmI().equals("ComplexClass_cplxc2"));\r
+        }\r
+\r
+        @Test\r
+        public void testComplexClass1() {\r
+                ComplexClass1 cc1 = new ComplexClass1("cplxc1a");\r
+                Assert.assertTrue(cc1.whoAmI().equals("ComplexClass1_cplxc1a"));\r
+                cc1.IAm("cplxc1b");\r
+                Assert.assertTrue(cc1.whoAmI().equals("ComplexClass1_cplxc1b"));\r
+        }\r
+\r
+\r
+        @Test\r
+        public void testComplexContainer() {\r
+                ComplexContainer cplxcontnr1 = new ComplexContainer("cct1", 5);\r
+                Assert.assertTrue(cplxcontnr1.getIdentity().equals("[ComplexClass_cct1]-[ComplexClass1_cct1]"));\r
+                Assert.assertTrue(cplxcontnr1.getState() == 5);\r
+\r
+                cplxcontnr1.setIdentity("cct2");\r
+                Assert.assertTrue(cplxcontnr1.getIdentity().equals("[ComplexClass_cct2]-[ComplexClass1_cct2]"));\r
+\r
+                Assert.assertTrue(cplxcontnr1.toString().equals(\r
+                                "{ID:[ComplexClass_cct2]-[ComplexClass1_cct2],STATE:5}"));\r
+        }\r
+\r
+        @Test\r
+        public void testStringContainer() {\r
+                StringContainer strcontainer1 = new StringContainer();\r
+                Assert.assertTrue(strcontainer1.getMystring() == null);\r
+                Assert.assertTrue(strcontainer1.hashCode() == 0);\r
+\r
+                StringContainer strcontainer2 = new StringContainer("foo");\r
+                Assert.assertTrue(strcontainer2.getMystring() != null);\r
+                Assert.assertTrue(strcontainer2.hashCode() != 0);\r
+\r
+                strcontainer1.setMystring("foo");\r
+                Assert.assertTrue(strcontainer2.equals(strcontainer1));\r
+\r
+                Assert.assertTrue(strcontainer2.toString().equals("{foo}"));\r
+        }\r
+\r
 \r
 }\r
index 802b00e..9f3107d 100644 (file)
           <manifestLocation>${project.basedir}/META-INF</manifestLocation>\r
         </configuration>\r
       </plugin>\r
+      <plugin>\r
+        <groupId>org.apache.maven.plugins</groupId>\r
+        <artifactId>maven-checkstyle-plugin</artifactId>\r
+        <version>${checkstyle.version}</version>\r
+        <configuration>\r
+          <failsOnError>true</failsOnError>\r
+          <configLocation>${project.parent.parent.basedir}/space_and_tabs_checks.xml</configLocation>\r
+        </configuration>\r
+      </plugin>\r
     </plugins>\r
   </build>\r
   <dependencies>\r
index 9d34dfb..9e9774e 100644 (file)
@@ -12,7 +12,7 @@ package org.opendaylight.controller.concepts.transform;
 public interface Acceptor<I> {\r
 \r
     /**\r
-     * \r
+     *\r
      * @param input\r
      * @return true if input is accepted.\r
      */\r
index fa6408d..dae9499 100644 (file)
@@ -17,26 +17,26 @@ import java.util.concurrent.ConcurrentHashMap;
 /**\r
  * Transformer which aggregates multiple implementations of\r
  * {@link InputClassBasedTransformer}.\r
- * \r
+ *\r
  * The transformation process is driven by {@link Class} of input. The selection\r
  * of used {@link InputClassBasedTransformer} is done by using the {@link Class}\r
  * of input as a key to select the transformer.\r
- * \r
+ *\r
  * This approach provides quick resolution of transformer, but does not support\r
  * registering a super type of input to provide transformation support for all\r
  * subclasses, one must register a new instance of transformer for each valid\r
  * input class.\r
- * \r
+ *\r
  * If you need more flexible selection of transformation consider using\r
  * {@link CompositeConditionalTransformer} which is slower but most flexible or\r
  * {@link RuleBasedTransformer} which provides declarative approach for\r
  * transformation.\r
- * \r
+ *\r
  * See {@link #transform(Object)} for more information about tranformation\r
  * process.\r
- * \r
+ *\r
  * @author Tony Tkacik <ttkacik@cisco.com>\r
- * \r
+ *\r
  * @param <I>\r
  *            Input super-type\r
  * @param <P>\r
@@ -50,18 +50,18 @@ public abstract class CompositeClassBasedTransformer<I, P> implements
 \r
     /**\r
      * Transforms an input into instance of Product class.\r
-     * \r
+     *\r
      * The final registered transformer is the one which match following\r
      * condition:\r
-     * \r
+     *\r
      * <code>input.getClass() == transformer.getInputClass()</code>\r
-     * \r
+     *\r
      * This means that transformers are not resolved by class hierarchy, only\r
      * selected based on final class of the input. If you need more flexible\r
      * selection of transformation consider using\r
      * {@link CompositeConditionalTransformer} which is slower but more\r
      * flexible.\r
-     * \r
+     *\r
      */\r
     @Override\r
     public P transform(I input) {\r
@@ -76,11 +76,11 @@ public abstract class CompositeClassBasedTransformer<I, P> implements
 \r
     /**\r
      * Registers a new transformer.\r
-     * \r
+     *\r
      * The transformer is registered for class returned by\r
      * {@link InputClassBasedTransformer#getInputClass()}. Only one transformer\r
      * can be registered for particular input class.\r
-     * \r
+     *\r
      */\r
     public void addTransformer(\r
             InputClassBasedTransformer<I, ? extends I, P> transformer)\r
@@ -95,9 +95,9 @@ public abstract class CompositeClassBasedTransformer<I, P> implements
 \r
     /**\r
      * Removes an registered transformer.\r
-     * \r
+     *\r
      * Note: Removal is currently unsupported.\r
-     * \r
+     *\r
      * @param transformer\r
      *            Tranformer to be removed.\r
      * @throws IllegalArgumentException\r
@@ -108,7 +108,7 @@ public abstract class CompositeClassBasedTransformer<I, P> implements
             throws IllegalArgumentException {\r
         throw new UnsupportedOperationException("Not implemented yet");\r
     }\r
-    \r
+\r
     @Override\r
     public Collection<P> transformAll(Collection<? extends I> inputs) {\r
         Collection<P> ret = new ArrayList<P>();\r
index 3e6b39a..1ad849b 100644 (file)
@@ -10,15 +10,15 @@ package org.opendaylight.controller.concepts.transform;
 \r
 /**\r
  * Input class based transformer\r
- * \r
+ *\r
  * {@link Transformer} which accepts / transforms only specific classes of\r
  * input, and is useful if the selection of transformer should be based on the\r
  * class of the input and there is one-to-one mapping between input class and\r
  * transformer.\r
- * \r
- * \r
+ *\r
+ *\r
  * @author Tony Tkacik\r
- * \r
+ *\r
  * @param <S>\r
  *            Common supertype of input\r
  * @param <I>\r
@@ -31,7 +31,7 @@ public interface InputClassBasedTransformer<S, I extends S, P> extends
 \r
     /**\r
      * Returns an {@link Class} of input which is acceptable for transformation.\r
-     * \r
+     *\r
      * @return {@link Class} of input which is acceptable for transformation.\r
      */\r
     Class<? extends S> getInputClass();\r
index 9f717ea..820b94a 100644 (file)
@@ -12,15 +12,15 @@ import java.util.Set;
 \r
 /**\r
  * Transformer with set of acceptance rules\r
- * \r
+ *\r
  * The transformer provides a set of {@link Acceptor}s, which could be used to\r
  * verify if the input will produce result using the transformer.\r
- * \r
+ *\r
  * The transormer is able to produce result if ANY of associated\r
  * {@link Acceptor}s accepted result.\r
- * \r
+ *\r
  * @author Tony Tkacik\r
- * \r
+ *\r
  * @param <I>\r
  *            Input class for transformation\r
  * @param <P>\r
@@ -31,10 +31,10 @@ public interface RuleBasedTransformer<I, P> extends Transformer<I, P> {
     /**\r
      * Set of {@link Acceptor}, which could be used to verify if the input is\r
      * usable by transformer.\r
-     * \r
+     *\r
      * The transformer is able to produce result if ANY of associated\r
      * {@link Acceptor}s accepted result.\r
-     * \r
+     *\r
      * @return Set of input acceptance rules associated to this transformer.\r
      */\r
     Set<Acceptor<I>> getRules();\r
index 81e43c3..4d0aa03 100644 (file)
@@ -10,15 +10,15 @@ package org.opendaylight.controller.concepts.transform;
 \r
 /**\r
  * Simple condition-based transformer\r
- * \r
+ *\r
  * The transformer provides {@link #isAcceptable(Object)} method,\r
  * which could be used to query transformer if the input will produce\r
  * result.\r
- * \r
+ *\r
  * This interface is simplified version of {@link RuleBasedTransformer} - does not\r
  * provide decoupling of Acceptance rule from transformer, and should be used only\r
  * for simple use-cases.\r
- *  \r
+ *\r
  * @author Tony Tkacik\r
  *\r
  * @param <I> Input class for transformation\r
@@ -28,9 +28,9 @@ public interface SimpleConditionalTransformer<I,P> extends Transformer<I, P>, Ac
 \r
 \r
     /**\r
-     * Checks if the input is acceptable \r
+     * Checks if the input is acceptable\r
      * for processing by the transformer.\r
-     * \r
+     *\r
      * @return true it the input is acceptable for processing by transformer.\r
      */\r
     @Override\r
index f80ccff..18184e1 100644 (file)
@@ -10,7 +10,7 @@ package org.opendaylight.controller.concepts.transform;
 \r
 /**\r
  * Factory which produces product based on input object\r
- * \r
+ *\r
  * @author Tony Tkacik\r
  *\r
  * @param <I> Input\r
@@ -19,7 +19,7 @@ package org.opendaylight.controller.concepts.transform;
 public interface Transformer<I,P> {\r
     /**\r
      * Transforms input into instance of product.\r
-     * \r
+     *\r
      * @param input Input which drives transformation\r
      * @return Instance of product which was created from supplied input.\r
      */\r
index a438ad8..1f4b442 100644 (file)
@@ -55,6 +55,7 @@
       <plugin>
        <groupId>org.ops4j.pax.exam</groupId>
        <artifactId>maven-paxexam-plugin</artifactId>
+       <version>1.2.4</version>
         <executions>
           <execution>
             <id>generate-config</id>
           </execution>
         </executions>
       </plugin>
+      <plugin>
+        <groupId>org.apache.maven.plugins</groupId>
+        <artifactId>maven-checkstyle-plugin</artifactId>
+        <version>${checkstyle.version}</version>
+        <configuration>
+          <failsOnError>true</failsOnError>
+          <configLocation>${project.parent.parent.basedir}/space_and_tabs_checks.xml</configLocation>
+        </configuration>
+      </plugin>
+      <plugin>
+        <groupId>org.codehaus.mojo</groupId>
+        <artifactId>properties-maven-plugin</artifactId>
+        <version>${propertymavenplugin.version}</version>
+        <executions>
+          <execution>
+            <goals>
+              <goal>set-system-properties</goal>
+            </goals>
+            <configuration>
+              <properties>
+                <property>
+                  <name>logback.configurationFile</name>
+                  <value>${project.parent.parent.basedir}/logback.xml</value>
+                </property>
+              </properties>
+            </configuration>
+          </execution>
+        </executions>
+      </plugin>
     </plugins>
   </build>
 </project>
index 9814b5f..4062e18 100644 (file)
@@ -9,10 +9,16 @@
   <artifactId>commons.opendaylight</artifactId>
   <version>1.4.0-SNAPSHOT</version>
   <packaging>pom</packaging>
+  <parent>
+    <groupId>org.opendaylight.controller</groupId>
+    <artifactId>commons.parent</artifactId>
+    <version>1.0.0-SNAPSHOT</version>
+    <relativePath>../parent</relativePath>
+  </parent>
 
   <properties>
+    <propertymavenplugin.version>1.0-alpha-2</propertymavenplugin.version>
     <sonar.host.url>https://sonar.opendaylight.org/</sonar.host.url>
-    <nexusproxy>http://nexus.opendaylight.org/content</nexusproxy>
     <sitedeploy>dav:http://nexus.opendaylight.org/content/sites/site</sitedeploy>
     <siteplugin>3.2</siteplugin>
     <projectinfo>2.6</projectinfo>
@@ -32,6 +38,7 @@
     <jersey.version>1.17</jersey.version>
     <virgo.version>3.6.0.RELEASE</virgo.version>
     <geminiweb.version>2.2.0.RELEASE</geminiweb.version>
+    <checkstyle.version>2.10</checkstyle.version>
   </properties>
 
   <pluginRepositories>
       <plugin>
         <groupId>org.apache.maven.plugins</groupId>
         <artifactId>maven-checkstyle-plugin</artifactId>
-        <version>2.10</version>
+        <version>${checkstyle.version}</version>
       </plugin>
       <plugin>
         <groupId>org.apache.maven.plugins</groupId>
       <plugin>
         <groupId>org.codehaus.mojo</groupId>
         <artifactId>properties-maven-plugin</artifactId>
-        <version>1.0-alpha-2</version>
+        <version>${propertymavenplugin.version}</version>
         <executions>
           <execution>
             <goals>
               <properties>
                 <property>
                   <name>logback.configurationFile</name>
-                  <value>${project.parent.relativePath}/logback.xml</value>
+                  <value>${project.parent.basedir}/logback.xml</value>
                 </property>
               </properties>
             </configuration>
           <compilerSource>1.6</compilerSource>
           <compilerCompliance>1.6</compilerCompliance>
           <compilerTargetPlatform>1.6</compilerTargetPlatform>
-          <configFile>${project.parent.relativePath}/sun_coding_style.xml</configFile>
+          <configFile>${project.parent.basedir}/sun_coding_style.xml</configFile>
+        </configuration>
+      </plugin>
+      <plugin>
+        <groupId>org.apache.maven.plugins</groupId>
+        <artifactId>maven-checkstyle-plugin</artifactId>
+        <version>${checkstyle.version}</version>
+        <executions>
+          <execution>
+            <phase>process-sources</phase>
+            <goals>
+              <goal>check</goal>
+            </goals>
+          </execution>
+        </executions>
+        <configuration>
+          <failsOnError>true</failsOnError>
+          <configLocation>${project.parent.basedir}/space_and_tabs_checks.xml</configLocation>
+          <consoleOutput>true</consoleOutput>
+          <includeTestSourceDirectory>true</includeTestSourceDirectory>
         </configuration>
       </plugin>
       <plugin>
                   </action>
                 </pluginExecution>
                 <pluginExecution>
-                       <pluginExecutionFilter>
-                               <groupId>org.ops4j.pax.exam</groupId>
-                               <artifactId>maven-paxexam-plugin</artifactId>
-                               <versionRange>[1.2.4,)</versionRange>
-                               <goals>
-                                       <goal>generate-depends-file</goal>
-                               </goals>
-                       </pluginExecutionFilter>
-                       <action>
-                               <ignore></ignore>
-                       </action>
+                  <pluginExecutionFilter>
+                    <groupId>org.ops4j.pax.exam</groupId>
+                    <artifactId>maven-paxexam-plugin</artifactId>
+                    <versionRange>[1.2.4,)</versionRange>
+                    <goals>
+                      <goal>generate-depends-file</goal>
+                    </goals>
+                  </pluginExecutionFilter>
+                  <action>
+                    <ignore/>
+                  </action>
+                </pluginExecution>
+                <pluginExecution>
+                  <pluginExecutionFilter>
+                    <groupId>org.apache.maven.plugins</groupId>
+                    <artifactId>maven-checkstyle-plugin</artifactId>
+                    <versionRange>[2.0,)</versionRange>
+                    <goals>
+                      <goal>check</goal>
+                    </goals>
+                  </pluginExecutionFilter>
+                  <action>
+                    <ignore/>
+                  </action>
                 </pluginExecution>
               </pluginExecutions>
             </lifecycleMappingMetadata>
diff --git a/opendaylight/commons/opendaylight/space_and_tabs_checks.xml b/opendaylight/commons/opendaylight/space_and_tabs_checks.xml
new file mode 100644 (file)
index 0000000..49a5802
--- /dev/null
@@ -0,0 +1,17 @@
+<?xml version="1.0"?>\r
+<!DOCTYPE module PUBLIC\r
+    "-//Puppy Crawl//DTD Check Configuration 1.2//EN"\r
+    "http://www.puppycrawl.com/dtds/configuration_1_2.dtd">\r
+\r
+<module name="Checker">\r
+    <module name="FileTabCharacter">\r
+        <property name="eachLine" value="true"/>\r
+    </module>\r
+\r
+    <module name="RegexpSingleline">\r
+        <!-- \s matches whitespace character, $ matches end of line. -->\r
+        <property name="format" value="\s+$"/>\r
+        <property name="message" value="Line has trailing spaces."/>\r
+    </module>\r
+\r
+</module>\r
diff --git a/opendaylight/commons/parent/README b/opendaylight/commons/parent/README
new file mode 100644 (file)
index 0000000..4560dd4
--- /dev/null
@@ -0,0 +1,10 @@
+This contains a dummy parent project. The use case of this is for
+example the maven-checkstyle plugin call in commons/opendaylight in
+there the plugin references the spaces_tabs_checks.xml from the
+parent, it works well for all the childs of commons/opendaylight
+artifact but when trying to deploy that one itself it breaks because
+the plugin section will still refer to the parent when there is no
+parent.
+This fake parents allow to still set a parent for the
+commons/opendaylight even if pretty much empty or limited to the bare
+minimum and yet allow the commons/opendaylight to reference a parent.
diff --git a/opendaylight/commons/parent/logback.xml b/opendaylight/commons/parent/logback.xml
new file mode 100644 (file)
index 0000000..043ceef
--- /dev/null
@@ -0,0 +1,12 @@
+<configuration scan="true">
+  
+  <appender name="STDOUT" class="ch.qos.logback.core.ConsoleAppender">
+    <encoder>
+      <pattern>%date{"yyyy-MM-dd HH:mm:ss.SSS z"} [%thread] %-5level %logger{36} - %msg%n</pattern>
+    </encoder>
+  </appender>
+  
+  <root level="error">
+    <appender-ref ref="STDOUT" />
+  </root>
+</configuration>
diff --git a/opendaylight/commons/parent/pom.xml b/opendaylight/commons/parent/pom.xml
new file mode 100644 (file)
index 0000000..a3fb6b4
--- /dev/null
@@ -0,0 +1,33 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<project xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd" xmlns="http://maven.apache.org/POM/4.0.0"
+         xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
+  <modelVersion>4.0.0</modelVersion>
+  <prerequisites>
+    <maven>3.0</maven>
+  </prerequisites>
+  <groupId>org.opendaylight.controller</groupId>
+  <artifactId>commons.parent</artifactId>
+  <version>1.0.0-SNAPSHOT</version>
+  <packaging>pom</packaging>
+
+  <properties>
+    <nexusproxy>http://nexus.opendaylight.org/content</nexusproxy>
+  </properties>
+  <distributionManagement>
+    <!-- OpenDayLight Released artifact -->
+    <repository>
+      <id>opendaylight-release</id>
+      <url>${nexusproxy}/repositories/opendaylight.release/</url>
+    </repository>
+    <!-- OpenDayLight Snapshot artifact -->
+    <snapshotRepository>
+      <id>opendaylight-snapshot</id>
+      <url>${nexusproxy}/repositories/opendaylight.snapshot/</url>
+    </snapshotRepository>
+    <!-- Site deployment -->
+    <site>
+      <id>website</id>
+      <url>${sitedeploy}</url>
+    </site>
+  </distributionManagement>
+</project>
diff --git a/opendaylight/commons/parent/space_and_tabs_checks.xml b/opendaylight/commons/parent/space_and_tabs_checks.xml
new file mode 100644 (file)
index 0000000..49a5802
--- /dev/null
@@ -0,0 +1,17 @@
+<?xml version="1.0"?>\r
+<!DOCTYPE module PUBLIC\r
+    "-//Puppy Crawl//DTD Check Configuration 1.2//EN"\r
+    "http://www.puppycrawl.com/dtds/configuration_1_2.dtd">\r
+\r
+<module name="Checker">\r
+    <module name="FileTabCharacter">\r
+        <property name="eachLine" value="true"/>\r
+    </module>\r
+\r
+    <module name="RegexpSingleline">\r
+        <!-- \s matches whitespace character, $ matches end of line. -->\r
+        <property name="format" value="\s+$"/>\r
+        <property name="message" value="Line has trailing spaces."/>\r
+    </module>\r
+\r
+</module>\r
diff --git a/opendaylight/commons/parent/sun_coding_style.xml b/opendaylight/commons/parent/sun_coding_style.xml
new file mode 100644 (file)
index 0000000..f4516b9
--- /dev/null
@@ -0,0 +1,291 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<profiles version="12">
+<profile kind="CodeFormatterProfile" name="SunCodingStyle" version="12">
+<setting id="org.eclipse.jdt.core.formatter.comment.insert_new_line_before_root_tags" value="insert"/>
+<setting id="org.eclipse.jdt.core.formatter.disabling_tag" value="@formatter:off"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_after_comma_in_annotation" value="insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_parameters" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_type_declaration" value="insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_arguments" value="insert"/>
+<setting id="org.eclipse.jdt.core.formatter.brace_position_for_anonymous_type_declaration" value="end_of_line"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_colon_in_case" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_after_opening_brace_in_array_initializer" value="insert"/>
+<setting id="org.eclipse.jdt.core.formatter.comment.new_lines_at_block_boundaries" value="true"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_new_line_in_empty_annotation_declaration" value="insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_new_line_before_closing_brace_in_array_initializer" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_annotation" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.blank_lines_before_field" value="0"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_while" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.use_on_off_tags" value="false"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_annotation_type_member_declaration" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_new_line_before_else_in_if_statement" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_after_prefix_operator" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.keep_else_statement_on_same_line" value="false"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_after_ellipsis" value="insert"/>
+<setting id="org.eclipse.jdt.core.formatter.comment.insert_new_line_for_parameter" value="insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_annotation_type_declaration" value="insert"/>
+<setting id="org.eclipse.jdt.core.formatter.indent_breaks_compare_to_cases" value="true"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.alignment_for_multiple_fields" value="16"/>
+<setting id="org.eclipse.jdt.core.formatter.alignment_for_expressions_in_array_initializer" value="16"/>
+<setting id="org.eclipse.jdt.core.formatter.alignment_for_conditional_expression" value="80"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_for" value="insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_after_binary_operator" value="insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_question_in_wildcard" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.brace_position_for_array_initializer" value="end_of_line"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_enum_constant" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_new_line_before_finally_in_try_statement" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_local_variable" value="insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_new_line_before_catch_in_try_statement" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_while" value="insert"/>
+<setting id="org.eclipse.jdt.core.formatter.blank_lines_after_package" value="1"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_parameters" value="insert"/>
+<setting id="org.eclipse.jdt.core.formatter.continuation_indentation" value="2"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_after_postfix_operator" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.alignment_for_arguments_in_method_invocation" value="16"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_arguments" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_comma_in_superinterfaces" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.blank_lines_before_new_chunk" value="1"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_binary_operator" value="insert"/>
+<setting id="org.eclipse.jdt.core.formatter.blank_lines_before_package" value="0"/>
+<setting id="org.eclipse.jdt.core.compiler.source" value="1.7"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_after_comma_in_enum_constant_arguments" value="insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_constructor_declaration" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.comment.format_line_comments" value="true"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_arguments" value="insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_after_comma_in_enum_declarations" value="insert"/>
+<setting id="org.eclipse.jdt.core.formatter.join_wrapped_lines" value="true"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_block" value="insert"/>
+<setting id="org.eclipse.jdt.core.formatter.alignment_for_arguments_in_explicit_constructor_call" value="16"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_invocation_arguments" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.blank_lines_before_member_type" value="1"/>
+<setting id="org.eclipse.jdt.core.formatter.align_type_members_on_columns" value="false"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_enum_constant" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_for" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_method_declaration" value="insert"/>
+<setting id="org.eclipse.jdt.core.formatter.alignment_for_selector_in_method_invocation" value="16"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_switch" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_after_unary_operator" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_after_colon_in_case" value="insert"/>
+<setting id="org.eclipse.jdt.core.formatter.comment.indent_parameter_description" value="true"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_method_declaration" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_switch" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_enum_declaration" value="insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_parameters" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.comment.clear_blank_lines_in_block_comment" value="false"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_new_line_in_empty_type_declaration" value="insert"/>
+<setting id="org.eclipse.jdt.core.formatter.lineSplit" value="80"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_if" value="insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_between_brackets_in_array_type_reference" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_parenthesized_expression" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_comma_in_explicitconstructorcall_arguments" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_constructor_declaration" value="insert"/>
+<setting id="org.eclipse.jdt.core.formatter.blank_lines_before_first_class_body_declaration" value="0"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_method" value="insert"/>
+<setting id="org.eclipse.jdt.core.formatter.indentation.size" value="8"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_method_declaration" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.enabling_tag" value="@formatter:on"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_enum_constant" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.alignment_for_superclass_in_type_declaration" value="16"/>
+<setting id="org.eclipse.jdt.core.formatter.alignment_for_assignment" value="0"/>
+<setting id="org.eclipse.jdt.core.compiler.problem.assertIdentifier" value="error"/>
+<setting id="org.eclipse.jdt.core.formatter.tabulation.char" value="space"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_after_comma_in_constructor_declaration_parameters" value="insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_try_resources" value="insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_prefix_operator" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.indent_statements_compare_to_body" value="true"/>
+<setting id="org.eclipse.jdt.core.formatter.blank_lines_before_method" value="1"/>
+<setting id="org.eclipse.jdt.core.formatter.wrap_outer_expressions_when_nested" value="true"/>
+<setting id="org.eclipse.jdt.core.formatter.format_guardian_clause_on_one_line" value="false"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_colon_in_for" value="insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_cast" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.alignment_for_parameters_in_constructor_declaration" value="16"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_after_colon_in_labeled_statement" value="insert"/>
+<setting id="org.eclipse.jdt.core.formatter.brace_position_for_annotation_type_declaration" value="end_of_line"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_new_line_in_empty_method_body" value="insert"/>
+<setting id="org.eclipse.jdt.core.formatter.alignment_for_method_declaration" value="0"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_method_invocation" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_try" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_after_opening_bracket_in_array_allocation_expression" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_enum_constant" value="insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_comma_in_annotation" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation_type_declaration" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_declaration_throws" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_if" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.brace_position_for_switch" value="end_of_line"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_declaration_throws" value="insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_parenthesized_expression_in_return" value="insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_annotation" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_after_question_in_conditional" value="insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_after_question_in_wildcard" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_try" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_closing_bracket_in_array_allocation_expression" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.comment.preserve_white_space_between_code_and_line_comments" value="false"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_parenthesized_expression_in_throw" value="insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_arguments" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.compiler.problem.enumIdentifier" value="error"/>
+<setting id="org.eclipse.jdt.core.formatter.indent_switchstatements_compare_to_switch" value="false"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_ellipsis" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.brace_position_for_block" value="end_of_line"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_comma_in_for_inits" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.brace_position_for_method_declaration" value="end_of_line"/>
+<setting id="org.eclipse.jdt.core.formatter.compact_else_if" value="true"/>
+<setting id="org.eclipse.jdt.core.formatter.wrap_before_or_operator_multicatch" value="true"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_comma_in_array_initializer" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_after_comma_in_for_increments" value="insert"/>
+<setting id="org.eclipse.jdt.core.formatter.format_line_comment_starting_on_first_column" value="true"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_closing_bracket_in_array_reference" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_field" value="insert"/>
+<setting id="org.eclipse.jdt.core.formatter.comment.indent_root_tags" value="true"/>
+<setting id="org.eclipse.jdt.core.formatter.brace_position_for_enum_constant" value="end_of_line"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_comma_in_enum_declarations" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.alignment_for_union_type_in_multicatch" value="16"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_after_comma_in_explicitconstructorcall_arguments" value="insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_switch" value="insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_declaration_parameters" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_after_comma_in_superinterfaces" value="insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_comma_in_allocation_expression" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.tabulation.size" value="4"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_type_reference" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_new_line_after_opening_brace_in_array_initializer" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_after_closing_brace_in_block" value="insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_reference" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_constant" value="insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_arguments" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_constructor_declaration" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_comma_in_constructor_declaration_throws" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_if" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.comment.clear_blank_lines_in_javadoc_comment" value="false"/>
+<setting id="org.eclipse.jdt.core.formatter.alignment_for_throws_clause_in_constructor_declaration" value="16"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_after_assignment_operator" value="insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_assignment_operator" value="insert"/>
+<setting id="org.eclipse.jdt.core.formatter.indent_empty_lines" value="false"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_synchronized" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_after_closing_paren_in_cast" value="insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_declaration_parameters" value="insert"/>
+<setting id="org.eclipse.jdt.core.formatter.brace_position_for_block_in_case" value="end_of_line"/>
+<setting id="org.eclipse.jdt.core.formatter.number_of_empty_lines_to_preserve" value="1"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_method_declaration" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_catch" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_constructor_declaration" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_method_invocation" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_after_opening_bracket_in_array_reference" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.alignment_for_arguments_in_qualified_allocation_expression" value="16"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_after_and_in_type_parameter" value="insert"/>
+<setting id="org.eclipse.jdt.core.compiler.compliance" value="1.7"/>
+<setting id="org.eclipse.jdt.core.formatter.continuation_indentation_for_array_initializer" value="2"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_between_empty_brackets_in_array_allocation_expression" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_at_in_annotation_type_declaration" value="insert"/>
+<setting id="org.eclipse.jdt.core.formatter.alignment_for_arguments_in_allocation_expression" value="16"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_cast" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_unary_operator" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_parameterized_type_reference" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_anonymous_type_declaration" value="insert"/>
+<setting id="org.eclipse.jdt.core.formatter.keep_empty_array_initializer_on_one_line" value="false"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_declaration" value="insert"/>
+<setting id="org.eclipse.jdt.core.formatter.keep_imple_if_on_one_line" value="false"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_comma_in_constructor_declaration_parameters" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_parameters" value="insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_new_line_at_end_of_file_if_missing" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_after_colon_in_for" value="insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_colon_in_labeled_statement" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_comma_in_parameterized_type_reference" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_type_declaration" value="16"/>
+<setting id="org.eclipse.jdt.core.formatter.alignment_for_binary_expression" value="16"/>
+<setting id="org.eclipse.jdt.core.formatter.brace_position_for_enum_declaration" value="end_of_line"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_type" value="insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_while" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode" value="enabled"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_try" value="insert"/>
+<setting id="org.eclipse.jdt.core.formatter.put_empty_statement_on_new_line" value="true"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_new_line_after_label" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_parameter" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_parameters" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_method_invocation" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_new_line_before_while_in_do_statement" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.alignment_for_arguments_in_enum_constant" value="16"/>
+<setting id="org.eclipse.jdt.core.formatter.comment.format_javadoc_comments" value="true"/>
+<setting id="org.eclipse.jdt.core.formatter.comment.line_length" value="80"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_package" value="insert"/>
+<setting id="org.eclipse.jdt.core.formatter.blank_lines_between_import_groups" value="1"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_comma_in_enum_constant_arguments" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_semicolon" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.brace_position_for_constructor_declaration" value="end_of_line"/>
+<setting id="org.eclipse.jdt.core.formatter.number_of_blank_lines_at_beginning_of_method_body" value="0"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_colon_in_conditional" value="insert"/>
+<setting id="org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_type_header" value="true"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_annotation_type_member_declaration" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.wrap_before_binary_operator" value="true"/>
+<setting id="org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_enum_declaration_header" value="true"/>
+<setting id="org.eclipse.jdt.core.formatter.blank_lines_between_type_declarations" value="1"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_synchronized" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.indent_statements_compare_to_block" value="true"/>
+<setting id="org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_enum_declaration" value="16"/>
+<setting id="org.eclipse.jdt.core.formatter.join_lines_in_comments" value="true"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_question_in_conditional" value="insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_comma_in_multiple_field_declarations" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.alignment_for_compact_if" value="16"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_after_comma_in_for_inits" value="insert"/>
+<setting id="org.eclipse.jdt.core.formatter.indent_switchstatements_compare_to_cases" value="true"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_after_comma_in_array_initializer" value="insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_colon_in_default" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_and_in_type_parameter" value="insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_constructor_declaration" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.blank_lines_before_imports" value="1"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_after_colon_in_assert" value="insert"/>
+<setting id="org.eclipse.jdt.core.formatter.comment.format_html" value="true"/>
+<setting id="org.eclipse.jdt.core.formatter.alignment_for_throws_clause_in_method_declaration" value="16"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_parameters" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_allocation_expression" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_new_line_in_empty_anonymous_type_declaration" value="insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_after_colon_in_conditional" value="insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_parameterized_type_reference" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_for" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_postfix_operator" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.comment.format_source_code" value="true"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_synchronized" value="insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_after_comma_in_allocation_expression" value="insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_after_comma_in_constructor_declaration_throws" value="insert"/>
+<setting id="org.eclipse.jdt.core.formatter.alignment_for_parameters_in_method_declaration" value="16"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_closing_brace_in_array_initializer" value="insert"/>
+<setting id="org.eclipse.jdt.core.compiler.codegen.targetPlatform" value="1.7"/>
+<setting id="org.eclipse.jdt.core.formatter.alignment_for_resources_in_try" value="80"/>
+<setting id="org.eclipse.jdt.core.formatter.use_tabs_only_for_leading_indentations" value="true"/>
+<setting id="org.eclipse.jdt.core.formatter.alignment_for_arguments_in_annotation" value="0"/>
+<setting id="org.eclipse.jdt.core.formatter.comment.format_header" value="false"/>
+<setting id="org.eclipse.jdt.core.formatter.comment.format_block_comments" value="true"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_enum_constant" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.alignment_for_enum_constants" value="0"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_new_line_in_empty_block" value="insert"/>
+<setting id="org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_annotation_declaration_header" value="true"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_parenthesized_expression" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_parenthesized_expression" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_catch" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_comma_in_multiple_local_declarations" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_switch" value="insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_comma_in_for_increments" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_method_invocation" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_colon_in_assert" value="insert"/>
+<setting id="org.eclipse.jdt.core.formatter.brace_position_for_type_declaration" value="end_of_line"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_array_initializer" value="insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_between_empty_braces_in_array_initializer" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_method_declaration" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_for" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_catch" value="insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_parameterized_type_reference" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_after_comma_in_multiple_field_declarations" value="insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_annotation" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_after_comma_in_parameterized_type_reference" value="insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_invocation_arguments" value="insert"/>
+<setting id="org.eclipse.jdt.core.formatter.comment.new_lines_at_javadoc_boundaries" value="true"/>
+<setting id="org.eclipse.jdt.core.formatter.blank_lines_after_imports" value="1"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_after_comma_in_multiple_local_declarations" value="insert"/>
+<setting id="org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_enum_constant_header" value="true"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_for" value="insert"/>
+<setting id="org.eclipse.jdt.core.formatter.never_indent_line_comments_on_first_column" value="false"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_try_resources" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_arguments" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.never_indent_block_comments_on_first_column" value="false"/>
+<setting id="org.eclipse.jdt.core.formatter.keep_then_statement_on_same_line" value="false"/>
+</profile>
+</profiles>
index 3d0c565..9fb0c23 100644 (file)
@@ -51,9 +51,9 @@ public class ConfigurationContainerImpl implements
     }
 
     public int getConfigurationAwareListSize() {
-       return this.configurationAwareList.size();
+        return this.configurationAwareList.size();
     }
-    
+
     public void removeConfigurationContainerAware(
             IConfigurationContainerAware configurationAware) {
         this.configurationAwareList.remove(configurationAware);
@@ -88,16 +88,16 @@ public class ConfigurationContainerImpl implements
 
             Status status = configurationAware.saveConfiguration();
             if (!status.isSuccess()) {
-               success = false;
-               logger.info("Failed to save config for {}",
-                               configurationAware.getClass().getSimpleName());
+                success = false;
+                logger.info("Failed to save config for {}",
+                                configurationAware.getClass().getSimpleName());
             }
         }
         if (success) {
             return new Status(StatusCode.SUCCESS, null);
         } else {
             return new Status(StatusCode.INTERNALERROR,
-                       "Failed to Save All Configurations");
+                        "Failed to Save All Configurations");
         }
     }
 
index ee15b4a..20821f1 100644 (file)
@@ -41,11 +41,11 @@ public class ConfigurationImpl implements IConfigurationService {
     private Set<IConfigurationAware> configurationAwareList = (Set<IConfigurationAware>) Collections
             .synchronizedSet(new HashSet<IConfigurationAware>());
 
-    
+
     public int getConfigurationAwareListSize() {
-       return this.configurationAwareList.size();
+        return this.configurationAwareList.size();
     }
-    
+
     public void addConfigurationAware(IConfigurationAware configurationAware) {
         if (!this.configurationAwareList.contains(configurationAware)) {
             this.configurationAwareList.add(configurationAware);
@@ -81,18 +81,18 @@ public class ConfigurationImpl implements IConfigurationService {
     public Status saveConfigurations() {
         boolean success = true;
         for (IConfigurationAware configurationAware : configurationAwareList) {
-               Status status = configurationAware.saveConfiguration();
+                Status status = configurationAware.saveConfiguration();
             if (!status.isSuccess()) {
-               success = false;
-               logger.info("Failed to save config for {}",
-                               configurationAware.getClass().getName());
+                success = false;
+                logger.info("Failed to save config for {}",
+                                configurationAware.getClass().getName());
             }
         }
         if (success) {
             return new Status(StatusCode.SUCCESS, null);
         } else {
             return new Status(StatusCode.INTERNALERROR,
-                       "Failed to Save All Configurations");
+                        "Failed to Save All Configurations");
         }
     }
 
index e93b467..c9dd5e2 100644 (file)
@@ -22,11 +22,11 @@ import org.opendaylight.controller.sal.utils.Status;
 
 public class ConfigurationAwareTest implements
 IConfigurationAware {
-       
-       @Override
-       public Status saveConfiguration() {
-               return null;
-       }
+
+        @Override
+        public Status saveConfiguration() {
+                return null;
+        }
 
 
 }
index 52f3776..c5d6bdc 100644 (file)
@@ -23,13 +23,13 @@ import org.opendaylight.controller.sal.utils.Status;
 public class ConfigurationContainerAwareTest implements
          IConfigurationContainerAware {
 
-       
-       
-       
-       @Override
-       public Status saveConfiguration() {
-               return null;
-       }
-       
-       
+
+
+
+        @Override
+        public Status saveConfiguration() {
+                return null;
+        }
+
+
 }
index 1d704a1..a82a9f2 100644 (file)
@@ -14,52 +14,51 @@ import org.opendaylight.controller.configuration.IConfigurationContainerAware;
 
 
 
-public class ConfigurationContainerImplTest { 
-       
-
-       @Test
-       public void testAddRemoveSaveConfiguration() {
-               
-               ConfigurationContainerImpl configurationContainerImpl = new ConfigurationContainerImpl();
-               IConfigurationContainerAware testConfigurationContainerAware = new ConfigurationContainerAwareTest();
-               
-               configurationContainerImpl.addConfigurationContainerAware(testConfigurationContainerAware);
-               configurationContainerImpl.addConfigurationContainerAware(testConfigurationContainerAware);
-               
-               Assert.assertEquals(1, configurationContainerImpl.getConfigurationAwareListSize());
-               
-               IConfigurationContainerAware testConfigurationAware1 = new ConfigurationContainerAwareTest();
-               configurationContainerImpl.addConfigurationContainerAware(testConfigurationAware1);
-               
-               Assert.assertEquals(2, configurationContainerImpl.getConfigurationAwareListSize());
-               
-               IConfigurationContainerAware testConfigurationAware2 = new ConfigurationContainerAwareTest();
-               configurationContainerImpl.addConfigurationContainerAware(testConfigurationAware2);
-               
-               Assert.assertEquals(3, configurationContainerImpl.getConfigurationAwareListSize());
-               
-               IConfigurationContainerAware testConfigurationAware3 = new ConfigurationContainerAwareTest();
-               configurationContainerImpl.addConfigurationContainerAware(testConfigurationAware3);
-               
-               Assert.assertEquals(4, configurationContainerImpl.getConfigurationAwareListSize());
-               
-               configurationContainerImpl.removeConfigurationContainerAware(testConfigurationContainerAware);
-               Assert.assertEquals(3, configurationContainerImpl.getConfigurationAwareListSize());
-               
-               configurationContainerImpl.removeConfigurationContainerAware(testConfigurationContainerAware);
-               Assert.assertEquals(3, configurationContainerImpl.getConfigurationAwareListSize());
-               
-               configurationContainerImpl.removeConfigurationContainerAware(testConfigurationAware3);
-               Assert.assertEquals(2, configurationContainerImpl.getConfigurationAwareListSize());
-               
-               configurationContainerImpl.removeConfigurationContainerAware(testConfigurationAware2);
-               Assert.assertEquals(1, configurationContainerImpl.getConfigurationAwareListSize());
-               
-               configurationContainerImpl.removeConfigurationContainerAware(testConfigurationAware1);
-               Assert.assertEquals(0, configurationContainerImpl.getConfigurationAwareListSize());
-               
-               
-       }
-       
-}
+public class ConfigurationContainerImplTest {
+
+
+        @Test
+        public void testAddRemoveSaveConfiguration() {
+
+                ConfigurationContainerImpl configurationContainerImpl = new ConfigurationContainerImpl();
+                IConfigurationContainerAware testConfigurationContainerAware = new ConfigurationContainerAwareTest();
+
+                configurationContainerImpl.addConfigurationContainerAware(testConfigurationContainerAware);
+                configurationContainerImpl.addConfigurationContainerAware(testConfigurationContainerAware);
+
+                Assert.assertEquals(1, configurationContainerImpl.getConfigurationAwareListSize());
+
+                IConfigurationContainerAware testConfigurationAware1 = new ConfigurationContainerAwareTest();
+                configurationContainerImpl.addConfigurationContainerAware(testConfigurationAware1);
+
+                Assert.assertEquals(2, configurationContainerImpl.getConfigurationAwareListSize());
+
+                IConfigurationContainerAware testConfigurationAware2 = new ConfigurationContainerAwareTest();
+                configurationContainerImpl.addConfigurationContainerAware(testConfigurationAware2);
+
+                Assert.assertEquals(3, configurationContainerImpl.getConfigurationAwareListSize());
 
+                IConfigurationContainerAware testConfigurationAware3 = new ConfigurationContainerAwareTest();
+                configurationContainerImpl.addConfigurationContainerAware(testConfigurationAware3);
+
+                Assert.assertEquals(4, configurationContainerImpl.getConfigurationAwareListSize());
+
+                configurationContainerImpl.removeConfigurationContainerAware(testConfigurationContainerAware);
+                Assert.assertEquals(3, configurationContainerImpl.getConfigurationAwareListSize());
+
+                configurationContainerImpl.removeConfigurationContainerAware(testConfigurationContainerAware);
+                Assert.assertEquals(3, configurationContainerImpl.getConfigurationAwareListSize());
+
+                configurationContainerImpl.removeConfigurationContainerAware(testConfigurationAware3);
+                Assert.assertEquals(2, configurationContainerImpl.getConfigurationAwareListSize());
+
+                configurationContainerImpl.removeConfigurationContainerAware(testConfigurationAware2);
+                Assert.assertEquals(1, configurationContainerImpl.getConfigurationAwareListSize());
+
+                configurationContainerImpl.removeConfigurationContainerAware(testConfigurationAware1);
+                Assert.assertEquals(0, configurationContainerImpl.getConfigurationAwareListSize());
+
+
+        }
+
+}
index 71d768d..816c6ce 100644 (file)
@@ -12,52 +12,51 @@ package org.opendaylight.controller.configuration.internal;
 import org.junit.*;
 import org.opendaylight.controller.configuration.IConfigurationAware;
 
-public class ConfigurationImplTest { 
-       
-
-       @Test
-       public void testAddRemoveSaveConfiguration() {
-               
-               ConfigurationImpl configurationImpl = new ConfigurationImpl();
-               IConfigurationAware testConfigurationAware = new ConfigurationAwareTest();
-               
-               configurationImpl.addConfigurationAware(testConfigurationAware);
-               configurationImpl.addConfigurationAware(testConfigurationAware);
-               
-               Assert.assertEquals(1, configurationImpl.getConfigurationAwareListSize());
-               
-               ConfigurationAwareTest testConfigurationAware1 = new ConfigurationAwareTest();
-               configurationImpl.addConfigurationAware(testConfigurationAware1);
-               
-               Assert.assertEquals(2, configurationImpl.getConfigurationAwareListSize());
-               
-               ConfigurationAwareTest testConfigurationAware2 = new ConfigurationAwareTest();
-               configurationImpl.addConfigurationAware(testConfigurationAware2);
-               
-               Assert.assertEquals(3, configurationImpl.getConfigurationAwareListSize());
-               
-               ConfigurationAwareTest testConfigurationAware3 = new ConfigurationAwareTest();
-               configurationImpl.addConfigurationAware(testConfigurationAware3);
-               
-               Assert.assertEquals(4, configurationImpl.getConfigurationAwareListSize());
-               
-               
-               configurationImpl.removeConfigurationAware(testConfigurationAware);
-               Assert.assertEquals(3, configurationImpl.getConfigurationAwareListSize());
-               
-               configurationImpl.removeConfigurationAware(testConfigurationAware);
-               Assert.assertEquals(3, configurationImpl.getConfigurationAwareListSize());
-               
-               configurationImpl.removeConfigurationAware(testConfigurationAware3);
-               Assert.assertEquals(2, configurationImpl.getConfigurationAwareListSize());
-               
-               configurationImpl.removeConfigurationAware(testConfigurationAware1);
-               Assert.assertEquals(1, configurationImpl.getConfigurationAwareListSize());
-               
-               configurationImpl.removeConfigurationAware(testConfigurationAware2);
-               Assert.assertEquals(0, configurationImpl.getConfigurationAwareListSize());
-               
-       }
-       
-}
+public class ConfigurationImplTest {
+
+
+        @Test
+        public void testAddRemoveSaveConfiguration() {
+
+                ConfigurationImpl configurationImpl = new ConfigurationImpl();
+                IConfigurationAware testConfigurationAware = new ConfigurationAwareTest();
+
+                configurationImpl.addConfigurationAware(testConfigurationAware);
+                configurationImpl.addConfigurationAware(testConfigurationAware);
+
+                Assert.assertEquals(1, configurationImpl.getConfigurationAwareListSize());
+
+                ConfigurationAwareTest testConfigurationAware1 = new ConfigurationAwareTest();
+                configurationImpl.addConfigurationAware(testConfigurationAware1);
+
+                Assert.assertEquals(2, configurationImpl.getConfigurationAwareListSize());
+
+                ConfigurationAwareTest testConfigurationAware2 = new ConfigurationAwareTest();
+                configurationImpl.addConfigurationAware(testConfigurationAware2);
+
+                Assert.assertEquals(3, configurationImpl.getConfigurationAwareListSize());
 
+                ConfigurationAwareTest testConfigurationAware3 = new ConfigurationAwareTest();
+                configurationImpl.addConfigurationAware(testConfigurationAware3);
+
+                Assert.assertEquals(4, configurationImpl.getConfigurationAwareListSize());
+
+
+                configurationImpl.removeConfigurationAware(testConfigurationAware);
+                Assert.assertEquals(3, configurationImpl.getConfigurationAwareListSize());
+
+                configurationImpl.removeConfigurationAware(testConfigurationAware);
+                Assert.assertEquals(3, configurationImpl.getConfigurationAwareListSize());
+
+                configurationImpl.removeConfigurationAware(testConfigurationAware3);
+                Assert.assertEquals(2, configurationImpl.getConfigurationAwareListSize());
+
+                configurationImpl.removeConfigurationAware(testConfigurationAware1);
+                Assert.assertEquals(1, configurationImpl.getConfigurationAwareListSize());
+
+                configurationImpl.removeConfigurationAware(testConfigurationAware2);
+                Assert.assertEquals(0, configurationImpl.getConfigurationAwareListSize());
+
+        }
+
+}
index f057959..b956d76 100644 (file)
@@ -23,14 +23,14 @@ public interface IContainerManager {
     /**
      * Returns a list of Containers that currently exist.
      *
-     * @return array of String Container names
+     * @return  array of String Container names
      */
     public boolean hasNonDefaultContainer();
 
     /**
      * Returns a list of Containers that currently exist.
      *
-     * @return array of String Container names
+     * @return  array of String Container names
      */
     public List<String> getContainerNames();
 
@@ -39,7 +39,7 @@ public interface IContainerManager {
      * TODO : REMOVE THIS FUNCTION and make Save as a service rather than the
      * current hack of calling individual save routines.
      *
-     * @return status code
+     * @return  status code
      */
     public Status saveContainerConfig();
 }
index 4bdd679..2d64399 100644 (file)
@@ -20,41 +20,41 @@ import org.opendaylight.controller.sal.utils.NodeCreator;
 \r
 public class ContainerImplTest {\r
 \r
-       @Test\r
-       public void test() {\r
-               \r
-               ContainerImpl container1 = new ContainerImpl();\r
-                               \r
-               //Create Component for init\r
-               ComponentImpl component1 = new ComponentImpl(null, null, null);\r
-               component1.setInterface("serviceTestName", null);\r
-\r
-               //container1 does not have name yet\r
-               container1.init(component1);\r
-               assertNull(container1.getName());\r
-               \r
-               //Sets container1 name to TestName\r
-               Hashtable<String, String> properties = new Hashtable<String, String>();\r
-               properties.put("dummyKey", "dummyValue");\r
-               properties.put("containerName", "TestName");\r
-               component1.setInterface("serviceTestName", properties);\r
-\r
-               container1.init(component1);\r
-               assertEquals("TestName", container1.getName());\r
-               \r
-               //getContainerFlows always returns null for now\r
-               assertNull(container1.getContainerFlows());\r
-               \r
-               //getTag always returns 0 for now\r
-               Node n = NodeCreator.createOFNode(1L);\r
-               assertEquals(0, container1.getTag(n));\r
-               \r
-               //getNodeConnectors always returns null for now\r
-               assertNull(container1.getNodeConnectors());\r
-               \r
-               //getNodes always returns null for now\r
-               assertNull(container1.getNodes());\r
-               \r
-       }\r
+        @Test\r
+        public void test() {\r
+\r
+                ContainerImpl container1 = new ContainerImpl();\r
+\r
+                //Create Component for init\r
+                ComponentImpl component1 = new ComponentImpl(null, null, null);\r
+                component1.setInterface("serviceTestName", null);\r
+\r
+                //container1 does not have name yet\r
+                container1.init(component1);\r
+                assertNull(container1.getName());\r
+\r
+                //Sets container1 name to TestName\r
+                Hashtable<String, String> properties = new Hashtable<String, String>();\r
+                properties.put("dummyKey", "dummyValue");\r
+                properties.put("containerName", "TestName");\r
+                component1.setInterface("serviceTestName", properties);\r
+\r
+                container1.init(component1);\r
+                assertEquals("TestName", container1.getName());\r
+\r
+                //getContainerFlows always returns null for now\r
+                assertNull(container1.getContainerFlows());\r
+\r
+                //getTag always returns 0 for now\r
+                Node n = NodeCreator.createOFNode(1L);\r
+                assertEquals(0, container1.getTag(n));\r
+\r
+                //getNodeConnectors always returns null for now\r
+                assertNull(container1.getNodeConnectors());\r
+\r
+                //getNodes always returns null for now\r
+                assertNull(container1.getNodes());\r
+\r
+        }\r
 \r
 }\r
index b5e7a11..c7e35a0 100644 (file)
@@ -18,21 +18,21 @@ import org.opendaylight.controller.sal.utils.GlobalConstants;
 \r
 public class ContainerManagerTest {\r
 \r
-       @Test\r
-       public void test() {\r
-               ContainerManager cm = new ContainerManager();\r
-               \r
-               cm.init();\r
-               \r
-               ArrayList<String> names = (ArrayList<String>) cm.getContainerNames();\r
-               assertEquals(1, names.size());\r
-               assertEquals(GlobalConstants.DEFAULT.toString(), names.get(0));\r
-               \r
-               assertFalse(cm.hasNonDefaultContainer());\r
-               assertNull(cm.saveContainerConfig());\r
-               \r
-               cm.destroy();\r
-\r
-       }\r
+        @Test\r
+        public void test() {\r
+                ContainerManager cm = new ContainerManager();\r
+\r
+                cm.init();\r
+\r
+                ArrayList<String> names = (ArrayList<String>) cm.getContainerNames();\r
+                assertEquals(1, names.size());\r
+                assertEquals(GlobalConstants.DEFAULT.toString(), names.get(0));\r
+\r
+                assertFalse(cm.hasNonDefaultContainer());\r
+                assertNull(cm.saveContainerConfig());\r
+\r
+                cm.destroy();\r
+\r
+        }\r
 \r
 }\r
index 5fabb26..0166d27 100644 (file)
@@ -12,14 +12,14 @@ package org.opendaylight.controller.forwarding.staticrouting;
 import java.net.InetAddress;
 import java.util.concurrent.ConcurrentMap;
 /**
- * 
+ *
  * This interface provides APIs to configure and manage static routes.
  *
  */
 import org.opendaylight.controller.sal.utils.Status;
 
 /**
- * 
+ *
  * This Interface provides APIs to manage and query the static routes
  *
  */
index 262c017..ceacebf 100644 (file)
@@ -151,18 +151,18 @@ public class StaticRouteConfig implements Serializable {
     public Status isValid() {
         if ((name == null) || (name.trim().length() < 1)) {
             return new Status(StatusCode.BADREQUEST,
-                       "Invalid Static Route name");
+                        "Invalid Static Route name");
         }
         if (!isValidStaticRouteEntry()) {
             return new Status(StatusCode.BADREQUEST,
-                       "Invalid Static Route entry. Please use the " +
-                       "IPAddress/mask format. Default gateway " +
-                       "(0.0.0.0/0) is NOT supported.");
+                        "Invalid Static Route entry. Please use the " +
+                        "IPAddress/mask format. Default gateway " +
+                        "(0.0.0.0/0) is NOT supported.");
         }
         if (!isValidNextHop()) {
             return new Status(StatusCode.BADREQUEST,
-                       "Invalid NextHop IP Address configuration. " +
-                                       "Please use the X.X.X.X format.");
+                        "Invalid NextHop IP Address configuration. " +
+                                        "Please use the X.X.X.X format.");
         }
 
         return new Status(StatusCode.SUCCESS, null);
index 1ac923c..8819be3 100644 (file)
@@ -131,7 +131,7 @@ public class StaticRoutingImplementation implements IfNewHostNotify,
         }
     }
 
-    
+
     private Status saveConfig() {
         // Publish the save config event to the cluster nodes
         configSaveEvent.put(new Date().getTime(), SAVE);
@@ -154,7 +154,7 @@ public class StaticRoutingImplementation implements IfNewHostNotify,
     }
 
     @SuppressWarnings("deprecation")
-       private void allocateCaches() {
+        private void allocateCaches() {
         if (this.clusterContainerService == null) {
             log
                     .info("un-initialized clusterContainerService, can't create cache");
@@ -207,7 +207,7 @@ public class StaticRoutingImplementation implements IfNewHostNotify,
     }
 
     @SuppressWarnings("deprecation")
-       private void destroyCaches() {
+        private void destroyCaches() {
         if (this.clusterContainerService == null) {
             log
                     .info("un-initialized clusterContainerService, can't destroy cache");
@@ -390,16 +390,16 @@ public class StaticRoutingImplementation implements IfNewHostNotify,
             return status;
         }
         if (staticRouteConfigs.get(config.getName()) != null) {
-               return new Status(StatusCode.CONFLICT,
-                               "A valid Static Route configuration with this name " +
-                                               "already exists. Please use a different name");
+                return new Status(StatusCode.CONFLICT,
+                                "A valid Static Route configuration with this name " +
+                                                "already exists. Please use a different name");
         }
         for (StaticRouteConfig s : staticRouteConfigs.values()) {
             if (s.equals(config)) {
-               return new Status(StatusCode.CONFLICT,
-                               "This conflicts with an existing Static Route " +
-                                       "Configuration. Please check the configuration " +
-                                               "and try again");
+                return new Status(StatusCode.CONFLICT,
+                                "This conflicts with an existing Static Route " +
+                                        "Configuration. Please check the configuration " +
+                                                "and try again");
             }
         }
 
@@ -407,7 +407,7 @@ public class StaticRoutingImplementation implements IfNewHostNotify,
         StaticRoute sRoute = new StaticRoute(config);
         staticRoutes.put(config.getName(), sRoute);
         checkAndUpdateListeners(sRoute, true);
-        return status; 
+        return status;
     }
 
     public Status removeStaticRoute(String name) {
@@ -417,8 +417,8 @@ public class StaticRoutingImplementation implements IfNewHostNotify,
             checkAndUpdateListeners(sRoute, false);
             return new Status(StatusCode.SUCCESS, null);
         }
-        return new Status(StatusCode.NOTFOUND, 
-                       "Static Route with name " + name + " is not found");
+        return new Status(StatusCode.NOTFOUND,
+                        "Static Route with name " + name + " is not found");
     }
 
     void setClusterContainerService(IClusterContainerServices s) {
index 84ec54b..7cd085f 100644 (file)
@@ -18,94 +18,93 @@ import org.opendaylight.controller.sal.utils.Status;
 import org.opendaylight.controller.sal.utils.StatusCode;
 
 public class StaticRouteConfigTest {
-       
-       @Test
-       public void testStaticRouteSetGet() {
-               StaticRouteConfig staticRouteConfig1 = new StaticRouteConfig();
-               staticRouteConfig1.setName("route");
-               staticRouteConfig1.setStaticRoute("10.1.1.2/32");
-               staticRouteConfig1.setNextHop("200.2.2.2");
-               staticRouteConfig1.setNextHopType(NextHopType.IPADDRESS.toString());
-               StaticRouteConfig staticRouteConfig2 = new StaticRouteConfig("route", "10.1.1.2/32", "200.2.2.2");
-               
-               Assert.assertEquals(staticRouteConfig2.getName(), staticRouteConfig1.getName());
-               Assert.assertEquals(staticRouteConfig2.getStaticRoute(), staticRouteConfig1.getStaticRoute());
-               Assert.assertEquals(staticRouteConfig2.getNextHop(), staticRouteConfig1.getNextHop());
-               Assert.assertEquals("nexthop-ip", staticRouteConfig1.getNextHopType());
-       }
-               
-       @Test
-       public void testStaticRouteisValid() {  
+
+        @Test
+        public void testStaticRouteSetGet() {
+                StaticRouteConfig staticRouteConfig1 = new StaticRouteConfig();
+                staticRouteConfig1.setName("route");
+                staticRouteConfig1.setStaticRoute("10.1.1.2/32");
+                staticRouteConfig1.setNextHop("200.2.2.2");
+                staticRouteConfig1.setNextHopType(NextHopType.IPADDRESS.toString());
+                StaticRouteConfig staticRouteConfig2 = new StaticRouteConfig("route", "10.1.1.2/32", "200.2.2.2");
+
+                Assert.assertEquals(staticRouteConfig2.getName(), staticRouteConfig1.getName());
+                Assert.assertEquals(staticRouteConfig2.getStaticRoute(), staticRouteConfig1.getStaticRoute());
+                Assert.assertEquals(staticRouteConfig2.getNextHop(), staticRouteConfig1.getNextHop());
+                Assert.assertEquals("nexthop-ip", staticRouteConfig1.getNextHopType());
+        }
+
+        @Test
+        public void testStaticRouteisValid() {
         StaticRouteConfig staticRouteConfig1 = new StaticRouteConfig("route1", "10.1.1.254/24", "100.1.1.1");
-               Status receivedResponse1 = staticRouteConfig1.isValid();
-               Status expectedResponse1 = new Status(StatusCode.SUCCESS, null);
-               Assert.assertEquals(expectedResponse1.toString(), receivedResponse1.toString());
-               
+                Status receivedResponse1 = staticRouteConfig1.isValid();
+                Status expectedResponse1 = new Status(StatusCode.SUCCESS, null);
+                Assert.assertEquals(expectedResponse1.toString(), receivedResponse1.toString());
+
         StaticRouteConfig staticRouteConfig2 = new StaticRouteConfig("", "", "100.1.1.1");
-               Status receivedResponse2 = staticRouteConfig2.isValid();
-               Status expectedResponse2 = new Status(StatusCode.BADREQUEST,
-                       "Invalid Static Route name");
-               Assert.assertEquals(expectedResponse2.toString(), receivedResponse2.toString());
+                Status receivedResponse2 = staticRouteConfig2.isValid();
+                Status expectedResponse2 = new Status(StatusCode.BADREQUEST,
+                        "Invalid Static Route name");
+                Assert.assertEquals(expectedResponse2.toString(), receivedResponse2.toString());
 
         StaticRouteConfig staticRouteConfig3 = new StaticRouteConfig("route1", "10.1.1.254", "100.1.1.1");
-               Status receivedResponse3 = staticRouteConfig3.isValid();
-               Status expectedResponse3 = new Status(StatusCode.BADREQUEST,
-                       "Invalid Static Route entry. Please use the " +
-                       "IPAddress/mask format. Default gateway " +
-                       "(0.0.0.0/0) is NOT supported.");
-               Assert.assertEquals(expectedResponse3.toString(), receivedResponse3.toString());
+                Status receivedResponse3 = staticRouteConfig3.isValid();
+                Status expectedResponse3 = new Status(StatusCode.BADREQUEST,
+                        "Invalid Static Route entry. Please use the " +
+                        "IPAddress/mask format. Default gateway " +
+                        "(0.0.0.0/0) is NOT supported.");
+                Assert.assertEquals(expectedResponse3.toString(), receivedResponse3.toString());
 
         StaticRouteConfig staticRouteConfig4 = new StaticRouteConfig("route1", "289.1.1.254/24", "100.1.1.1");
-               Status receivedResponse4 = staticRouteConfig4.isValid();
-               Status expectedResponse4 = new Status(StatusCode.BADREQUEST,
-                       "Invalid Static Route entry. Please use the " +
-                       "IPAddress/mask format. Default gateway " +
-                       "(0.0.0.0/0) is NOT supported.");
-               Assert.assertEquals(expectedResponse4.toString(), receivedResponse4.toString());
-               
+                Status receivedResponse4 = staticRouteConfig4.isValid();
+                Status expectedResponse4 = new Status(StatusCode.BADREQUEST,
+                        "Invalid Static Route entry. Please use the " +
+                        "IPAddress/mask format. Default gateway " +
+                        "(0.0.0.0/0) is NOT supported.");
+                Assert.assertEquals(expectedResponse4.toString(), receivedResponse4.toString());
+
         StaticRouteConfig staticRouteConfig5 = new StaticRouteConfig("route1", "10.1.1.254/24", "100.1.1");
-               Status receivedResponse5 = staticRouteConfig5.isValid();
-               Status expectedResponse5 = new Status(StatusCode.BADREQUEST,
-                       "Invalid NextHop IP Address configuration. " +
-                               "Please use the X.X.X.X format.");
-               Assert.assertEquals(expectedResponse5.toString(), receivedResponse5.toString());
-       }
-       
-       @Test
-       public void testGetStaticRouteIP() {
+                Status receivedResponse5 = staticRouteConfig5.isValid();
+                Status expectedResponse5 = new Status(StatusCode.BADREQUEST,
+                        "Invalid NextHop IP Address configuration. " +
+                                "Please use the X.X.X.X format.");
+                Assert.assertEquals(expectedResponse5.toString(), receivedResponse5.toString());
+        }
+
+        @Test
+        public void testGetStaticRouteIP() {
         StaticRouteConfig staticRouteConfig1 = new StaticRouteConfig("route1", "10.1.1.0/24", "100.1.1.1");
         InetAddress ip1 = staticRouteConfig1.getStaticRouteIP();
-               Assert.assertEquals("10.1.1.0", ip1.getHostAddress());        
-               
+                Assert.assertEquals("10.1.1.0", ip1.getHostAddress());
+
         StaticRouteConfig staticRouteConfig2 = new StaticRouteConfig("route1", "10.1.1.0/80", "100.1.1.1");
         InetAddress ip2 = staticRouteConfig2.getStaticRouteIP();
-               Assert.assertEquals(null, ip2);        
+                Assert.assertEquals(null, ip2);
+
+        }
 
-       }
-       
-       @Test
-       public void testGetStaticRouteMask() {
+        @Test
+        public void testGetStaticRouteMask() {
         StaticRouteConfig staticRouteConfig1 = new StaticRouteConfig("route1", "10.1.1.0/24", "100.1.1.1");
-               Short receivedMaskLen1 = staticRouteConfig1.getStaticRouteMask();
-               Short expectedMaskLen1 = 24;
-               Assert.assertEquals(expectedMaskLen1, receivedMaskLen1);
-
-               StaticRouteConfig staticRouteConfig2 = new StaticRouteConfig("route1", "10.1.1.0/40", "100.1.1.1");
-               Short receivedMaskLen2 = staticRouteConfig2.getStaticRouteMask();
-               Short expectedMaskLen2 = 0;
-               Assert.assertEquals(expectedMaskLen2, receivedMaskLen2);
-       }
-       
-       @Test 
-       public void testGetNextHopIP() {
+                Short receivedMaskLen1 = staticRouteConfig1.getStaticRouteMask();
+                Short expectedMaskLen1 = 24;
+                Assert.assertEquals(expectedMaskLen1, receivedMaskLen1);
+
+                StaticRouteConfig staticRouteConfig2 = new StaticRouteConfig("route1", "10.1.1.0/40", "100.1.1.1");
+                Short receivedMaskLen2 = staticRouteConfig2.getStaticRouteMask();
+                Short expectedMaskLen2 = 0;
+                Assert.assertEquals(expectedMaskLen2, receivedMaskLen2);
+        }
+
+        @Test
+        public void testGetNextHopIP() {
         StaticRouteConfig staticRouteConfig1 = new StaticRouteConfig("route1", "10.1.1.254/24", "100.1.1.1");
         InetAddress ip1 = staticRouteConfig1.getNextHopIP();
-               Assert.assertEquals("100.1.1.1", ip1.getHostAddress());                
+                Assert.assertEquals("100.1.1.1", ip1.getHostAddress());
 
-               StaticRouteConfig staticRouteConfig2 = new StaticRouteConfig("route1", "10.1.1.254/24", "100.1.1");
+                StaticRouteConfig staticRouteConfig2 = new StaticRouteConfig("route1", "10.1.1.254/24", "100.1.1");
         InetAddress ip2 = staticRouteConfig2.getNextHopIP();
-               Assert.assertEquals(null, ip2);                
-       }
-       
-}
+                Assert.assertEquals(null, ip2);
+        }
 
+}
index f05b10c..4a497a0 100644 (file)
@@ -23,35 +23,35 @@ import org.opendaylight.controller.sal.utils.NodeConnectorCreator;
 import org.opendaylight.controller.sal.utils.NodeCreator;
 
 public class StaticRouteTest {
-       
-       @Test
-       public void testStaticRouteGetSet() {
-               StaticRoute staticRoute = new StaticRoute();
-               InetAddress networkAddress = null;
-               InetAddress mask = null;
-               InetAddress nextHopAddress = null;
-               try {
-                       networkAddress = InetAddress.getByName("10.1.1.0");
-                       mask = InetAddress.getByName("255.255.255.0");
-                       nextHopAddress = InetAddress.getByName("200.0.0.1");
-                       
-               } catch (UnknownHostException e) {
-                       Assert.assertTrue(false);
-               }
-               staticRoute.setNetworkAddress(networkAddress);
-               Assert.assertEquals(networkAddress.getHostAddress(), staticRoute.getNetworkAddress().getHostAddress());
-               staticRoute.setMask(mask);
-               Assert.assertEquals(mask.getHostAddress(), staticRoute.getMask().getHostAddress());
-               staticRoute.setType(NextHopType.IPADDRESS);
-               Assert.assertEquals("nexthop-ip", staticRoute.getType().toString());
-               staticRoute.setNextHopAddress(nextHopAddress);
-               Assert.assertEquals(nextHopAddress.getHostAddress(), staticRoute.getNextHopAddress().getHostAddress());
-               Node node = NodeCreator.createOFNode(((long)10));
-               staticRoute.setNode(node);
-               Assert.assertEquals(node, staticRoute.getNode());
-               NodeConnector nc0 = NodeConnectorCreator.createOFNodeConnector((short)20, node);
-               staticRoute.setPort(nc0);
-               Assert.assertEquals(nc0, staticRoute.getPort());
+
+        @Test
+        public void testStaticRouteGetSet() {
+                StaticRoute staticRoute = new StaticRoute();
+                InetAddress networkAddress = null;
+                InetAddress mask = null;
+                InetAddress nextHopAddress = null;
+                try {
+                        networkAddress = InetAddress.getByName("10.1.1.0");
+                        mask = InetAddress.getByName("255.255.255.0");
+                        nextHopAddress = InetAddress.getByName("200.0.0.1");
+
+                } catch (UnknownHostException e) {
+                        Assert.assertTrue(false);
+                }
+                staticRoute.setNetworkAddress(networkAddress);
+                Assert.assertEquals(networkAddress.getHostAddress(), staticRoute.getNetworkAddress().getHostAddress());
+                staticRoute.setMask(mask);
+                Assert.assertEquals(mask.getHostAddress(), staticRoute.getMask().getHostAddress());
+                staticRoute.setType(NextHopType.IPADDRESS);
+                Assert.assertEquals("nexthop-ip", staticRoute.getType().toString());
+                staticRoute.setNextHopAddress(nextHopAddress);
+                Assert.assertEquals(nextHopAddress.getHostAddress(), staticRoute.getNextHopAddress().getHostAddress());
+                Node node = NodeCreator.createOFNode(((long)10));
+                staticRoute.setNode(node);
+                Assert.assertEquals(node, staticRoute.getNode());
+                NodeConnector nc0 = NodeConnectorCreator.createOFNodeConnector((short)20, node);
+                staticRoute.setPort(nc0);
+                Assert.assertEquals(nc0, staticRoute.getPort());
         InetAddress ip1 = null;
         HostNodeConnector h1 = null;
         try {
@@ -66,10 +66,10 @@ public class StaticRouteTest {
         }
         staticRoute.setHost(h1);
         Assert.assertEquals(h1, staticRoute.getHost());
-       }
-       
-       @Test
-       public void testStaticRouteComparison() {
+        }
+
+        @Test
+        public void testStaticRouteComparison() {
         StaticRouteConfig staticRouteConfig1 = new StaticRouteConfig("route1", "10.1.1.0/24", "100.1.1.1");
         StaticRouteConfig staticRouteConfig2 = new StaticRouteConfig("route2", "10.1.1.0/24", "100.2.1.1");
         StaticRouteConfig staticRouteConfig3 = new StaticRouteConfig("route3", "10.2.1.0/24", "100.3.1.1");
@@ -82,28 +82,28 @@ public class StaticRouteTest {
         Assert.assertTrue(staticRoute1.equals(staticRoute2));
         Assert.assertFalse(staticRoute1.equals(staticRoute3));
         Assert.assertFalse(staticRoute1.equals(staticRoute4));
-        
+
         Assert.assertTrue(staticRoute1.compareTo(staticRoute2) == 0 ? true : false);
         Assert.assertFalse(staticRoute1.compareTo(staticRoute3) == 0 ? true : false);
         Assert.assertTrue(staticRoute1.compareTo(staticRoute4) == 0 ? true : false);
-                       
-       }
-       
-       @Test
-       public void testLongestPrefixMatch() {
+
+        }
+
+        @Test
+        public void testLongestPrefixMatch() {
         StaticRouteConfig staticRouteConfig1 = new StaticRouteConfig("route1", "10.1.1.254/24", "100.1.1.1");
         StaticRoute staticRoute1 = new StaticRoute(staticRouteConfig1);
-               InetAddress ip1 = null;
-               InetAddress ip2 = null;
-               try {
-                       ip1 = InetAddress.getByName("10.1.0.2");
-                       ip2 = InetAddress.getByName("10.1.1.2");
-               } catch (UnknownHostException e) {
-                       Assert.assertTrue(false);
-               }
+                InetAddress ip1 = null;
+                InetAddress ip2 = null;
+                try {
+                        ip1 = InetAddress.getByName("10.1.0.2");
+                        ip2 = InetAddress.getByName("10.1.1.2");
+                } catch (UnknownHostException e) {
+                        Assert.assertTrue(false);
+                }
         InetAddress rxdIp1 = staticRoute1.longestPrefixMatch(ip1);
         InetAddress rxdIp2 = staticRoute1.longestPrefixMatch(ip2);
-               Assert.assertEquals(null, rxdIp1);
-               Assert.assertEquals("10.1.1.0", rxdIp2.getHostAddress());
-       }
+                Assert.assertEquals(null, rxdIp1);
+                Assert.assertEquals("10.1.1.0", rxdIp2.getHostAddress());
+        }
 }
index 4df0590..4c9d4ab 100644 (file)
@@ -13,16 +13,12 @@ import org.junit.Assert;
 import org.junit.Test;
 
 public class StaticRoutingImplementationTest {
-       
-       @Test
-       public void isIPv4AddressValidTest() {
-               StaticRoutingImplementation staticRouteImpl = new StaticRoutingImplementation();
-        Assert.assertTrue(staticRouteImpl.isIPv4AddressValid("192.168.100.0/24"));             
-        Assert.assertFalse(staticRouteImpl.isIPv4AddressValid("192.168.100.0/36"));            
-        Assert.assertFalse(staticRouteImpl.isIPv4AddressValid("192.168.300.0/32"));            
-       }
-}
-
-
-
 
+        @Test
+        public void isIPv4AddressValidTest() {
+                StaticRoutingImplementation staticRouteImpl = new StaticRoutingImplementation();
+        Assert.assertTrue(staticRouteImpl.isIPv4AddressValid("192.168.100.0/24"));
+        Assert.assertFalse(staticRouteImpl.isIPv4AddressValid("192.168.100.0/36"));
+        Assert.assertFalse(staticRouteImpl.isIPv4AddressValid("192.168.300.0/32"));
+        }
+}
index 6aa5b07..8a05532 100644 (file)
@@ -51,7 +51,7 @@ public class FlowEntry implements Cloneable, Serializable {
 
     /**
      * Return the actual Flow contained in this entry
-     * 
+     *
      * @return the flow
      */
     public Flow getFlow() {
@@ -147,12 +147,12 @@ public class FlowEntry implements Cloneable, Serializable {
 
     /**
      * Merges the current Flow with the passed Container Flow
-     * 
+     *
      * Note: Container Flow merging is not an injective function. Be m1 and m2
      * two different matches, and be f() the flow merge function, such that y1 =
      * f(m1) and y2 = f(m2) are the two merged matches, we may have: y1 = y2
-     * 
-     * 
+     *
+     *
      * @param containerFlow
      * @return this merged FlowEntry
      */
index 18255bc..311d2f9 100644 (file)
@@ -17,10 +17,10 @@ import org.opendaylight.controller.sal.core.Node;
  * install, the container flow with which that entry had to be merged and the
  * resultant merged flow entry, which is the one that was eventually installed
  * on the network node
- * 
+ *
  * Note: If the container flow is null, the install entry will be a clone of the
  * original entry
- * 
+ *
  */
 public class FlowEntryInstall {
     private FlowEntry original;
@@ -115,7 +115,7 @@ public class FlowEntryInstall {
     public void setRequestId(long rid) {
         this.requestId = rid;
     }
-    
+
     public long getRequestId() {
         return requestId;
     }
index 087c0bc..b3d0c8a 100644 (file)
@@ -18,7 +18,7 @@ import org.opendaylight.controller.sal.utils.Status;
 /**
  * Interface that describes methods for installing or removing forwarding rules
  * and to access to the flows database.
- * 
+ *
  */
 public interface IForwardingRulesManager {
 
@@ -27,7 +27,7 @@ public interface IForwardingRulesManager {
      * SDN protocol plugin to install the flow on the network node. Based on the
      * result of this operation FRM will update its database accordingly and
      * will return the proper {@code Status} code.
-     * 
+     *
      * @param flow
      *            the flow entry to install
      * @return the {@code Status} object indicating the result of this action.
@@ -39,7 +39,7 @@ public interface IForwardingRulesManager {
      * protocol plugin to uninstall the flow from the network node. Based on the
      * result of this operation FRM will update its database accordingly and
      * will return the proper {@code Status} code.
-     * 
+     *
      * @param flow
      *            the flow entry to uninstall
      * @return the {@code Status} object indicating the result of this action
@@ -53,7 +53,7 @@ public interface IForwardingRulesManager {
      * modify message depending on the SDN protocol specifications If the
      * current flow is equal to the new one it will be a no op and success code
      * is returned.
-     * 
+     *
      * @param current
      *            the current flow entry to modify
      * @param newone
@@ -72,8 +72,8 @@ public interface IForwardingRulesManager {
      * it, it will request plugin to add the new flow. If the passed entry is
      * not valid an error code is returned. If the existing flow is equal to the
      * passed one it will be a no op and success code is returned.
-     * 
-     * 
+     *
+     *
      * @param newone
      *            the new flow entry to install
      * @return the {@code Status} object indicating the result of this action
@@ -86,7 +86,7 @@ public interface IForwardingRulesManager {
      * SDN protocol plugin to install the flow on the network node. As immediate
      * result of this asynchronous call, FRM will update its flow database as if
      * the flow was successfully installed.
-     * 
+     *
      * @param flow
      *            the flow entry to install
      * @return the status of this request containing the request id associated
@@ -100,7 +100,7 @@ public interface IForwardingRulesManager {
      * SDN protocol plugin to uninstall the flow from the network node. As
      * immediate result of this asynchronous call, FRM will update its flow
      * database as if the flow was successfully installed.
-     * 
+     *
      * @param flow
      *            the flow entry to uninstall
      * @return the status of this request containing the unique id associated to
@@ -115,7 +115,7 @@ public interface IForwardingRulesManager {
      * this message to the network node. It could be a delete + add or a single
      * modify message depending on the SDN protocol specifications. If the
      * current flow is equal to the new one it will be a no op.
-     * 
+     *
      * @param current
      *            the current flow entry to modify
      * @param newone
@@ -136,7 +136,7 @@ public interface IForwardingRulesManager {
      * it, it will request plugin to add the new flow. If the passed entry is
      * not valid a zero request id is returned. If the existing flow is equal to
      * the passed one it will be a no op.
-     * 
+     *
      * @param newone
      *            the new flow entry to install
      * @return the unique id associated to this request. In case of not
@@ -154,7 +154,7 @@ public interface IForwardingRulesManager {
      * blocked until the solicitation response is received from the network node
      * or receive timeout. Otherwise, it is a non-blocking call and does not
      * guarantee the node will respond in any given time.
-     * 
+     *
      * @param node
      *            The network node to solicit a response
      * @param blocking
@@ -166,7 +166,7 @@ public interface IForwardingRulesManager {
 
     /**
      * Check whether the passed flow entry conflicts with the Container flows
-     * 
+     *
      * @param flow
      *            the flow entry to test
      * @return true if conflicts, false otherwise
@@ -176,7 +176,7 @@ public interface IForwardingRulesManager {
     /**
      * Returns the list of Flow entries across network nodes which are part of
      * the same flow group, policy
-     * 
+     *
      * @param group
      *            the group name
      * @return the list of flow entries belonging to the specified group
@@ -186,7 +186,7 @@ public interface IForwardingRulesManager {
     /**
      * Add a list of output port to the flow with the specified name on the
      * specified network node
-     * 
+     *
      * @param node
      *            the network node
      * @param flowName
@@ -200,7 +200,7 @@ public interface IForwardingRulesManager {
     /**
      * Remove a list of output port from the flow with the specified name on the
      * specified network node
-     * 
+     *
      * @param node
      *            the network node
      * @param flowName
@@ -214,7 +214,7 @@ public interface IForwardingRulesManager {
     /**
      * Replace the current output port in the specified flow with the specified
      * one
-     * 
+     *
      * @param node
      *            the network node
      * @param groupName
@@ -229,7 +229,7 @@ public interface IForwardingRulesManager {
 
     /**
      * Returns the output port configured on the specified flow
-     * 
+     *
      * @param node
      *            the network node
      * @param flowName
@@ -242,14 +242,14 @@ public interface IForwardingRulesManager {
      * Returns all the troubleshooting information that applications have set
      * along with the policy they have configured through forwarding rules
      * manger.
-     * 
+     *
      * @return the collection of troubleshooting objects
      */
     public Map<String, Object> getTSPolicyData();
 
     /**
      * Set the troubleshooting information for the policy
-     * 
+     *
      * @param policyname
      *            the flow group name
      * @param o
@@ -262,7 +262,7 @@ public interface IForwardingRulesManager {
     /**
      * Returns the troubleshooting information that was set for the specified
      * policy
-     * 
+     *
      * @param groupName
      *            the flows group name
      * @return the troubleshooting info object
@@ -272,7 +272,7 @@ public interface IForwardingRulesManager {
     /**
      * Returns the specifications of all the flows configured for all the
      * switches on the current container
-     * 
+     *
      * @return the list of flow configurations present in the database
      */
     public List<FlowConfig> getStaticFlows();
@@ -280,7 +280,7 @@ public interface IForwardingRulesManager {
     /**
      * Returns the specifications of all the flows configured for the given
      * switch on the current container
-     * 
+     *
      * @param node
      *            the network node identifier
      * @return the list of {@code FlowConfig} objects
@@ -290,7 +290,7 @@ public interface IForwardingRulesManager {
     /**
      * Returns the specification of the flow configured for the given network
      * node on the current container
-     * 
+     *
      * @param name
      *            the flow name
      * @param n
@@ -302,7 +302,7 @@ public interface IForwardingRulesManager {
     /**
      * Returns the list of names of flows configured for the given Network node
      * on the current container
-     * 
+     *
      * @param node
      *            the network node identifier
      * @return the list of flow names
@@ -311,14 +311,14 @@ public interface IForwardingRulesManager {
 
     /**
      * Returns the list of Node(s) for which a static flow has been configured
-     * 
+     *
      * @return the list of network nodes
      */
     public List<Node> getListNodeWithConfiguredFlows();
 
     /**
      * Save the flow configured so far to file
-     * 
+     *
      * @return the {@code Status} object indicating the result of this action.
      */
     public Status saveConfig();
@@ -326,7 +326,7 @@ public interface IForwardingRulesManager {
     /**
      * Add a flow specified by the {@code FlowConfig} object on the current
      * container
-     * 
+     *
      * @param config
      *            the {@code FlowConfig} object representing the static flow
      * @param restore
@@ -339,7 +339,7 @@ public interface IForwardingRulesManager {
     /**
      * Remove a flow specified by the {@code FlowConfig} object on the current
      * container
-     * 
+     *
      * @param config
      *            the {@code FlowConfig} object representing the static flow
      * @return the {@code Status} object indicating the result of this action
@@ -350,7 +350,7 @@ public interface IForwardingRulesManager {
      * Replace the flow identified by the {@code FlowConfig.name} name for the
      * {@code FlowConfig.node} network node with the new flow specified by
      * {@code FlowConfig} object
-     * 
+     *
      * @param config
      *            the {@code FlowConfig} object
      * @returnthe {@code Status} object indicating the result of this action
@@ -359,7 +359,7 @@ public interface IForwardingRulesManager {
 
     /**
      * Remove the flow specified by name on the passed network node
-     * 
+     *
      * @param name
      *            for the static flow
      * @param node
@@ -372,7 +372,7 @@ public interface IForwardingRulesManager {
      * Toggle the installation status of the specified configured flow If the
      * flow configuration status is active, this call will change the flow
      * status to inactive and vice-versa
-     * 
+     *
      * @param configObject
      *            the {@code FlowConfig} object
      * @return the {@code Status} object indicating the result of this action
@@ -383,7 +383,7 @@ public interface IForwardingRulesManager {
      * Toggle the installation status of the specified configured flow If the
      * flow configuration status is active, this call will change the flow
      * status to inactive and vice-versa
-     * 
+     *
      * @param name
      *            for the static flow
      * @param node
index 43d1b29..952b3cd 100644 (file)
@@ -11,14 +11,14 @@ package org.opendaylight.controller.forwardingrulesmanager;
 /**
  * The interface which describes the methods forwarding rules manager will call
  * for notifying the listeners of policy installation updates.
- * 
+ *
  */
 public interface IForwardingRulesManagerAware {
 
     /**
      * Inform the listeners that a troubleshooting information was added or
      * removed for the specified policy.
-     * 
+     *
      * @param policyName
      *            the policy affected
      * @param add
@@ -31,7 +31,7 @@ public interface IForwardingRulesManagerAware {
      * Inform listeners that the network node has notified us about a failure in
      * executing the controller generated asynchronous request identified by the
      * passed unique id.
-     * 
+     *
      * @param requestId
      *            the unique id associated with the request which failed to be
      *            executed on the network node
index 5acd3e2..95e9b00 100644 (file)
@@ -14,11 +14,11 @@ import java.util.Set;
 /**
  * PortGroup is a simple data-structure to represent any arbitrary group of
  * ports on a Switch (that is represented using its switch-ID).
- * 
+ *
  * PortGroup is used by PortGroupProvider application to signal a set of ports
  * that represent a configured PortGroupConfig.
- * 
- * 
+ *
+ *
  */
 public class PortGroup {
     private long matrixSwitchId;
@@ -26,7 +26,7 @@ public class PortGroup {
 
     /**
      * PortGroup Constructor using Switch and Ports.
-     * 
+     *
      * @param matrixSwitchId
      *            Switch Id that represents an openflow Switch
      * @param ports
@@ -40,7 +40,7 @@ public class PortGroup {
 
     /**
      * PortGroup Constructor using Switch.
-     * 
+     *
      * @param matrixSwitchId
      *            Switch-Id that represents an openflow Switch
      */
@@ -51,7 +51,7 @@ public class PortGroup {
 
     /**
      * Returns the switchId representing the Switch that makes this PortGroup.
-     * 
+     *
      * @return long switchId
      */
     public long getMatrixSwitchId() {
@@ -60,7 +60,7 @@ public class PortGroup {
 
     /**
      * Assigns a Switch to this PortGroup
-     * 
+     *
      * @param matrixSwitchId
      *            Switch-Id that represents an openflow Switch
      */
@@ -70,7 +70,7 @@ public class PortGroup {
 
     /**
      * Returns the Set of Ports that makes this PortGroup.
-     * 
+     *
      * @return Set of short values representing openflow port-ids.
      */
     public Set<Short> getPorts() {
@@ -79,7 +79,7 @@ public class PortGroup {
 
     /**
      * Assigns a set of openflow ports to this PortGroup
-     * 
+     *
      * @param ports
      *            Set of short values representing openflow port-ids.
      */
@@ -89,7 +89,7 @@ public class PortGroup {
 
     /**
      * Adds a port to this PortGroup
-     * 
+     *
      * @param port
      *            Short value of a openflow port.
      */
index 7c8ade5..77ff640 100644 (file)
@@ -15,14 +15,14 @@ import org.opendaylight.controller.sal.core.Node;
 /**
  * PortGroupChangeListener listens to the PortGroup updates provided by the
  * PortGroupProvider.
- * 
- * 
+ *
+ *
  */
 public interface PortGroupChangeListener {
     /**
      * This method is invoked by PortGroupProvider whenever it detects a change
      * in PortGroup membership for a given PortGroupConfig.
-     * 
+     *
      * @param config
      *            Port Group Configuration
      * @param portGroupData
index 164f264..b45f489 100644 (file)
@@ -16,12 +16,12 @@ import java.util.List;
 /**
  * PortGroupConfig class represents the User's Configuration with a Opaque
  * Regular Expression String that is parsed and handled by PortGroupProvider.
- * 
+ *
  * Typically, the opaque matchString will be a Regular Expression String
  * supported by a particular PortGroupProvider based on Customer requirements.
- * 
- * 
- * 
+ *
+ *
+ *
  */
 public class PortGroupConfig implements Serializable {
     private static final long serialVersionUID = 1L;
@@ -41,7 +41,7 @@ public class PortGroupConfig implements Serializable {
     /**
      * Constructor to create a Port Group Configuration using a Group Name and
      * an Opaque String that is managed by PortGroupProvider.
-     * 
+     *
      * @param name
      *            Group Name representing a Port Group configuration
      * @param matchString
@@ -55,7 +55,7 @@ public class PortGroupConfig implements Serializable {
 
     /**
      * Returns the user configured PortGroup Configuration name.
-     * 
+     *
      * @return Configuration Name
      */
     public String getName() {
@@ -64,7 +64,7 @@ public class PortGroupConfig implements Serializable {
 
     /**
      * Assigns a name to the configuration
-     * 
+     *
      * @param name
      *            configuration name
      */
@@ -74,7 +74,7 @@ public class PortGroupConfig implements Serializable {
 
     /**
      * Returns the Opaque string
-     * 
+     *
      * @return
      */
     public String getMatchString() {
@@ -83,7 +83,7 @@ public class PortGroupConfig implements Serializable {
 
     /**
      * Assigns an opaque String to the Configuration.
-     * 
+     *
      * @param matchString
      *            Opaque string handled by PortGroupProvider
      */
@@ -94,7 +94,7 @@ public class PortGroupConfig implements Serializable {
     /**
      * Returns the names of all the configurable fields in PortGroupConfig. This
      * method is typically used by NorthBound apis.
-     * 
+     *
      * @return List of Field names that can be configured.
      */
     public static List<String> getFieldsNames() {
@@ -113,7 +113,7 @@ public class PortGroupConfig implements Serializable {
      * Returns the names of all the configurable fields in PortGroupConfig in
      * human readable format for UI purposes. This method is typically used by
      * Web/UI apis.
-     * 
+     *
      * @return List of Human readable Strings that corresponds to the
      *         configurable field names.
      */
index 37cbcd1..5a9281a 100644 (file)
@@ -17,15 +17,15 @@ import org.opendaylight.controller.sal.core.Node;
  * application to implement in order to provide Port Grouping Service. Custom
  * Application that implements this interface will have to handle the opaque
  * match criteria passed to it via PortGroupConfig.
- * 
- * 
- * 
+ *
+ *
+ *
  */
 public interface PortGroupProvider {
     /**
      * This method is invoked by the Controller towards the Provider when a new
      * port group is configured.
-     * 
+     *
      * @param config
      *            New PortGroupConfig object created by user Configuration.
      * @return true if successful. false otherwise.
@@ -35,7 +35,7 @@ public interface PortGroupProvider {
     /**
      * This method is invoked by the Controller towards the Provider when an
      * existing port group is deleted.
-     * 
+     *
      * @param config
      *            Existing Port Group Configuration deleted by the user.
      * @return true if successful. false otherwise.
@@ -47,7 +47,7 @@ public interface PortGroupProvider {
      * Configuration. Its the PortGroupProvider Application's responsibility to
      * manage the Switches & the Set of its Ports that correspond to each of the
      * Configuration and return it to the Controller when requested.
-     * 
+     *
      * @param config
      *            User Configuration
      * @see PortGroupConfig
@@ -61,7 +61,7 @@ public interface PortGroupProvider {
      * PortGroupProvider Application's responsibility to manage the Switches &
      * the Set of its Ports that correspond to each of the Configuration and
      * return it to the Controller when requested.
-     * 
+     *
      * @param config
      *            User Configuration
      * @param matrixSwitchId
@@ -76,7 +76,7 @@ public interface PortGroupProvider {
     /**
      * Registers a Listener for Port Group membership changes based on Custom
      * application algorithm.
-     * 
+     *
      * @param listener
      *            A Controller module that listens to events from the Custom
      *            Port Grouping Application.
@@ -89,7 +89,7 @@ public interface PortGroupProvider {
      * implement Custom Algorithm for Port Grouping. This method exposes the
      * custom algorithm to the user so that the user can configure the
      * matchString regular expression in PortGroupConfig appropriately.
-     * 
+     *
      * @return Usage string.
      */
     public String getApplicationDrivenMatchCriteriaUsage();
@@ -97,7 +97,7 @@ public interface PortGroupProvider {
     /**
      * Returns the name of the Custom Application that implements
      * PortGroupProvider interface.
-     * 
+     *
      * @return Provider Name
      */
     public String getProviderName();
@@ -105,7 +105,7 @@ public interface PortGroupProvider {
     /**
      * Controller uses this method to check with the Provider supports the
      * matchCriteria String configured by the User.
-     * 
+     *
      * @param matchCriteria
      * @return true if the Provider supports the matchCriteria String. false
      *         otherwise.
index d0a3702..9692877 100644 (file)
@@ -40,7 +40,7 @@ public class Activator extends ComponentActivatorAbstractBase {
     /**
      * Function called when the activator starts just after some initializations
      * are done by the ComponentActivatorAbstractBase.
-     * 
+     *
      */
     public void init() {
 
@@ -49,7 +49,7 @@ public class Activator extends ComponentActivatorAbstractBase {
     /**
      * Function called when the activator stops just before the cleanup done by
      * ComponentActivatorAbstractBase
-     * 
+     *
      */
     public void destroy() {
 
@@ -58,8 +58,8 @@ public class Activator extends ComponentActivatorAbstractBase {
     /**
      * Function that is used to communicate to dependency manager the list of
      * known implementations for services inside a container
-     * 
-     * 
+     *
+     *
      * @return An array containing all the CLASS objects that will be
      *         instantiated in order to get an fully working implementation
      *         Object
@@ -72,7 +72,7 @@ public class Activator extends ComponentActivatorAbstractBase {
     /**
      * Function that is called when configuration of the dependencies is
      * required.
-     * 
+     *
      * @param c
      *            dependency manager Component object, used for configuring the
      *            dependencies exported and imported
index 5fbe12b..db1186e 100644 (file)
@@ -135,7 +135,7 @@ public class ForwardingRulesManagerImpl implements IForwardingRulesManager,
      * Adds a flow entry onto the network node It runs various validity checks
      * and derive the final container flows merged entries that will be
      * attempted to be installed
-     * 
+     *
      * @param flowEntry
      *            the original flow entry application requested to add
      * @param async
@@ -144,7 +144,7 @@ public class ForwardingRulesManagerImpl implements IForwardingRulesManager,
      *          will contain the unique id assigned to this request
      */
     private Status addEntry(FlowEntry flowEntry, boolean async) {
-        
+
         // Sanity Check
         if (flowEntry == null || flowEntry.getNode() == null) {
             String msg = "Invalid FlowEntry";
@@ -209,7 +209,7 @@ public class ForwardingRulesManagerImpl implements IForwardingRulesManager,
                  * complication for now and assume we will always deal with
                  * one flow only per request
                  */
-                succeded = ret;   
+                succeded = ret;
             } else {
                 error = ret;
                 log.warn("Failed to install the entry: {}. The failure is: {}",
@@ -228,7 +228,7 @@ public class ForwardingRulesManagerImpl implements IForwardingRulesManager,
      * flow entry is congruent with all the N container flows, then the output
      * install entry list will contain N entries. If the output list is empty,
      * it means the passed flow entry conflicts with all the container flows.
-     * 
+     *
      * @param cFlowList
      *            The list of container flows
      * @return the list of container flow merged entries good to be installed on
@@ -260,7 +260,7 @@ public class ForwardingRulesManagerImpl implements IForwardingRulesManager,
     /**
      * Modify a flow entry with a new one It runs various validity check and
      * derive the final container flows merged flow entries to work with
-     * 
+     *
      * @param currentFlowEntry
      * @param newFlowEntry
      * @param async
@@ -335,13 +335,13 @@ public class ForwardingRulesManagerImpl implements IForwardingRulesManager,
          * This is only possible when the new entry and current entry have
          * different match. In this scenario the modification would ultimately
          * be handled as a remove and add operations in the protocol plugin.
-         * 
+         *
          * Also, if any of the new flow entries would clash with an existing
          * one, we cannot proceed with the modify operation, because it would
          * fail for some entries and leave stale entries on the network node.
          * Modify path can be taken only if it can be performed completely, for
          * all entries.
-         * 
+         *
          * So, for the above two cases, to simplify, let's decouple the modify
          * in: 1) remove current entries 2) install new entries
          */
@@ -384,7 +384,7 @@ public class ForwardingRulesManagerImpl implements IForwardingRulesManager,
              * (and might be wrong) that the same container flows that were
              * satisfied by the current entries are the same that are satisfied
              * by the new entries. Let's take the risk for now.
-             * 
+             *
              * Note: modification has to be complete. If any entry modification
              * fails, we need to stop, restore the already modified entries, and
              * declare failure.
@@ -440,7 +440,7 @@ public class ForwardingRulesManagerImpl implements IForwardingRulesManager,
      * This is the function that modifies the final container flows merged
      * entries on the network node and update the database. It expects that all
      * the validity checks are passed
-     * 
+     *
      * @param currentEntries
      * @param newEntries
      * @param async
@@ -451,7 +451,7 @@ public class ForwardingRulesManagerImpl implements IForwardingRulesManager,
     private Status modifyEntryInternal(FlowEntryInstall currentEntries,
             FlowEntryInstall newEntries, boolean async) {
         // Modify the flow on the network node
-        Status status = (async)? 
+        Status status = (async)?
                 programmer.modifyFlowAsync(currentEntries.getNode(),
                         currentEntries.getInstall().getFlow(), newEntries.getInstall()
                                 .getFlow()) :
@@ -481,7 +481,7 @@ public class ForwardingRulesManagerImpl implements IForwardingRulesManager,
     /**
      * Remove a flow entry. If the entry is not present in the software view
      * (entry or node not present), it return successfully
-     * 
+     *
      * @param flowEntry
      *          the flow entry to remove
      * @param async
@@ -554,7 +554,7 @@ public class ForwardingRulesManagerImpl implements IForwardingRulesManager,
      * This is the function that removes the final container flows merged entry
      * from the network node and update the database. It expects that all the
      * validity checks are passed
-     * 
+     *
      * @param entry
      *            the flow entry to remove
      * @param async
@@ -572,7 +572,7 @@ public class ForwardingRulesManagerImpl implements IForwardingRulesManager,
                         .getInstall().getFlow()) :
                 programmer.removeFlow(entry.getNode(), entry
                         .getInstall().getFlow());
+
 
         if (!status.isSuccess()) {
             log.warn(
@@ -593,7 +593,7 @@ public class ForwardingRulesManagerImpl implements IForwardingRulesManager,
      * on the network node and updates the database. It expects that all the
      * validity and conflict checks are passed. That means it does not check
      * whether this flow would conflict or overwrite an existing one.
-     * 
+     *
      * @param entry
      *            the flow entry to install
      * @param async
@@ -631,7 +631,7 @@ public class ForwardingRulesManagerImpl implements IForwardingRulesManager,
      * means that if the function returns true, the passed flow entry is
      * congruent with at least one container flow, hence it is good to be
      * installed on this container.
-     * 
+     *
      * @param flowEntry
      * @return true if flow conflicts with all the container flows, false
      *         otherwise
@@ -837,7 +837,7 @@ public class ForwardingRulesManagerImpl implements IForwardingRulesManager,
         }
         return status;
     }
-    
+
     @Override
     public Status modifyFlowEntry(FlowEntry currentFlowEntry,
             FlowEntry newFlowEntry) {
@@ -908,13 +908,13 @@ public class ForwardingRulesManagerImpl implements IForwardingRulesManager,
         }
     }
 
-    
+
     /**
      * Try to find in the database if a Flow with the same Match and priority of
      * the passed one already exists for the specified network node. Flow,
      * priority and network node are all specified in the FlowEntry If found,
      * the respective FlowEntryInstall Object is returned
-     * 
+     *
      * @param flowEntry
      *            the FlowEntry to be tested against the ones installed
      * @param looseCheck
@@ -1409,9 +1409,9 @@ public class ForwardingRulesManagerImpl implements IForwardingRulesManager,
          * multiple entry configuration (PortGroup) and hardware installation is
          * NOT done directly on this event. 3. The User prefers to retain the
          * configuration in Controller and skip hardware installation.
-         * 
+         *
          * Hence it is safe to update the StaticFlow DB at this point.
-         * 
+         *
          * Note : For the case of PortGrouping, it is essential to have this DB
          * populated before the PortGroupListeners can query for the DB
          * triggered using portGroupChanged event...
@@ -1924,7 +1924,7 @@ public class ForwardingRulesManagerImpl implements IForwardingRulesManager,
 
     /**
      * Remove from the databases all the flows installed on the node
-     * 
+     *
      * @param node
      */
     private synchronized void cleanDatabaseForNode(Node node) {
@@ -2210,7 +2210,7 @@ public class ForwardingRulesManagerImpl implements IForwardingRulesManager,
     /**
      * Function called by the dependency manager when all the required
      * dependencies are satisfied
-     * 
+     *
      */
     void init() {
         frmAware = Collections
@@ -2245,7 +2245,7 @@ public class ForwardingRulesManagerImpl implements IForwardingRulesManager,
      * Function called by the dependency manager when at least one dependency
      * become unsatisfied or when the component is shutting down because for
      * example bundle is being stopped.
-     * 
+     *
      */
     void destroy() {
         destroyCaches();
@@ -2254,7 +2254,7 @@ public class ForwardingRulesManagerImpl implements IForwardingRulesManager,
     /**
      * Function called by dependency manager after "init ()" is called and after
      * the services provided by the class are registered in the service registry
-     * 
+     *
      */
     void start() {
         /*
@@ -2270,7 +2270,7 @@ public class ForwardingRulesManagerImpl implements IForwardingRulesManager,
      * Function called by the dependency manager before the services exported by
      * the component are unregistered, this will be followed by a "destroy ()"
      * calls
-     * 
+     *
      */
     void stop() {
     }
@@ -2541,8 +2541,8 @@ public class ForwardingRulesManagerImpl implements IForwardingRulesManager,
         /*
          *  If this was for a flow install, remove the corresponding entry
          *  from the software view. If it was a Looking for the rid going through the
-         *  software database. 
-         *  TODO: A more efficient rid <->  FlowEntryInstall mapping will 
+         *  software database.
+         *  TODO: A more efficient rid <->  FlowEntryInstall mapping will
          *  have to be added in future
          */
         Set<FlowEntryInstall> entries = nodeFlows.get(node);
@@ -2559,7 +2559,7 @@ public class ForwardingRulesManagerImpl implements IForwardingRulesManager,
                 this.updateLocalDatabase(target, false);
             }
         }
-        
+
         // Notify listeners
         if (frmAware != null) {
             synchronized (frmAware) {
@@ -2573,19 +2573,19 @@ public class ForwardingRulesManagerImpl implements IForwardingRulesManager,
             }
         }
     }
-    
+
     @Override
     public Status solicitStatusResponse(Node node, boolean blocking) {
         Status rv = new Status(StatusCode.INTERNALERROR);
-        
+
         if (this.programmer != null) {
             if (blocking) {
                 rv = programmer.syncSendBarrierMessage(node);
             } else {
-                rv = programmer.asyncSendBarrierMessage(node);                
+                rv = programmer.asyncSendBarrierMessage(node);
             }
         }
-        
+
         return rv;
     }
 }
index cb15fb0..d7c6fdb 100644 (file)
@@ -26,7 +26,7 @@ public interface IfHostListener {
      * of coming up a new Host. For the hosts which it has already
      * learned, it refreshes them.
      *
-     * @param host             Host info encapsulated in HostNodeConnector class
+     * @param host      Host info encapsulated in HostNodeConnector class
      */
     public void hostListener(HostNodeConnector host);
 }
index 554da42..fdb1e72 100644 (file)
@@ -32,10 +32,10 @@ public interface IfIptoHost {
      * Northbound APIs. If a binding is unknown, then an ARP request is initiated
      * immediately to discover the host.
      *
-     * @param networkAddress   IP Address of the Host encapsulated in class InetAddress
-     * @return                                 {@link org.opendaylight.controller.hosttracker.hostAware.HostNodeConnector}
-     *                                                         Class that contains the Host info such as its MAC address,
-     *                                                         Switch ID, port, VLAN. If Host is not found, returns NULL
+     * @param networkAddress    IP Address of the Host encapsulated in class InetAddress
+     * @return                  {@link org.opendaylight.controller.hosttracker.hostAware.HostNodeConnector}
+     *                                                  Class that contains the Host info such as its MAC address,
+     *                                                  Switch ID, port, VLAN. If Host is not found, returns NULL
      */
     public HostNodeConnector hostFind(InetAddress networkAddress);
 
@@ -43,10 +43,10 @@ public interface IfIptoHost {
      * Checks the local Host Database to see if a Host has been learned for a
      * given IP address.
      *
-     * @param networkAddress   IP Address of the Host encapsulated in class InetAddress
-     * @return                                 {@link org.opendaylight.controller.hosttracker.hostAware.HostNodeConnector}
-     *                                                         Class that contains the Host info such as its MAC address,
-     *                                                         Switch ID, port, VLAN. If Host is not found, returns NULL
+     * @param networkAddress    IP Address of the Host encapsulated in class InetAddress
+     * @return                  {@link org.opendaylight.controller.hosttracker.hostAware.HostNodeConnector}
+     *                                                  Class that contains the Host info such as its MAC address,
+     *                                                  Switch ID, port, VLAN. If Host is not found, returns NULL
      *
      */
     public HostNodeConnector hostQuery(InetAddress networkAddress);
@@ -55,8 +55,8 @@ public interface IfIptoHost {
      * Initiates an immediate discovery of the Host for a given IP address. This
      * provides for the calling applications to block on the host discovery.
      *
-     * @param networkAddress           IP address encapsulated in InetAddress class
-     * @return                                         Future {@link org.opendaylight.controller.hosttracker.HostTrackerCallable}
+     * @param networkAddress            IP address encapsulated in InetAddress class
+     * @return                      Future {@link org.opendaylight.controller.hosttracker.HostTrackerCallable}
      */
     public Future<HostNodeConnector> discoverHost(InetAddress networkAddress);
 
@@ -64,8 +64,8 @@ public interface IfIptoHost {
      * Returns the Network Hierarchy for a given Host. This API is typically used by
      * applications like Hadoop for Rack Awareness functionality.
      *
-     * @param                                  IP address of the Host encapsulated in InetAddress class
-     * @return                                 List of String ArrayList containing the Hierarchies.
+     * @param                                   IP address of the Host encapsulated in InetAddress class
+     * @return                  List of String ArrayList containing the Hierarchies.
      */
     public List<List<String>> getHostNetworkHierarchy(InetAddress hostAddress);
 
@@ -73,9 +73,9 @@ public interface IfIptoHost {
      * Returns all the the Hosts either learned dynamically or added statically via
      * Northbound APIs.
      *
-     * @return                                 Set of {@link org.opendaylight.controller.hosttracker.hostAware.HostNodeConnector}.
-     *                                                         Class that contains the Host info such as its MAC address,
-     *                                                         Switch ID, port, VLAN.
+     * @return                  Set of {@link org.opendaylight.controller.hosttracker.hostAware.HostNodeConnector}.
+     *                                                  Class that contains the Host info such as its MAC address,
+     *                                                  Switch ID, port, VLAN.
      */
     public Set<HostNodeConnector> getAllHosts();
 
@@ -84,9 +84,9 @@ public interface IfIptoHost {
      * are categorized as "Active" because the Switch and Port they are connected to, are in
      * up state.
      *
-     * @return                                 Set of {@link org.opendaylight.controller.hosttracker.hostAware.HostNodeConnector}.
-     *                                                         Class that contains the Host info such as MAC address,
-     *                                                         Switch ID, port, VLAN. If Host is not found, returns NULL
+     * @return                  Set of {@link org.opendaylight.controller.hosttracker.hostAware.HostNodeConnector}.
+     *                                                  Class that contains the Host info such as MAC address,
+     *                                                  Switch ID, port, VLAN. If Host is not found, returns NULL
      */
     public Set<HostNodeConnector> getActiveStaticHosts();
 
@@ -95,10 +95,10 @@ public interface IfIptoHost {
      * are categorized as "Inactive" because either the Switch or the Port they are connected
      * to, is in down state.
      *
-     * @return                                 Set of HostNodeConnector {@link org.opendaylight.controller.hosttracker.hostAware.HostNodeConnector}.
-     *                                                         HostNodeConnector is Class that
-     *                                                         contains the Host info such as its MAC address, OpenFlowNode
-     *                                                         ID, port, VLAN.
+     * @return                  Set of HostNodeConnector {@link org.opendaylight.controller.hosttracker.hostAware.HostNodeConnector}.
+     *                                                  HostNodeConnector is Class that
+     *                                                  contains the Host info such as its MAC address, OpenFlowNode
+     *                                                  ID, port, VLAN.
      */
     public Set<HostNodeConnector> getInactiveStaticHosts();
 
@@ -106,12 +106,12 @@ public interface IfIptoHost {
      * Hosts can be learned dynamically or added statically. This method allows the addition
      * of a Host to the local database statically.
      *
-     * @param networkAddress           IP Address of the Host
-     * @param dataLayerAddress         MAC Address of the Host
-     * @param nc                                   NodeConnector to which the host is attached
-     * @param vlan                                     VLAN the host belongs to
-     * @return                                         The status object as described in {@code Status}
-     *                                                                 indicating the result of this action.
+     * @param networkAddress        IP Address of the Host
+     * @param dataLayerAddress      MAC Address of the Host
+     * @param nc                                    NodeConnector to which the host is attached
+     * @param vlan                  VLAN the host belongs to
+     * @return                      The status object as described in {@code Status}
+     *                                                          indicating the result of this action.
      */
     public Status addStaticHost(String networkAddress, String dataLayerAddress,
                                 NodeConnector nc, String vlan);
@@ -120,8 +120,8 @@ public interface IfIptoHost {
      * Allows the deletion of statically learned Host
      *
      * @param networkAddress
-     * @return                                         The status object as described in {@code Status}
-     *                                                                 indicating the result of this action.
+     * @return                      The status object as described in {@code Status}
+     *                                                          indicating the result of this action.
      */
     public Status removeStaticHost(String networkAddress);
 }
index 88db081..561f78f 100644 (file)
@@ -13,7 +13,7 @@ import org.opendaylight.controller.hosttracker.hostAware.HostNodeConnector;
 
 /**
  * This Interface defines the methods for client applications of
- * Host Tracker to get notifications when a new host is learned or 
+ * Host Tracker to get notifications when a new host is learned or
  * existing host is removed from the network.
  *
  */
@@ -21,7 +21,7 @@ public interface IfNewHostNotify {
     /**
      * Notifies the HostTracker Clients that a new Host has been learned
      *
-     * @param host             Host Info encapsulated in HostNodeConnector class
+     * @param host      Host Info encapsulated in HostNodeConnector class
      */
     public void notifyHTClient(HostNodeConnector host);
 
@@ -30,7 +30,7 @@ public interface IfNewHostNotify {
      * the past has been removed either due to switch/port down event or
      * due to ARP Aging
      *
-     * @param host             Host Info encapsulated in HostNodeConnector class
+     * @param host      Host Info encapsulated in HostNodeConnector class
      */
     public void notifyHTClientHostRemoved(HostNodeConnector host);
 }
index 5ea7fb0..533e759 100644 (file)
@@ -26,7 +26,7 @@ public interface IHostFinder {
      * by query of an application to the HostTracker. The requested IP address
      * doesn't exist in the local database at this point.
      *
-     * @param networkAddress   IP Address encapsulated in InetAddress class
+     * @param networkAddress    IP Address encapsulated in InetAddress class
      *
      */
     public void find(InetAddress networkAddress);
@@ -35,7 +35,7 @@ public interface IHostFinder {
      * This method is called by HostTracker to see if a learned Host is still in the network.
      * Used mostly for ARP Aging.
      *
-     * @param host                     The Host that needs to be probed
+     * @param host          The Host that needs to be probed
      */
     public void probe(HostNodeConnector host);
 }
index c29e5b1..2c2c49b 100644 (file)
@@ -29,61 +29,61 @@ import org.opendaylight.controller.sal.utils.NodeCreator;
 \r
 public class HostNodeConnectorTest extends TestCase {\r
 \r
-       @Test\r
-       public void testHostNodeConnector() throws UnknownHostException {\r
-               HostNodeConnector hostnodeconnector_1, hostnodeconnector_2, hostnodeconnector_3;\r
-               InetAddress hostIP_1 = InetAddress.getByName("192.168.0.8");\r
-               InetAddress hostIP_2 = InetAddress.getByName("2001:420:281:1004:e123:e688:d655:a1b0");\r
-               InetAddress hostIP_3 = InetAddress.getByName("192.168.0.28");\r
-               byte[] hostMAC_2 = new byte[]{(byte)0x11,(byte)0x22,(byte)0x33,(byte)0x22,(byte)0x22,(byte)0x22};\r
-               byte[] hostMAC_3 = new byte[]{(byte)0x11,(byte)0x22,(byte)0x33,(byte)0x33,(byte)0x33,(byte)0x33};\r
-               \r
-               Node node  = NodeCreator.createOFNode(1L);\r
-               NodeConnector nc1 = NodeConnectorCreator.createOFNodeConnector((short) 2, node);\r
-               NodeConnector nc2 = NodeConnectorCreator.createOFNodeConnector((short) 1, node);\r
-               \r
-               try {\r
-                       hostnodeconnector_1 = new HostNodeConnector(hostIP_1);\r
-                       Assert.assertTrue(hostnodeconnector_1.equalsByIP(hostIP_1));\r
-                       Assert.assertTrue(hostnodeconnector_1.isV4Host());\r
-                       Assert.assertTrue(hostnodeconnector_1.equalsByIP(hostIP_1));\r
-               } catch (ConstructionException e) {\r
-                       Assert.assertTrue(false);\r
-               }\r
-               \r
-               try {\r
-                       hostnodeconnector_2 = new HostNodeConnector(\r
-                               hostMAC_2, hostIP_2, nc1, (short)2);\r
-                       Assert.assertTrue(hostnodeconnector_2.isV6Host());\r
-                       Assert.assertTrue(hostnodeconnector_2.getnodeConnector().equals(nc1));\r
-                       Assert.assertTrue(hostnodeconnector_2.getnodeconnectorNode().equals(node));\r
+        @Test\r
+        public void testHostNodeConnector() throws UnknownHostException {\r
+                HostNodeConnector hostnodeconnector_1, hostnodeconnector_2, hostnodeconnector_3;\r
+                InetAddress hostIP_1 = InetAddress.getByName("192.168.0.8");\r
+                InetAddress hostIP_2 = InetAddress.getByName("2001:420:281:1004:e123:e688:d655:a1b0");\r
+                InetAddress hostIP_3 = InetAddress.getByName("192.168.0.28");\r
+                byte[] hostMAC_2 = new byte[]{(byte)0x11,(byte)0x22,(byte)0x33,(byte)0x22,(byte)0x22,(byte)0x22};\r
+                byte[] hostMAC_3 = new byte[]{(byte)0x11,(byte)0x22,(byte)0x33,(byte)0x33,(byte)0x33,(byte)0x33};\r
+\r
+                Node node  = NodeCreator.createOFNode(1L);\r
+                NodeConnector nc1 = NodeConnectorCreator.createOFNodeConnector((short) 2, node);\r
+                NodeConnector nc2 = NodeConnectorCreator.createOFNodeConnector((short) 1, node);\r
+\r
+                try {\r
+                        hostnodeconnector_1 = new HostNodeConnector(hostIP_1);\r
+                        Assert.assertTrue(hostnodeconnector_1.equalsByIP(hostIP_1));\r
+                        Assert.assertTrue(hostnodeconnector_1.isV4Host());\r
+                        Assert.assertTrue(hostnodeconnector_1.equalsByIP(hostIP_1));\r
+                } catch (ConstructionException e) {\r
+                        Assert.assertTrue(false);\r
+                }\r
+\r
+                try {\r
+                        hostnodeconnector_2 = new HostNodeConnector(\r
+                                hostMAC_2, hostIP_2, nc1, (short)2);\r
+                        Assert.assertTrue(hostnodeconnector_2.isV6Host());\r
+                        Assert.assertTrue(hostnodeconnector_2.getnodeConnector().equals(nc1));\r
+                        Assert.assertTrue(hostnodeconnector_2.getnodeconnectorNode().equals(node));\r
                         Assert.assertTrue(node.equals(hostnodeconnector_2.getnodeconnectorNode()));\r
-               } catch (ConstructionException e) {\r
-                       Assert.assertTrue(false);\r
-               }\r
-               \r
-               try {\r
-                       hostnodeconnector_3 = new HostNodeConnector(\r
-                                       new EthernetAddress(hostMAC_3), hostIP_3, nc2, (short)3);\r
-                       byte[] hostMAC_3_rb = hostnodeconnector_3.getDataLayerAddressBytes();\r
-                       HostNodeConnector  hostnodeconnector_3rb = new HostNodeConnector(\r
-                                       new EthernetAddress(hostMAC_3_rb), hostIP_3, nc2, (short)3);\r
-                       Assert.assertTrue(hostnodeconnector_3.equals(hostnodeconnector_3rb));\r
-                       \r
-                       Assert.assertTrue(hostnodeconnector_3.getVlan() == (short)3);\r
-                       \r
-                       hostnodeconnector_3.setStaticHost(true);\r
-                       Assert.assertTrue(hostnodeconnector_3.isStaticHost());\r
-                       \r
-                       Assert.assertTrue(hostnodeconnector_3.isRewriteEnabled());\r
-                       \r
-                       hostnodeconnector_3.initArpSendCountDown().setArpSendCountDown((short) 10);\r
-                       Assert.assertTrue(hostnodeconnector_3.getArpSendCountDown() == (short)10);\r
-                       \r
-               } catch (ConstructionException e) {\r
-                       Assert.assertTrue(false);\r
-               }\r
-               \r
-       }\r
+                } catch (ConstructionException e) {\r
+                        Assert.assertTrue(false);\r
+                }\r
+\r
+                try {\r
+                        hostnodeconnector_3 = new HostNodeConnector(\r
+                                        new EthernetAddress(hostMAC_3), hostIP_3, nc2, (short)3);\r
+                        byte[] hostMAC_3_rb = hostnodeconnector_3.getDataLayerAddressBytes();\r
+                        HostNodeConnector  hostnodeconnector_3rb = new HostNodeConnector(\r
+                                        new EthernetAddress(hostMAC_3_rb), hostIP_3, nc2, (short)3);\r
+                        Assert.assertTrue(hostnodeconnector_3.equals(hostnodeconnector_3rb));\r
+\r
+                        Assert.assertTrue(hostnodeconnector_3.getVlan() == (short)3);\r
+\r
+                        hostnodeconnector_3.setStaticHost(true);\r
+                        Assert.assertTrue(hostnodeconnector_3.isStaticHost());\r
+\r
+                        Assert.assertTrue(hostnodeconnector_3.isRewriteEnabled());\r
+\r
+                        hostnodeconnector_3.initArpSendCountDown().setArpSendCountDown((short) 10);\r
+                        Assert.assertTrue(hostnodeconnector_3.getArpSendCountDown() == (short)10);\r
+\r
+                } catch (ConstructionException e) {\r
+                        Assert.assertTrue(false);\r
+                }\r
+\r
+        }\r
 \r
 }\r
index 0af523a..1230d34 100644 (file)
@@ -15,8 +15,8 @@ package org.opendaylight.controller.hosttracker.internal;
 
 /**
  * This Class provides methods to discover Host through a blocking call
- * mechanism. Applications can make use of these methods if they don't 
- * find a host in HostTracker's database and want to discover the host  
+ * mechanism. Applications can make use of these methods if they don't
+ * find a host in HostTracker's database and want to discover the host
  * in the same thread without being called by a callback function.
  */
 import java.net.InetAddress;
index 9bd28c8..a99100b 100644 (file)
@@ -22,38 +22,38 @@ import org.opendaylight.controller.hosttracker.hostAware.HostNodeConnector;
 \r
 public class HostTrackerTest extends TestCase {\r
 \r
-       @Test\r
-       public void testHostTrackerCallable() throws UnknownHostException {\r
-               \r
-               HostTracker hostTracker = null;\r
-               hostTracker = new HostTracker();\r
-               Assert.assertFalse(hostTracker== null);\r
-               \r
-               InetAddress hostIP = InetAddress.getByName("192.168.0.8");\r
-               \r
-               HostTrackerCallable htCallable = new HostTrackerCallable (hostTracker, hostIP);\r
-               Assert.assertTrue(htCallable.trackedHost.equals(hostIP));\r
-               Assert.assertTrue(htCallable.hostTracker.equals(hostTracker));\r
-\r
-               long count = htCallable.latch.getCount();\r
-               htCallable.wakeup();\r
-               Assert.assertTrue(htCallable.latch.getCount() == --count );\r
-       }               \r
-               \r
-       \r
-       \r
-       @Test\r
-       public void testHostTracker() throws UnknownHostException {\r
-               HostTracker hostTracker = null;\r
-               hostTracker = new HostTracker();\r
-               Assert.assertFalse(hostTracker== null);\r
-               \r
-               InetAddress hostIP_1 = InetAddress.getByName("192.168.0.8");\r
-               InetAddress hostIP_2 = InetAddress.getByName("192.168.0.18");\r
-               Future<HostNodeConnector> dschost = hostTracker.discoverHost(hostIP_1);\r
-               dschost = hostTracker.discoverHost(hostIP_2);\r
-               hostTracker.nonClusterObjectCreate();\r
-       }\r
-       \r
+        @Test\r
+        public void testHostTrackerCallable() throws UnknownHostException {\r
+\r
+                HostTracker hostTracker = null;\r
+                hostTracker = new HostTracker();\r
+                Assert.assertFalse(hostTracker== null);\r
+\r
+                InetAddress hostIP = InetAddress.getByName("192.168.0.8");\r
+\r
+                HostTrackerCallable htCallable = new HostTrackerCallable (hostTracker, hostIP);\r
+                Assert.assertTrue(htCallable.trackedHost.equals(hostIP));\r
+                Assert.assertTrue(htCallable.hostTracker.equals(hostTracker));\r
+\r
+                long count = htCallable.latch.getCount();\r
+                htCallable.wakeup();\r
+                Assert.assertTrue(htCallable.latch.getCount() == --count );\r
+        }\r
+\r
+\r
+\r
+        @Test\r
+        public void testHostTracker() throws UnknownHostException {\r
+                HostTracker hostTracker = null;\r
+                hostTracker = new HostTracker();\r
+                Assert.assertFalse(hostTracker== null);\r
+\r
+                InetAddress hostIP_1 = InetAddress.getByName("192.168.0.8");\r
+                InetAddress hostIP_2 = InetAddress.getByName("192.168.0.18");\r
+                Future<HostNodeConnector> dschost = hostTracker.discoverHost(hostIP_1);\r
+                dschost = hostTracker.discoverHost(hostIP_2);\r
+                hostTracker.nonClusterObjectCreate();\r
+        }\r
+\r
 \r
 }\r
index 6bafee0..7061954 100644 (file)
@@ -56,7 +56,7 @@ public class Activator implements BundleActivator {
                         this.listener.logged(entry);
                     }
                 }
-                
+
                 /*
                  * Install the default exception handler so that the uncaught
                  * exceptions are handled by our customized handler. This new
@@ -65,13 +65,13 @@ public class Activator implements BundleActivator {
                  */
                 Thread.setDefaultUncaughtExceptionHandler(new org.opendaylight.
                         controller.logging.bridge.internal.UncaughtExceptionHandler());
-                
+
                 /*
                  * Install the Shutdown handler. This will intercept SIGTERM signal and
                  * close the system bundle. This allows for a graceful  closing of OSGI
                  * framework.
                  */
-                
+
                 Runtime.getRuntime().addShutdownHook(new shutdownHandler(context));
             } else {
                 this.log.error("Cannot register the LogListener because "
@@ -95,13 +95,13 @@ public class Activator implements BundleActivator {
         this.listener = null;
         this.log = null;
     }
-    
+
     private class shutdownHandler extends Thread {
         BundleContext bundlecontext;
         public shutdownHandler(BundleContext ctxt) {
                 this.bundlecontext = ctxt;
         }
-        
+
         public void run () {
             try {
                 this.bundlecontext.getBundle(0).stop();
@@ -109,7 +109,7 @@ public class Activator implements BundleActivator {
             } catch (BundleException e) {
                 log.debug("Bundle couldn't be stopped");
             }
-        }   
+        }
     }
 
 }
index 7069ff0..3fedd0c 100644 (file)
@@ -9,11 +9,11 @@ import org.opendaylight.controller.usermanager.IUserManager;
 
 public class NorthboundUtils {
 
-    
+
     /**
      * Returns whether the current user has the required privilege on the
      * specified container
-     * 
+     *
      * @param userName
      *            The user name
      * @param containerName
@@ -21,21 +21,21 @@ public class NorthboundUtils {
      * @param required
      *            Operation to be performed - READ/WRITE
      * @param bundle
-     *            Class from where the function is invoked           
+     *            Class from where the function is invoked
      * @return The Status of the request, either Success or Unauthorized
      */
     public static boolean isAuthorized(String userName, String containerName,
             Privilege required,Object bundle) {
-        
+
          if (containerName.equals(GlobalConstants.DEFAULT.toString())) {
             IUserManager auth = (IUserManager) ServiceHelper.getGlobalInstance(
                     IUserManager.class, bundle);
-            
+
             switch (required) {
             case WRITE:
                 return (auth.getUserLevel(userName).ordinal() <= UserLevel.NETWORKADMIN.ordinal());
             case READ:
-                return (auth.getUserLevel(userName).ordinal() <= UserLevel.NETWORKOPERATOR.ordinal());                    
+                return (auth.getUserLevel(userName).ordinal() <= UserLevel.NETWORKOPERATOR.ordinal());
             default:
                 return false;
             }
@@ -56,5 +56,5 @@ public class NorthboundUtils {
         }
         return true;
     }
-    
+
 }
index f6a757e..4b37612 100644 (file)
@@ -21,22 +21,22 @@ import org.opendaylight.controller.forwardingrulesmanager.FlowConfig;
 @XmlAccessorType(XmlAccessType.NONE)
 
 public class FlowConfigs {
-       @XmlElement
-       List<FlowConfig> flowConfig;
-       //To satisfy JAXB
-       private FlowConfigs() {
-               
-       }
-       
-       public FlowConfigs(List<FlowConfig> flowConfig) {
-               this.flowConfig = flowConfig;
-       }
-
-       public List<FlowConfig> getFlowConfig() {
-               return flowConfig;
-       }
-
-       public void setFlowConfig(List<FlowConfig> flowConfig) {
-               this.flowConfig = flowConfig;
-       }
+        @XmlElement
+        List<FlowConfig> flowConfig;
+        //To satisfy JAXB
+        private FlowConfigs() {
+
+        }
+
+        public FlowConfigs(List<FlowConfig> flowConfig) {
+                this.flowConfig = flowConfig;
+        }
+
+        public List<FlowConfig> getFlowConfig() {
+                return flowConfig;
+        }
+
+        public void setFlowConfig(List<FlowConfig> flowConfig) {
+                this.flowConfig = flowConfig;
+        }
 }
index 99452b4..b419a9b 100644 (file)
@@ -48,7 +48,7 @@ import org.opendaylight.controller.switchmanager.ISwitchManager;
 
 /**
  * Flow Configuration Northbound API
- * 
+ *
  * <br>
  * <br>
  * Authentication scheme : <b>HTTP Basic</b><br>
@@ -60,7 +60,7 @@ import org.opendaylight.controller.switchmanager.ISwitchManager;
  * trusted authority.<br>
  * More info :
  * http://tomcat.apache.org/tomcat-7.0-doc/ssl-howto.html#Configuration
- * 
+ *
  */
 @Path("/")
 public class FlowProgrammerNorthbound {
@@ -147,7 +147,7 @@ public class FlowProgrammerNorthbound {
 
     /**
      * Returns a list of Flows configured on the given container
-     * 
+     *
      * @param containerName
      *            Name of the Container. The Container name for the base
      *            controller is "default".
@@ -177,7 +177,7 @@ public class FlowProgrammerNorthbound {
 
     /**
      * Returns a list of Flows configured on a Node in a given container
-     * 
+     *
      * @param containerName
      *            Name of the Container. The Container name for the base
      *            controller is "default".
@@ -217,7 +217,7 @@ public class FlowProgrammerNorthbound {
     /**
      * Returns the flow configuration matching a human-readable name and nodeId
      * on a given Container.
-     * 
+     *
      * @param containerName
      *            Name of the Container. The Container name for the base
      *            controller is "default".
@@ -266,7 +266,7 @@ public class FlowProgrammerNorthbound {
 
     /**
      * Add a flow configuration
-     * 
+     *
      * @param containerName
      *            Name of the Container. The Container name for the base
      *            controller is "default".
@@ -330,9 +330,9 @@ public class FlowProgrammerNorthbound {
 
     /**
      * Delete a Flow configuration
-     * 
+     *
      * DELETE /flows/{containerName}/{nodeType}/{nodeId}/{name}
-     * 
+     *
      * @param containerName
      *            Name of the Container. The Container name for the base
      *            controller is "default".
@@ -392,7 +392,7 @@ public class FlowProgrammerNorthbound {
 
     /**
      * Toggle a Flow configuration
-     * 
+     *
      * @param containerName
      *            Name of the Container. The Container name for the base
      *            controller is "default".
index a9f210e..dbc99d0 100644 (file)
@@ -56,7 +56,7 @@ import org.opendaylight.controller.sal.authorization.Privilege;
  * Location is represented by Host node connector which is essentially a logical
  * entity that represents a Switch/Port. A host is represented by it's
  * IP-address and mac-address.
- * 
+ *
  * <br>
  * <br>
  * Authentication scheme : <b>HTTP Basic</b><br>
@@ -68,7 +68,7 @@ import org.opendaylight.controller.sal.authorization.Privilege;
  * trusted authority.<br>
  * More info :
  * http://tomcat.apache.org/tomcat-7.0-doc/ssl-howto.html#Configuration
- * 
+ *
  */
 
 @Path("/")
@@ -120,7 +120,7 @@ public class HostTrackerNorthbound {
     /**
      * Returns a list of all Hosts : both configured via PUT API and dynamically
      * learnt on the network.
-     * 
+     *
      * @param containerName
      *            Name of the Container. The Container name for the base
      *            controller is "default".
@@ -135,7 +135,7 @@ public class HostTrackerNorthbound {
             @ResponseCode(code = 404, condition = "The containerName is not found"),
             @ResponseCode(code = 503, condition = "One or more of Controller Services are unavailable") })
     public Hosts getActiveHosts(@PathParam("containerName") String containerName) {
+
         if (!NorthboundUtils.isAuthorized(
                 getUserName(), containerName, Privilege.READ, this)) {
             throw new UnauthorizedException(
@@ -154,7 +154,7 @@ public class HostTrackerNorthbound {
     /**
      * Returns a list of Hosts that are statically configured and are connected
      * to a NodeConnector that is down.
-     * 
+     *
      * @param containerName
      *            Name of the Container. The Container name for the base
      *            controller is "default".
@@ -187,7 +187,7 @@ public class HostTrackerNorthbound {
 
     /**
      * Returns a host that matches the IP Address value passed as parameter.
-     * 
+     *
      * @param containerName
      *            Name of the Container. The Container name for the base
      *            controller is "default".
@@ -236,7 +236,7 @@ public class HostTrackerNorthbound {
 
     /**
      * Add a Static Host configuration
-     * 
+     *
      * @param containerName
      *            Name of the Container. The Container name for the base
      *            controller is "default".
@@ -320,7 +320,7 @@ public class HostTrackerNorthbound {
 
     /**
      * Delete a Static Host configuration
-     * 
+     *
      * @param containerName
      *            Name of the Container. The Container name for the base
      *            controller is "default".
@@ -342,7 +342,7 @@ public class HostTrackerNorthbound {
     public Response deleteFlow(
             @PathParam(value = "containerName") String containerName,
             @PathParam(value = "networkAddress") String networkAddress) {
+
         if (!NorthboundUtils.isAuthorized(
                 getUserName(), containerName, Privilege.WRITE, this)) {
             throw new UnauthorizedException(
index 463b493..c9ada2a 100644 (file)
@@ -21,18 +21,18 @@ import org.opendaylight.controller.hosttracker.hostAware.HostNodeConnector;
 @XmlAccessorType(XmlAccessType.NONE)
 
 public class Hosts {
-       @XmlElement (name="host")
-       Set<HostNodeConnector> hostNodeConnector;
-       
-       public Hosts() {
-       }
-       public Hosts (Set<HostNodeConnector> hostNodeConnector) {
-               this.hostNodeConnector = hostNodeConnector;
-       }
-       public Set<HostNodeConnector> getHostNodeConnector() {
-               return hostNodeConnector;
-       }
-       public void setHostNodeConnector(Set<HostNodeConnector> hostNodeConnector) {
-               this.hostNodeConnector = hostNodeConnector;
-       }
+        @XmlElement (name="host")
+        Set<HostNodeConnector> hostNodeConnector;
+
+        public Hosts() {
+        }
+        public Hosts (Set<HostNodeConnector> hostNodeConnector) {
+                this.hostNodeConnector = hostNodeConnector;
+        }
+        public Set<HostNodeConnector> getHostNodeConnector() {
+                return hostNodeConnector;
+        }
+        public void setHostNodeConnector(Set<HostNodeConnector> hostNodeConnector) {
+                this.hostNodeConnector = hostNodeConnector;
+        }
 }
index 24eb3d7..0065cb5 100644 (file)
@@ -403,7 +403,7 @@ public class NorthboundIT {
             fc = "{\"dynamic\":\"false\", \"name\":\"test2\", \"nwSrc\":\"1.1.1.1\", \"node\":{\"@id\":\"51966\",\"@type\":\"STUB\"}, \"actions\":[\"DROP\"]}";
             result = getJsonResult(baseURL + "STUB/51966/test2", "POST", fc);
             Assert.assertTrue(httpResponseCode == 201);
-            
+
             // check that request returns both flows given node.
             result = getJsonResult(baseURL + "STUB/51966/", "GET");
             jt = new JSONTokener(result);
index 9511b8c..683a9a2 100644 (file)
@@ -21,22 +21,22 @@ import org.opendaylight.controller.forwardingrulesmanager.FlowConfig;
 @XmlAccessorType(XmlAccessType.NONE)
 
 public class StaticRoutes {
-       @XmlElement
-       List<StaticRoute> staticRoute;
-       //To satisfy JAXB
-       private StaticRoutes() {
-               
-       }
-       
-       public StaticRoutes(List<StaticRoute> staticRoute) {
-               this.staticRoute = staticRoute;
-       }
-
-       public List<StaticRoute> getFlowConfig() {
-               return staticRoute;
-       }
-
-       public void setFlowConfig(List<StaticRoute> staticRoute) {
-               this.staticRoute = staticRoute;
-       }
+        @XmlElement
+        List<StaticRoute> staticRoute;
+        //To satisfy JAXB
+        private StaticRoutes() {
+
+        }
+
+        public StaticRoutes(List<StaticRoute> staticRoute) {
+                this.staticRoute = staticRoute;
+        }
+
+        public List<StaticRoute> getFlowConfig() {
+                return staticRoute;
+        }
+
+        public void setFlowConfig(List<StaticRoute> staticRoute) {
+                this.staticRoute = staticRoute;
+        }
 }
index c48d7ec..b85f564 100644 (file)
@@ -51,7 +51,7 @@ import org.opendaylight.controller.sal.utils.Status;
  * Authentication realm : <b>opendaylight</b><br>
  * Transport : <b>HTTP and HTTPS</b><br>
  * <br>
- * HTTPS Authentication is disabled by default. Administrator can enable it in tomcat-server.xml after adding 
+ * HTTPS Authentication is disabled by default. Administrator can enable it in tomcat-server.xml after adding
  * a proper keystore / SSL certificate from a trusted authority.<br>
  * More info : http://tomcat.apache.org/tomcat-7.0-doc/ssl-howto.html#Configuration
  */
@@ -59,18 +59,18 @@ import org.opendaylight.controller.sal.utils.Status;
 public class StaticRoutingNorthbound {
 
 
-       private String username;
-       
+        private String username;
+
     @Context
     public void setSecurityContext(SecurityContext context) {
-       username = context.getUserPrincipal().getName();
+        username = context.getUserPrincipal().getName();
     }
     protected String getUserName() {
         return username;
     }
-       
 
-       
+
+
     private List<StaticRoute> getStaticRoutesInternal(String containerName) {
 
         IForwardingStaticRouting staticRouting = (IForwardingStaticRouting) ServiceHelper
@@ -109,9 +109,9 @@ public class StaticRoutingNorthbound {
     public StaticRoutes getStaticRoutes(
             @PathParam("containerName") String containerName) {
 
-        if(!NorthboundUtils.isAuthorized(getUserName(), containerName, 
+        if(!NorthboundUtils.isAuthorized(getUserName(), containerName,
                 Privilege.WRITE, this)){
-            throw new 
+            throw new
                 UnauthorizedException("User is not authorized to perform this operation on container "
                             + containerName);
         }
@@ -136,9 +136,9 @@ public class StaticRoutingNorthbound {
             @PathParam("containerName") String containerName,
             @PathParam("name") String name) {
 
-        if(!NorthboundUtils.isAuthorized(getUserName(), containerName, 
+        if(!NorthboundUtils.isAuthorized(getUserName(), containerName,
                 Privilege.WRITE, this)){
-            throw new 
+            throw new
                 UnauthorizedException("User is not authorized to perform this operation on container "
                             + containerName);
         }
@@ -174,10 +174,10 @@ public class StaticRoutingNorthbound {
             @PathParam(value = "name") String name,
             @TypeHint(StaticRoute.class) JAXBElement<StaticRoute> staticRouteData) {
 
-   
-        if(!NorthboundUtils.isAuthorized(getUserName(), containerName, 
+
+        if(!NorthboundUtils.isAuthorized(getUserName(), containerName,
                 Privilege.WRITE, this)){
-            throw new 
+            throw new
                 UnauthorizedException("User is not authorized to perform this operation on container "
                             + containerName);
         }
@@ -221,10 +221,10 @@ public class StaticRoutingNorthbound {
     public Response removeStaticRoute(
             @PathParam(value = "containerName") String containerName,
             @PathParam(value = "name") String name) {
-        if(!NorthboundUtils.isAuthorized(getUserName(), containerName, 
+
+        if(!NorthboundUtils.isAuthorized(getUserName(), containerName,
                 Privilege.WRITE, this)){
-            throw new 
+            throw new
                 UnauthorizedException("User is not authorized to perform this operation on container "
                             + containerName);
         }
index 0e96c54..7f37afe 100644 (file)
@@ -19,22 +19,22 @@ import javax.xml.bind.annotation.XmlRootElement;
 @XmlAccessorType(XmlAccessType.NONE)
 
 public class AllFlowStatistics {
-       @XmlElement
-       List<FlowStatistics> flowStatistics;
-       //To satisfy JAXB
-       private AllFlowStatistics() {
-       }
-       
-       public AllFlowStatistics(List<FlowStatistics> flowStatistics) {
-               this.flowStatistics = flowStatistics;
-       }
-
-       public List<FlowStatistics> getFlowStatistics() {
-               return flowStatistics;
-       }
-
-       public void setFlowStatistics(List<FlowStatistics> flowStatistics) {
-               this.flowStatistics = flowStatistics;
-       }
+        @XmlElement
+        List<FlowStatistics> flowStatistics;
+        //To satisfy JAXB
+        private AllFlowStatistics() {
+        }
+
+        public AllFlowStatistics(List<FlowStatistics> flowStatistics) {
+                this.flowStatistics = flowStatistics;
+        }
+
+        public List<FlowStatistics> getFlowStatistics() {
+                return flowStatistics;
+        }
+
+        public void setFlowStatistics(List<FlowStatistics> flowStatistics) {
+                this.flowStatistics = flowStatistics;
+        }
 
 }
index a1bf190..e377de2 100644 (file)
@@ -19,22 +19,22 @@ import javax.xml.bind.annotation.XmlRootElement;
 @XmlAccessorType(XmlAccessType.NONE)
 
 public class AllPortStatistics {
-       @XmlElement
-       List<PortStatistics> portStatistics;
-       //To satisfy JAXB
-       private AllPortStatistics() {
-       }
-       
-       public AllPortStatistics(List<PortStatistics> portStatistics) {
-               this.portStatistics = portStatistics;
-       }
-
-       public List<PortStatistics> getPortStatistics() {
-               return portStatistics;
-       }
-
-       public void setPortStatistics(List<PortStatistics> portStatistics) {
-               this.portStatistics = portStatistics;
-       }
+        @XmlElement
+        List<PortStatistics> portStatistics;
+        //To satisfy JAXB
+        private AllPortStatistics() {
+        }
+
+        public AllPortStatistics(List<PortStatistics> portStatistics) {
+                this.portStatistics = portStatistics;
+        }
+
+        public List<PortStatistics> getPortStatistics() {
+                return portStatistics;
+        }
+
+        public void setPortStatistics(List<PortStatistics> portStatistics) {
+                this.portStatistics = portStatistics;
+        }
 
 }
index 146e95a..25b671c 100644 (file)
@@ -27,7 +27,7 @@ public class FlowStatistics {
 
     // To satisfy JAXB
     @SuppressWarnings("unused")
-       private FlowStatistics() {
+        private FlowStatistics() {
     }
 
     public FlowStatistics(Node node, List<FlowOnNode> flowStat) {
index 068baa1..876bb7f 100644 (file)
@@ -28,7 +28,7 @@ public class PortStatistics {
 
     // To satisfy JAXB
     @SuppressWarnings("unused")
-       private PortStatistics() {
+        private PortStatistics() {
     }
 
     public PortStatistics(Node node, List<NodeConnectorStatistics> portStats) {
index dee5293..197ebab 100644 (file)
@@ -40,7 +40,7 @@ import org.opendaylight.controller.switchmanager.ISwitchManager;
 /**
  * Northbound APIs that returns various Statistics exposed by the Southbound
  * plugins such as Openflow.
- * 
+ *
  * <br>
  * <br>
  * Authentication scheme : <b>HTTP Basic</b><br>
@@ -52,7 +52,7 @@ import org.opendaylight.controller.switchmanager.ISwitchManager;
  * trusted authority.<br>
  * More info :
  * http://tomcat.apache.org/tomcat-7.0-doc/ssl-howto.html#Configuration
- * 
+ *
  */
 @Path("/")
 public class StatisticsNorthbound {
@@ -102,7 +102,7 @@ public class StatisticsNorthbound {
 
     /**
      * Returns a list of all Flow Statistics from all the Nodes.
-     * 
+     *
      * @param containerName
      *            Name of the Container. The Container name for the base
      *            controller is "default".
@@ -154,7 +154,7 @@ public class StatisticsNorthbound {
 
     /**
      * Returns a list of Flow Statistics for a given Node.
-     * 
+     *
      * @param containerName
      *            Name of the Container. The Container name for the base
      *            controller is "default".
@@ -204,7 +204,7 @@ public class StatisticsNorthbound {
     /**
      * Returns a list of all the Port Statistics across all the NodeConnectors
      * on all the Nodes.
-     * 
+     *
      * @param containerName
      *            Name of the Container. The Container name for the base
      *            controller is "default".
@@ -255,7 +255,7 @@ public class StatisticsNorthbound {
     /**
      * Returns a list of all the Port Statistics across all the NodeConnectors
      * in a given Node.
-     * 
+     *
      * @param containerName
      *            Name of the Container. The Container name for the base
      *            controller is "default".
index 60062ed..3361f1b 100644 (file)
@@ -21,22 +21,22 @@ import org.opendaylight.controller.switchmanager.SubnetConfig;
 @XmlAccessorType(XmlAccessType.NONE)
 
 public class SubnetConfigs {
-       @XmlElement
-       List<SubnetConfig> subnetConfig;
-       //To satisfy JAXB
-       private SubnetConfigs() {
-               
-       }
-       
-       public SubnetConfigs(List<SubnetConfig> subnetConfig) {
-               this.subnetConfig = subnetConfig;
-       }
-
-       public List<SubnetConfig> getSubnetConfig() {
-               return subnetConfig;
-       }
-
-       public void setSubnetConfig(List<SubnetConfig> subnetConfig) {
-               this.subnetConfig = subnetConfig;
-       }
+        @XmlElement
+        List<SubnetConfig> subnetConfig;
+        //To satisfy JAXB
+        private SubnetConfigs() {
+
+        }
+
+        public SubnetConfigs(List<SubnetConfig> subnetConfig) {
+                this.subnetConfig = subnetConfig;
+        }
+
+        public List<SubnetConfig> getSubnetConfig() {
+                return subnetConfig;
+        }
+
+        public void setSubnetConfig(List<SubnetConfig> subnetConfig) {
+                this.subnetConfig = subnetConfig;
+        }
 }
index 05bb5b1..5c327c4 100644 (file)
@@ -55,10 +55,10 @@ public class SubnetsNorthboundJAXRS {
 
     /**
      * List all the subnets in a given container
-     * 
+     *
      * @param containerName
      *            container in which we want to query the subnets
-     * 
+     *
      * @return a List of SubnetConfig
      */
     @Path("/{containerName}")
@@ -86,12 +86,12 @@ public class SubnetsNorthboundJAXRS {
 
     /**
      * List the configuration of a subnet in a given container
-     * 
+     *
      * @param containerName
      *            container in which we want to query the subnet
      * @param subnetName
      *            of the subnet being queried
-     * 
+     *
      * @return a SubnetConfig
      */
     @Path("/{containerName}/{subnetName}")
@@ -129,7 +129,7 @@ public class SubnetsNorthboundJAXRS {
 
     /**
      * Add/Update a subnet to a container
-     * 
+     *
      * @param containerName
      *            container in which we want to add/update the subnet
      * @param subnetName
@@ -137,7