Skip to content
Snippets Groups Projects
Commit 06cb326f authored by Shudong Zhou's avatar Shudong Zhou
Browse files

Minor findbugs fix for OFSwitchBase

parent 42577fde
No related branches found
No related tags found
No related merge requests found
......@@ -20,7 +20,6 @@ package net.floodlightcontroller.core;
import java.io.IOException;
import java.net.SocketAddress;
import java.util.Collection;
import java.util.Date;
import java.util.List;
import java.util.Map;
import java.util.concurrent.Future;
......@@ -293,7 +292,7 @@ public interface IOFSwitch {
* Retrieves the date the switch connected to this controller
* @return the date
*/
public Date getConnectedSince();
public String getConnectedSince();
/**
* Returns the next available transaction id
......
......@@ -72,7 +72,7 @@ import org.slf4j.LoggerFactory;
public abstract class OFSwitchBase implements IOFSwitch {
// TODO: should we really do logging in the class or should we throw
// exception that can then be handled by callers?
protected static Logger log = LoggerFactory.getLogger(OFSwitchBase.class);
protected static final Logger log = LoggerFactory.getLogger(OFSwitchBase.class);
protected ConcurrentMap<Object, Object> attributes;
protected IFloodlightProviderService floodlightProvider;
......@@ -144,8 +144,8 @@ public abstract class OFSwitchBase implements IOFSwitch {
// Defaults properties for an ideal switch
this.setAttribute(PROP_FASTWILDCARDS, OFMatch.OFPFW_ALL);
this.setAttribute(PROP_SUPPORTS_OFPP_FLOOD, new Boolean(true));
this.setAttribute(PROP_SUPPORTS_OFPP_TABLE, new Boolean(true));
this.setAttribute(PROP_SUPPORTS_OFPP_FLOOD, Boolean.valueOf(true));
this.setAttribute(PROP_SUPPORTS_OFPP_TABLE, Boolean.valueOf(true));
}
......@@ -440,8 +440,8 @@ public abstract class OFSwitchBase implements IOFSwitch {
}
@Override
public Date getConnectedSince() {
return connectedSince;
public String getConnectedSince() {
return connectedSince.toString();
}
@JsonIgnore
......
......@@ -21,7 +21,6 @@ import java.io.IOException;
import java.net.SocketAddress;
import java.util.Collection;
import java.util.Date;
import java.util.List;
import java.util.Map;
import java.util.concurrent.Future;
......@@ -228,7 +227,7 @@ public class OFMessageDamperMockSwitch implements IOFSwitch {
}
@Override
public Date getConnectedSince() {
public String getConnectedSince() {
assertTrue("Unexpected method call", false);
return null;
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment