faster dcgw failure detection using bfd.
Change-Id: I619e95c56f18782a4dec47f81e1f31f2bea256d7
Signed-off-by: Vyshakh Krishnan CH <vyshakh.krishnan.c.h@ericsson.com>
void deletePrefix(String rd, String prefix);
+ void setQbgpLog(String fileName, String logLevel);
+
/**
* Advertises a Prefix to a BGP neighbour, using several nexthops. Only sends the BGP messages, no writing to
* MD-SAL.
<artifactId>libthrift</artifactId>
<version>0.9.3</version>
</dependency>
+ <dependency>
+ <groupId>${project.groupId}</groupId>
+ <artifactId>fibmanager-api</artifactId>
+ <version>${project.version}</version>
+ </dependency>
<dependency>
<groupId>${project.groupId}</groupId>
<artifactId>vpnmanager-api</artifactId>
import com.google.common.net.InetAddresses;
import com.google.common.util.concurrent.ThreadFactoryBuilder;
import io.netty.util.concurrent.GlobalEventExecutor;
-import java.io.IOException;
import java.lang.reflect.Constructor;
import java.lang.reflect.InvocationTargetException;
import java.net.InetAddress;
import java.util.concurrent.Callable;
import java.util.concurrent.ConcurrentHashMap;
import java.util.concurrent.CountDownLatch;
+import java.util.concurrent.ExecutionException;
import java.util.concurrent.Executors;
import java.util.concurrent.Future;
import java.util.concurrent.ScheduledExecutorService;
import java.util.concurrent.ScheduledFuture;
import java.util.concurrent.TimeUnit;
+import java.util.concurrent.TimeoutException;
import java.util.concurrent.atomic.AtomicInteger;
import java.util.concurrent.atomic.AtomicReference;
import javax.annotation.Nullable;
import org.opendaylight.netvirt.bgpmanager.thrift.server.BgpThriftService;
import org.opendaylight.netvirt.fibmanager.api.RouteOrigin;
import org.opendaylight.netvirt.vpnmanager.api.intervpnlink.IVpnLinkService;
+import org.opendaylight.yang.gen.v1.urn.ericsson.params.xml.ns.yang.ebfd.rev190219.BfdConfig;
+import org.opendaylight.yang.gen.v1.urn.ericsson.params.xml.ns.yang.ebfd.rev190219.BfdConfigBuilder;
import org.opendaylight.yang.gen.v1.urn.ericsson.params.xml.ns.yang.ebgp.rev150901.AddressFamily;
import org.opendaylight.yang.gen.v1.urn.ericsson.params.xml.ns.yang.ebgp.rev150901.Bgp;
import org.opendaylight.yang.gen.v1.urn.ericsson.params.xml.ns.yang.ebgp.rev150901.BgpControlPlaneType;
import org.opendaylight.yang.gen.v1.urn.ericsson.params.xml.ns.yang.ebgp.rev150901.bgp.AsIdBuilder;
import org.opendaylight.yang.gen.v1.urn.ericsson.params.xml.ns.yang.ebgp.rev150901.bgp.ConfigServer;
import org.opendaylight.yang.gen.v1.urn.ericsson.params.xml.ns.yang.ebgp.rev150901.bgp.ConfigServerBuilder;
+import org.opendaylight.yang.gen.v1.urn.ericsson.params.xml.ns.yang.ebgp.rev150901.bgp.DcgwTepList;
import org.opendaylight.yang.gen.v1.urn.ericsson.params.xml.ns.yang.ebgp.rev150901.bgp.GracefulRestart;
import org.opendaylight.yang.gen.v1.urn.ericsson.params.xml.ns.yang.ebgp.rev150901.bgp.GracefulRestartBuilder;
import org.opendaylight.yang.gen.v1.urn.ericsson.params.xml.ns.yang.ebgp.rev150901.bgp.Logging;
import org.opendaylight.yang.gen.v1.urn.ericsson.params.xml.ns.yang.ebgp.rev150901.bgp.Vrfs;
import org.opendaylight.yang.gen.v1.urn.ericsson.params.xml.ns.yang.ebgp.rev150901.bgp.VrfsBuilder;
import org.opendaylight.yang.gen.v1.urn.ericsson.params.xml.ns.yang.ebgp.rev150901.bgp.VrfsKey;
+import org.opendaylight.yang.gen.v1.urn.ericsson.params.xml.ns.yang.ebgp.rev150901.bgp.dcgw.tep.list.DcgwTep;
+import org.opendaylight.yang.gen.v1.urn.ericsson.params.xml.ns.yang.ebgp.rev150901.bgp.dcgw.tep.list.DcgwTepBuilder;
+import org.opendaylight.yang.gen.v1.urn.ericsson.params.xml.ns.yang.ebgp.rev150901.bgp.dcgw.tep.list.DcgwTepKey;
import org.opendaylight.yang.gen.v1.urn.ericsson.params.xml.ns.yang.ebgp.rev150901.bgp.neighbors.AddressFamilies;
import org.opendaylight.yang.gen.v1.urn.ericsson.params.xml.ns.yang.ebgp.rev150901.bgp.neighbors.AddressFamiliesBuilder;
import org.opendaylight.yang.gen.v1.urn.ericsson.params.xml.ns.yang.ebgp.rev150901.bgp.neighbors.AddressFamiliesKey;
private static final String DEL_WARN = "Config store updated; undo with Add if needed.";
private static final String UPD_WARN = "Update operation not supported; Config store updated;"
+ " restore with another Update if needed.";
+ private static long bgp_as_num = 0;
private static final Class<?>[] REACTORS = {
ConfigServerReactor.class, AsIdReactor.class,
NeighborsReactor.class, UpdateSourceReactor.class,
EbgpMultihopReactor.class, AddressFamiliesReactor.class,
NetworksReactor.class, VrfsReactor.class, BgpReactor.class,
- MultipathReactor.class, VrfMaxpathReactor.class
+ MultipathReactor.class, VrfMaxpathReactor.class, BfdConfigReactor.class
};
private IBgpManager bgpManager;
bgpRouter.configServerUpdated();
synchronized (BgpConfigurationManager.this) {
- Bgp conf = getConfig();
- if (conf != null) {
- AsId asId = conf.getAsId();
- if (asId != null) {
- long asNum = asId.getLocalAs();
- try {
- bgpRouter.stopBgp(asNum);
- stopBgpCountersTask();
- stopBgpAlarmsTask();
- } catch (TException | BgpRouterException e) {
- LOG.error("{} Delete received exception; {}", YANG_OBJ, DEL_WARN, e);
- }
- } else {
- LOG.debug("bgp as-id is null while removing config-server");
+ if (bgp_as_num != 0) {
+ try {
+ bgpRouter.stopBgp(bgp_as_num);
+ stopBgpCountersTask();
+ stopBgpAlarmsTask();
+ } catch (TException | BgpRouterException e) {
+ LOG.error("{} Delete received exception; {}", YANG_OBJ, DEL_WARN, e);
}
} else {
- LOG.error("Config Null while removing the config-server");
+ LOG.debug("bgp as-id is null while removing config-server");
}
bgpRouter.disconnect();
}
return;
}
LOG.debug("received add router config asNum {}", val.getLocalAs());
+ bgp_as_num = val.getLocalAs().longValue();
synchronized (BgpConfigurationManager.this) {
BgpRouter br = getClient(YANG_OBJ);
if (br == null) {
synchronized (BgpConfigurationManager.this) {
long asNum = val.getLocalAs();
BgpRouter br = getClient(YANG_OBJ);
+ bgp_as_num = 0;
if (br == null) {
LOG.debug("{} Unable to process remove for asNum {}; {} {}", YANG_OBJ, asNum,
BgpRouterException.BGP_ERR_NOT_INITED, DEL_WARN);
if (bgpAlarms != null) {
bgpAlarms.clearBgpNbrDownAlarm(peerIp);
}
+
+ if (bgpUtil.isBfdEnabled()) {
+ final BgpCounters bgpCounters = getBgpCounters();
+ if (bgpCounters != null) {
+ bgpCounters.clearBfdNbrCounters(peerIp);
+ }
+ }
}
}
}
}
- protected void activateMIP() {
- try {
- LOG.trace("BgpReactor: Executing MIP Activate command");
- Runtime.getRuntime().exec("cluster ip -a sdnc_bgp_mip");
- Runtime.getRuntime().exec("cluster ip -a sdnc_os_mip");
- LOG.trace("bgpMIP Activated");
-
- } catch (IOException io) {
- LOG.error("IO Exception got while activating mip: {}", io.getMessage());
- }
- }
-
public class BgpReactor
extends AsyncDataTreeChangeListenerBase<Bgp, BgpReactor>
implements ClusteredDataTreeChangeListener<Bgp> {
if (!isBGPEntityOwner()) {
return;
}
- activateMIP();
}
}
@Override
protected void remove(InstanceIdentifier<VrfMaxpath> iid, VrfMaxpath vrfMaxPathVal) {
- executor.execute(new VrfMaxPathConfigurator(vrfMaxPathVal));
+ if (isBGPEntityOwner()) {
+ synchronized (BgpConfigurationManager.this) {
+ BgpRouter br = getClient(YANG_OBJ);
+ if (br != null) {
+ try {
+ br.multipaths(vrfMaxPathVal.getRd(), BgpConstants.BGP_DEFAULT_MULTIPATH);
+ LOG.debug("Del Maxpath for vrf: {} ", vrfMaxPathVal.getRd());
+ } catch (TException | BgpRouterException e) {
+ LOG.error(YANG_OBJ + " del received exception:", e);
+ }
+ }
+ }
+ }
}
@Override
}
}
+ public class BfdConfigReactor
+ extends AsyncDataTreeChangeListenerBase<BfdConfig, BfdConfigReactor>
+ implements ClusteredDataTreeChangeListener<BfdConfig> {
+
+ private static final String YANG_OBJ = "BfdConfig ";
+
+ public BfdConfigReactor() {
+ super(BfdConfig.class, BfdConfigReactor.class);
+ }
+
+ @Override
+ protected void add(InstanceIdentifier<BfdConfig> iid, BfdConfig val) {
+ if (!isBGPEntityOwner()) {
+ return;
+ }
+ BgpRouter br = getClient(YANG_OBJ);
+ LOG.debug("received bfd config: bfd enabled {} min-rx {} min-tx {} detect-mul {} mhop {}",
+ val.isBfdEnabled(), val.getMinRx(), val.getMinTx(),
+ val.getDetectMult(), val.isMultihop());
+ if (br == null) {
+ LOG.debug(YANG_OBJ + "{} Unable to process add {}",
+ BgpRouterException.BGP_ERR_NOT_INITED, ADD_WARN);
+ return;
+ }
+ if (val.isBfdEnabled() == false) {
+ LOG.debug("BFD not enabled. Ignoring the config add");
+ return;
+ }
+ int minRx = val.getMinRx().intValue();
+ int minTx = val.getMinTx().intValue();
+ int detectMult = val.getDetectMult().intValue();
+ boolean multiHop = val.isMultihop();
+ try {
+ br.addBfd(detectMult, minRx, minTx,multiHop);
+ } catch (TException | BgpRouterException e) {
+ LOG.error("{} get {}, Add received exception;", YANG_OBJ, ADD_WARN, e);
+ }
+ }
+
+ @Override
+ protected BfdConfigReactor getDataTreeChangeListener() {
+ return BfdConfigReactor.this;
+ }
+
+ @Override
+ protected InstanceIdentifier<BfdConfig> getWildCardPath() {
+ return InstanceIdentifier.create(BfdConfig.class);
+ }
+
+ @Override
+ protected void remove(InstanceIdentifier<BfdConfig> iid, BfdConfig val) {
+ if (!isBGPEntityOwner()) {
+ return;
+ }
+ LOG.debug("received bfd config removal");
+ BgpRouter br = getClient(YANG_OBJ);
+ if (br == null) {
+ LOG.debug("{} Unable to process del {} {}", YANG_OBJ,
+ BgpRouterException.BGP_ERR_NOT_INITED, ADD_WARN);
+ return;
+ }
+ try {
+ br.delBfd();
+ } catch (TException | BgpRouterException e) {
+ LOG.error("{} get {}, Del received exception;", YANG_OBJ, ADD_WARN, e);
+ }
+
+ }
+
+ @Override
+ protected void update(InstanceIdentifier<BfdConfig> iid,
+ BfdConfig oldval, BfdConfig newval) {
+ LOG.debug("received bfd config: updated oldval bfd enabled {}"
+ + "min-rx {} min-tx {} detect-mul {} mhop {}",
+ oldval.isBfdEnabled(), oldval.getMinRx(), oldval.getMinTx(),
+ oldval.getDetectMult(), oldval.isMultihop());
+ LOG.debug("received bfd config: updated newval bfd enabled {}"
+ + "min-rx {} min-tx {} detect-mul {} mhop {}",
+ newval.isBfdEnabled(), newval.getMinRx(), newval.getMinTx(),
+ newval.getDetectMult(), newval.isMultihop());
+ if (oldval.isBfdEnabled()) {
+ LOG.debug("deleting bfd config on an update");
+ remove(iid, oldval);
+ }
+ LOG.debug("adding bfd config on an update");
+ add(iid, newval);
+ }
+ }
+
+
public boolean isIpAvailable(String odlip) {
try {
cancelPreviousReplayJob();
}
Runnable task = () -> {
- LOG.info("running bgp replay task ");
- if (get() == null) {
- String host = getConfigHost();
- int port = getConfigPort();
- LOG.info("connecting to bgp host {} ", host);
- bgpRouter.connect(host, port);
- LOG.info("no config to push in bgp replay task ");
- return;
- }
- setStaleStartTime(System.currentTimeMillis());
- LOG.info("started creating stale fibDSWriter map ");
- createStaleFibMap();
- setStaleEndTime(System.currentTimeMillis());
- LOG.info("took {} msecs for stale fibDSWriter map creation ", getStaleEndTime() - getStaleStartTime());
- LOG.info("started bgp config replay ");
- setCfgReplayStartTime(System.currentTimeMillis());
- boolean replaySucceded = replay();
- setCfgReplayEndTime(System.currentTimeMillis());
- LOG.info("took {} msecs for bgp replay ", getCfgReplayEndTime() - getCfgReplayStartTime());
- if (replaySucceded) {
- LOG.info("starting the stale cleanup timer");
- long routeSyncTime = getStalePathtime(BGP_RESTART_ROUTE_SYNC_SEC, config.getAsId());
- setStaleCleanupTime(routeSyncTime);
- routeCleanupFuture = executor.schedule(new RouteCleanup(), routeSyncTime, TimeUnit.SECONDS);
- } else {
- staledFibEntriesMap.clear();
+ try {
+ LOG.info("running bgp replay task ");
+ if (get() == null) {
+ String host = getConfigHost();
+ int port = getConfigPort();
+ LOG.info("connecting to bgp host {} ", host);
+ bgpRouter.connect(host, port);
+ LOG.info("no config to push in bgp replay task ");
+ return;
+ }
+ setStaleStartTime(System.currentTimeMillis());
+ LOG.info("started creating stale fibDSWriter map ");
+ createStaleFibMap();
+ setStaleEndTime(System.currentTimeMillis());
+ LOG.info("took {} msecs for stale fibDSWriter map creation ", getStaleEndTime() - getStaleStartTime());
+ LOG.info("started bgp config replay ");
+ setCfgReplayStartTime(System.currentTimeMillis());
+ boolean replaySucceded = replay();
+ setCfgReplayEndTime(System.currentTimeMillis());
+ LOG.info("took {} msecs for bgp replay ", getCfgReplayEndTime() - getCfgReplayStartTime());
+ if (replaySucceded) {
+ LOG.info("starting the stale cleanup timer");
+ long routeSyncTime = getStalePathtime(BGP_RESTART_ROUTE_SYNC_SEC, config.getAsId());
+ setStaleCleanupTime(routeSyncTime);
+ routeCleanupFuture = executor.schedule(new RouteCleanup(), routeSyncTime, TimeUnit.SECONDS);
+ } else {
+ staledFibEntriesMap.clear();
+ }
+ } catch (InterruptedException | TimeoutException | ExecutionException eCancel) {
+ LOG.error("Stale Cleanup Task Cancelled", eCancel);
}
};
lastReplayJobFt = executor.submit(task);
}
}
+ public void peerDown(String ipAddress, long asNumber) {
+ List<String> tepIpList = bgpUtil.getDcgwTepConfig(ipAddress);
+ if (tepIpList == null) {
+ LOG.error("No Tep IP configured for DCGW {} on a peerDown", ipAddress);
+ return;
+ }
+ tepIpList.forEach(tepIp -> {
+ bgpUtil.removeOrUpdateLBGroups(tepIp, NwConstants.MOD_FLOW, false);
+ });
+ }
+
+ public void peerUp(String ipAddress, long asNumber) {
+ List<String> tepIpList = bgpUtil.getDcgwTepConfig(ipAddress);
+ if (tepIpList == null) {
+ LOG.error("No Tep IP configured for DCGW {} on a peerUp", ipAddress);
+ return;
+ }
+ tepIpList.forEach(tepIp -> {
+ bgpUtil.removeOrUpdateLBGroups(tepIp, NwConstants.MOD_FLOW, true);
+ });
+ }
+
private static boolean isRouteModified(int label, Long labelInStaleMap) {
return labelInStaleMap != null && !labelInStaleMap.equals(Long.valueOf(label));
}
final String md5password = extractMd5Secret(replayNbr.getNbr());
br.addNeighbor(replayNbr.getNbr().getAddress().getValue(),
replayNbr.getNbr().getRemoteAs().longValue(), md5password);
- UpdateSource us = replayNbr.getNbr().getUpdateSource();
- if (us != null) {
- LOG.debug("Replaying updatesource along with nbr: {} US-ip: {} to peer {}",
- replayNbr.getNbr().getAddress().getValue(),
- us.getSourceIp().getValue(),
- us.getPeerIp().getValue());
- br.addUpdateSource(us.getPeerIp().getValue(),
- us.getSourceIp().getValue());
- }
replayDone = true;
+ } catch (TApplicationException tae) {
+ LOG.debug("Replaying addNbr {}, tapplicationexception: ",
+ replayNbr.getNbr().getAddress().getValue(), tae);
+ if (tae.getType() == BgpRouterException.BGP_ERR_PEER_EXISTS) {
+ LOG.debug("Replaying addNbr Neighbor already present");
+ replayDone = true;
+ }
} catch (TException | BgpRouterException eNbr) {
LOG.debug("Replaying addNbr {}, exception: ", replayNbr.getNbr().getAddress().getValue(), eNbr);
}
- boolean replaySuccess = true;
- replaySuccess = replaySuccess && replayDone;
+
LOG.debug("Replay addNbr {} successful", replayNbr.getNbr().getAddress().getValue());
//Update Source handling
UpdateSource us = replayNbr.getNbr().getUpdateSource();
- if (replayDone == false && us != null) {
+ if (us != null) {
LOG.debug("Replaying updatesource {} to peer {}", us.getSourceIp().getValue(),
us.getPeerIp().getValue());
- replayDone = false;
try {
br.addUpdateSource(us.getPeerIp().getValue(),
us.getSourceIp().getValue());
- replayDone = true;
} catch (TException | BgpRouterException eUs) {
LOG.debug("Replaying UpdateSource for Nbr {}, exception:",
replayNbr.getNbr().getAddress().getValue(), eUs);
}
LOG.debug("Replay updatesource {} successful", us.getSourceIp().getValue());
- replaySuccess = replaySuccess && replayDone;
}
//Ebgp Multihope
EbgpMultihop en = replayNbr.getNbr().getEbgpMultihop();
if (en != null) {
- replayDone = false;
try {
br.addEbgpMultihop(en.getPeerIp().getValue(),
en.getNhops().intValue());
- replayDone = true;
} catch (TException | BgpRouterException eEbgpMhop) {
LOG.debug("Replaying EbgpMultihop for Nbr {}, exception: ",
replayNbr.getNbr().getAddress().getValue(), eEbgpMhop);
}
- replaySuccess = replaySuccess && replayDone;
}
//afs
for (AddressFamilies af : afs) {
af_afi afi = af_afi.findByValue(af.getAfi().intValue());
af_safi safi = af_safi.findByValue(af.getSafi().intValue());
- replayDone = false;
try {
br.addAddressFamily(af.getPeerIp().getValue(), afi, safi);
- replayDone = true;
} catch (TException | BgpRouterException eAFs) {
LOG.debug("Replaying AddressFamily for Nbr {}, exception:",
replayNbr.getNbr().getAddress().getValue(), eAFs);
}
- replaySuccess = replaySuccess && replayDone;
}
}
//replay is success --> no need to replay this nbr in next iteration.
- replayNbr.setShouldRetry(replaySuccess ? false : true);
+ replayNbr.setShouldRetry(replayDone ? false : true);
}
} while (nbrRetry.decrementAndRetry());
boolean replaySuccess = true;
}
@SuppressWarnings("checkstyle:IllegalCatch")
- public synchronized boolean replay() {
+ public synchronized boolean replay() throws InterruptedException, TimeoutException, ExecutionException {
boolean replaySucceded = true;
+ boolean doRouteSync = false;
String host = getConfigHost();
int port = getConfigPort();
LOG.error("connecting to bgp host {} ", host);
boolean res = bgpRouter.connect(host, port);
if (!res) {
- LOG.error("Cannot connect to BGP config server at {}:{}{}", host, port,
- config != null ? "; Configuration Replay aborted" : "");
+ LOG.error("Cannot connect to BGP config server at {} {}", host, port);
return replaySucceded;
}
config = getConfig();
LOG.debug("Starting the routesync for exception", bre);
startBgpRetry.errorOccured();
if (!startBgpRetry.shouldRetry()) {
- LOG.debug("starting route sync for BgpRouter exception");
- doRouteSync();
+ doRouteSync = true;
+ replayDone = true;
}
} else {
LOG.error("Replay: startBgp() received exception error {} : ",
LOG.debug("Starting the routesync for exception", tae);
startBgpRetry.errorOccured();
if (!startBgpRetry.shouldRetry()) {
- LOG.debug("starting route sync for Thrift BGP_ERR_ACTIVE exception");
- doRouteSync();
+ doRouteSync = true;
+ replayDone = true;
}
} else if (tae.getType() == BgpRouterException.BGP_ERR_COMMON_FAILURE) {
LOG.debug("Starting the routesync for AS-ID started exception", tae);
startBgpRetry.errorOccured();
if (!startBgpRetry.shouldRetry()) {
- LOG.debug("starting route sync for Thrift BGP_ERR_COMMON_FAILURE exception");
- doRouteSync();
+ doRouteSync = true;
+ replayDone = true;
}
} else {
LOG.error("Replay: startBgp() received exception type {}: ",
* commenting this due to a bug with QBGP. Will uncomment once QBGP fix is done.
* This wont have any functional impacts
*/
- try {
- br.delayEOR(delayEorSeconds);
- } catch (TException | BgpRouterException e) {
- LOG.error("Replay: delayEOR() number of seconds to wait for EOR from ODL:", e);
+ //try {
+ // br.delayEOR(delayEorSeconds);
+ //} catch (TException | BgpRouterException e) {
+ // LOG.error("Replay: delayEOR() number of seconds to wait for EOR from ODL:", e);
+ //}
+
+ BfdConfig bfdConfig = bgpUtil.getBfdConfig();
+ if (bfdConfig != null) {
+ if (bfdConfig.isBfdEnabled()) {
+ LOG.debug("Replaying bfd config min-rx {} min-tx {} detect-mul {} mhop {}",
+ bfdConfig.getMinRx(), bfdConfig.getMinTx(),
+ bfdConfig.getDetectMult(), bfdConfig.isMultihop());
+ try {
+ br.addBfd(bfdConfig.getDetectMult().intValue(), bfdConfig.getMinRx().intValue(),
+ bfdConfig.getMinTx().intValue(), bfdConfig.isMultihop());
+ } catch (TException | BgpRouterException e) {
+ LOG.error("Replay:addBfd() received exception", e);
+ }
+ }
}
List<Neighbors> neighbors = config.getNeighbors();
//send End of Rib Marker to Qthriftd.
final int numberOfEORRetries = 3;
- replayDone = false;
RetryOnException eorRetry = new RetryOnException(numberOfEORRetries);
do {
try {
br.sendEOR();
LOG.debug("Replay sendEOR {} successful");
- replayDone = true;
break;
} catch (Exception e) {
eorRetry.errorOccured();
}
} while (eorRetry.shouldRetry());
- return replaySucceded && replayDone;
+ if (doRouteSync) {
+ LOG.debug("starting route sync for Thrift BGP_ERR_COMMON_FAILURE exception "
+ + "happened earlier");
+ doRouteSync();
+ }
+
+ return replaySucceded;
}
private <T extends DataObject> void update(InstanceIdentifier<T> iid, T dto) {
update(iid, dto);
}
+ public void startBfd(long detectMult, long minRx, long minTx, boolean multiHop) {
+ InstanceIdentifier.InstanceIdentifierBuilder<BfdConfig> iib =
+ InstanceIdentifier.builder(BfdConfig.class);
+ InstanceIdentifier<BfdConfig> iid = iib.build();
+ BfdConfig dto = new BfdConfigBuilder()
+ .setBfdEnabled(true)
+ .setMultihop(multiHop)
+ .setMinRx(minRx)
+ .setMinTx(minTx)
+ .setDetectMult(detectMult)
+ .build();
+ update(iid, dto);
+ }
+
+ public void addDcgwTep(String dcgwIp, String tepIp) {
+ InstanceIdentifier.InstanceIdentifierBuilder<DcgwTep> iib =
+ InstanceIdentifier.builder(Bgp.class)
+ .child(DcgwTepList.class)
+ .child(DcgwTep.class, new DcgwTepKey(dcgwIp));
+ InstanceIdentifier<DcgwTep> iid = iib.build();
+ ArrayList<String> tepList = new ArrayList<String>();
+ tepList.add(tepIp);
+ DcgwTep dto = new DcgwTepBuilder().setDcGwIp(dcgwIp).setTepIps(tepList)
+ .build();
+ update(iid, dto);
+ }
+
public void addLogging(String fileName, String logLevel) {
InstanceIdentifier.InstanceIdentifierBuilder<Logging> iib =
InstanceIdentifier.builder(Bgp.class).child(Logging.class);
LOG.error("Error adding VRF to datastore", e);
throw new RuntimeException(e);
}
+
+ // enable multipath by default in all VRFs
+ setMultipaths(rd, BgpConstants.BGP_DEFAULT_MULTIPATH);
}
public void stopConfig() {
delete(iid);
}
+ public void stopBfd() {
+ InstanceIdentifier.InstanceIdentifierBuilder<BfdConfig> iib =
+ InstanceIdentifier.builder(BfdConfig.class);
+ InstanceIdentifier<BfdConfig> iid = iib.build();
+ delete(iid);
+ }
+
+ public void delDcgwTep(String dcgwIp, String tepIp) {
+ if (tepIp == null) {
+ InstanceIdentifier.InstanceIdentifierBuilder<DcgwTep> iib =
+ InstanceIdentifier.builder(Bgp.class)
+ .child(DcgwTepList.class)
+ .child(DcgwTep.class, new DcgwTepKey(dcgwIp));
+ InstanceIdentifier<DcgwTep> iid = iib.build();
+ delete(iid);
+ } else {
+ InstanceIdentifier.InstanceIdentifierBuilder<DcgwTep> iib =
+ InstanceIdentifier.builder(Bgp.class)
+ .child(DcgwTepList.class)
+ .child(DcgwTep.class, new DcgwTepKey(dcgwIp));
+ InstanceIdentifier<DcgwTep> iid = iib.build();
+ List<String> tepIpList = bgpUtil.getDcgwTepConfig(dcgwIp);
+ if (tepIpList == null) {
+ LOG.error("No Tep IP configured for DCGW {} on deleting the dcgwtep", dcgwIp);
+ return;
+ }
+ List<String> newTepIpList = new ArrayList<String>();
+ tepIpList.forEach(tep -> {
+ if (!tep.equals(tepIp)) {
+ newTepIpList.add(tep);
+ }
+ });
+ DcgwTep dto = new DcgwTepBuilder().setDcGwIp(dcgwIp).setTepIps(newTepIpList)
+ .build();
+ try {
+ SingleTransactionDataBroker.syncWrite(dataBroker,
+ LogicalDatastoreType.CONFIGURATION, iid, dto);
+ } catch (TransactionCommitFailedException e) {
+ LOG.error("delDcgwTep: Error deleting DCGW Tep", e);
+ throw new RuntimeException(e);
+ }
+ }
+ }
+
public void delLogging() {
InstanceIdentifier.InstanceIdentifierBuilder<Logging> iib =
InstanceIdentifier.builder(Bgp.class).child(Logging.class);
LOG.error("delVrf: vrf {}, addressFamily invalid", rd);
return false;
}
+ delMultipaths(rd);
AddressFamiliesVrfBuilder adfBuilder = new AddressFamiliesVrfBuilder();
if (addressFamily.equals(AddressFamily.IPV4)) {
adfBuilder.setAfi((long) af_afi.AFI_IP.getValue());
adfBuilder.setAfi((long) af_afi.AFI_IP.getValue());
adfBuilder.setSafi((long) af_safi.SAFI_EVPN.getValue());
}
+ LOG.debug("delVrf: Received Delete VRF : rd:{}, address family: {} {}", rd,
+ adfBuilder.getAfi(), adfBuilder.getSafi());
+
Vrfs vrfOriginal = bgpUtil.getVrfFromRd(rd);
if (vrfOriginal == null) {
LOG.error("delVrf: no vrf with existing rd {}. step aborted", rd);
InstanceIdentifier<Vrfs> iid = iib.build();
- InstanceIdentifier.builder(Bgp.class).build()
- .child(Multipath.class, new MultipathKey(adfBuilder.getAfi(), adfBuilder.getSafi()));
@SuppressWarnings("static-access")
- InstanceIdentifier<Bgp> iid6 = InstanceIdentifier.create(Bgp.class);
+ InstanceIdentifier<Bgp> iid6 = iid.builder(Bgp.class).build()
+ .child(Multipath.class, new MultipathKey(adfBuilder.getAfi(), adfBuilder.getSafi())).create(Bgp.class);
InstanceIdentifierBuilder<Vrfs> iib3 = iid6.child(Vrfs.class, new VrfsKey(rd)).builder();
InstanceIdentifier<Vrfs> iidFinal = iib3.build();
}
}
if (adfListOriginal.isEmpty()) {
+ LOG.debug("delVrf: delete iid: {}", iidFinal);
delete(iidFinal);
return true;
}
update(iib.build(), dto);
}
- public void multipaths(String rd, int maxpath) {
+ public void setMultipaths(String rd, int maxpath) {
InstanceIdentifier.InstanceIdentifierBuilder<VrfMaxpath> iib =
InstanceIdentifier
.builder(Bgp.class)
update(iib.build(), dto);
}
+ public void delMultipaths(String rd) {
+ InstanceIdentifier.InstanceIdentifierBuilder<VrfMaxpath> iib =
+ InstanceIdentifier.builder(Bgp.class)
+ .child(VrfMaxpath.class, new VrfMaxpathKey(rd));
+ InstanceIdentifier<VrfMaxpath> iid = iib.build();
+ delete(iid);
+ }
+
/*
* Remove Stale Marked Routes after timer expiry.
*/
}
public boolean isBgpConnected() {
- return bgpRouter.isBgpConnected();
+ return (bgpRouter == null) ? false : bgpRouter.isBgpConnected();
}
public long getLastConnectedTS() {
- return bgpRouter.getLastConnectedTS();
+ return (bgpRouter == null) ? 0 : bgpRouter.getLastConnectedTS();
}
public long getConnectTS() {
- return bgpRouter.getConnectTS();
+ return (bgpRouter == null) ? 0 : bgpRouter.getConnectTS();
}
public long getStartTS() {
- return bgpRouter.getStartTS();
+ return (bgpRouter == null) ? 0 : bgpRouter.getStartTS();
}
public TTransport getTransport() {
TimeUnit.MILLISECONDS);
LOG.info("Bgp Counters task scheduled for every two minutes.");
- addLogging(BgpConstants.BGP_DEF_LOG_FILE, BgpConstants.BGP_DEF_LOG_LEVEL);
+ bgpManager.setQbgpLog(BgpConstants.BGP_DEF_LOG_FILE, BgpConstants.BGP_DEF_LOG_LEVEL);
}
}
bgpAlarmsReference.get().init();
bgpAlarmsTask = executor.scheduleAtFixedRate(bgpAlarmsReference.get(), 0, 60 * 1000, TimeUnit.MILLISECONDS);
LOG.info("Bgp Alarms task scheduled for every minute.");
+ } else {
+ LOG.trace("Bgp Alarms task already scheduled for every minute.");
}
}
return bgpAlarmsReference.get();
}
+ public void getPeerStatus(String nbrIp, long nbrAsNum) throws
+ BgpRouterException, TException {
+ bgpRouter.getPeerStatus(nbrIp, nbrAsNum);
+ }
+
private static String appendNextHopToPrefix(String prefix, String nextHop) {
return prefix + ":" + nextHop;
}
import javax.annotation.PreDestroy;
import javax.inject.Inject;
import javax.inject.Singleton;
+import org.apache.thrift.TException;
import org.opendaylight.controller.md.sal.binding.api.DataBroker;
import org.opendaylight.controller.md.sal.binding.api.ReadOnlyTransaction;
import org.opendaylight.controller.md.sal.common.api.data.LogicalDatastoreType;
import org.opendaylight.netvirt.bgpmanager.api.IBgpManager;
import org.opendaylight.netvirt.bgpmanager.oam.BgpAlarmErrorCodes;
import org.opendaylight.netvirt.bgpmanager.oam.BgpConstants;
+import org.opendaylight.netvirt.bgpmanager.thrift.client.BgpRouterException;
+import org.opendaylight.netvirt.bgpmanager.thrift.gen.af_afi;
+import org.opendaylight.netvirt.bgpmanager.thrift.gen.af_safi;
import org.opendaylight.netvirt.fibmanager.api.RouteOrigin;
import org.opendaylight.yang.gen.v1.urn.ericsson.params.xml.ns.yang.ebgp.rev150901.AddressFamily;
import org.opendaylight.yang.gen.v1.urn.ericsson.params.xml.ns.yang.ebgp.rev150901.Bgp;
+import org.opendaylight.yang.gen.v1.urn.ericsson.params.xml.ns.yang.ebgp.rev150901.TcpMd5SignaturePasswordType;
import org.opendaylight.yang.gen.v1.urn.ericsson.params.xml.ns.yang.ebgp.rev150901.bgp.Neighbors;
import org.opendaylight.yang.gen.v1.urn.ericsson.params.xml.ns.yang.ebgp.rev150901.bgp.Networks;
import org.opendaylight.yang.gen.v1.urn.ericsson.params.xml.ns.yang.ebgp.rev150901.bgp.NetworksKey;
LOG.info("{} close", getClass().getSimpleName());
}
+ public BgpConfigurationManager getBgpConfigurationManager() {
+ return bcm;
+ }
+
+ public void configureGR(int stalepathTime) {
+ bcm.addGracefulRestart(stalepathTime);
+ }
+
+ public void delGracefulRestart() {
+ bcm.delGracefulRestart();
+ }
+
+ public void addNeighbor(String ipAddress, long asNum,
+ @Nullable final TcpMd5SignaturePasswordType md5Password) {
+ bcm.addNeighbor(ipAddress, asNum, md5Password);
+ }
+
+ public void addEbgpMultihop(String ipAddress, int nhops) {
+ bcm.addEbgpMultihop(ipAddress, nhops);
+ }
+
+ public void addUpdateSource(String ipAddress, String srcIp) {
+ bcm.addUpdateSource(ipAddress, srcIp);
+ }
+
+ public void addAddressFamily(String ipAddress, af_afi afi, af_safi safi) {
+ bcm.addAddressFamily(ipAddress, afi.getValue(), safi.getValue());
+ }
+
+ public void deleteNeighbor(String ipAddress) {
+ bcm.delNeighbor(ipAddress);
+ }
+
@Override
public void addVrf(String rd, Collection<String> importRts, Collection<String> exportRts,
AddressFamily addressFamily) {
@Override
public void deleteVrf(String rd, boolean removeFibTable, AddressFamily addressFamily) {
+ boolean ret = false;
if (removeFibTable) {
LOG.info("deleteVrf: suppressing FIB from rd {} with {}", rd, addressFamily);
fibDSWriter.removeVrfSubFamilyFromDS(rd, addressFamily);
}
- if (bcm.delVrf(rd, addressFamily) && removeFibTable) {
+ ret = bcm.delVrf(rd, addressFamily);
+ if (ret && removeFibTable) {
fibDSWriter.removeVrfFromDS(rd);
}
}
+ public void getAllPeerStatus() {
+ List<Neighbors> nbrList = null;
+ if (getConfig() != null) {
+ nbrList = getConfig().getNeighbors();
+ } else {
+ LOG.error("BGP configuration NOT exist");
+ return;
+ }
+ if (nbrList == null) {
+ return;
+ }
+
+ for (Neighbors nbr : nbrList) {
+ try {
+ LOG.trace("nbr {} checking status, AS num: {}", nbr.getAddress().getValue(), nbr.getRemoteAs());
+ bcm.getPeerStatus(nbr.getAddress().getValue(), nbr.getRemoteAs());
+ LOG.trace("nbr {} status is: PEER UP", nbr.getAddress().getValue());
+ } catch (BgpRouterException bre) {
+ if (bre.getErrorCode() == BgpRouterException.BGP_PEER_DOWN) {
+ LOG.trace("nbr {} status is: DOWN", nbr.getAddress().getValue());
+ } else if (bre.getErrorCode() == BgpRouterException.BGP_PEER_NOTCONFIGURED) {
+ LOG.trace("nbr {} status is: NOT CONFIGURED", nbr.getAddress().getValue());
+ } else if (bre.getErrorCode() == BgpRouterException.BGP_PEER_UNKNOWN) {
+ LOG.info("nbr {} status is: Unknown", nbr.getAddress().getValue());
+ } else {
+ LOG.info("nbr {} status is: Unknown, invalid BgpRouterException:",
+ nbr.getAddress().getValue(), bre);
+ }
+ } catch (TException tae) {
+ LOG.error("nbr {} status is: Unknown, received TException ", nbr.getAddress().getValue(), tae);
+ }
+ }
+ }
+
@Override
public void addPrefix(String rd, String macAddress, String prefix, List<String> nextHopList,
VrfEntry.EncapType encapType, int vpnLabel, long l3vni,
}
}
+ @Override
+ public void setQbgpLog(String fileName, String debugLevel) {
+ bcm.addLogging(fileName, debugLevel);
+ }
+
+ public void delLogging() {
+ bcm.delLogging();
+ }
+
+ public void startBgp(long asn, String routerId, int spt, boolean fbit) {
+ bcm.startBgp(asn, routerId, spt, fbit);
+ }
+
+ public void stopBgp() {
+ bcm.stopBgp();
+ }
+
+ public void startConfig(String host, int port) {
+ bcm.startConfig(host, port);
+ }
+
+ public void stopConfig() {
+ bcm.stopConfig();
+ }
+
+ public Bgp getConfig() {
+ return bcm.getConfig();
+ }
+
+ public void startBfd(int detectMult, int minRx, int minTx, boolean multiHop) {
+ bcm.startBfd(detectMult, minRx, minTx, multiHop);
+ }
+
+ public void stopBfd() {
+ bcm.stopBfd();
+ }
+
+ public void addDcgwTep(String dcgwIp, String tepIp) {
+ bcm.addDcgwTep(dcgwIp, tepIp);
+ }
+
+ public void delDcgwTep(String dcgwIp, String tepIp) {
+ bcm.delDcgwTep(dcgwIp, tepIp);
+ }
+
+ public void enableMultipath(af_afi afi, af_safi safi) {
+ bcm.setMultipathStatus(afi, safi,true);
+ }
+
+ public void disableMultipath(af_afi afi, af_safi safi) {
+ bcm.setMultipathStatus(afi, safi, false);
+ }
+
+ public void setMultipaths(String rd, int maxpath) {
+ bcm.setMultipaths(rd, maxpath);
+ }
+
@Override
public String getDCGwIP() {
Bgp conf = bcm.getConfig();
}
}
+ public FibDSWriter getFibWriter() {
+ return fibDSWriter;
+ }
+
+ public String getConfigHost() {
+ return bcm.getConfigHost();
+ }
+
+ public int getConfigPort() {
+ return bcm.getConfigPort();
+ }
+
+
@Override
public void bgpRestarted() {
bcm.bgpRestarted();
}
+ public BgpManager getBgpManager() {
+ return this;
+ }
+
+ public boolean isBgpConnected() {
+ return bcm.isBgpConnected();
+ }
+
+ public long getLastConnectedTS() {
+ return bcm.getLastConnectedTS();
+ }
+
+ public long getConnectTS() {
+ return bcm.getConnectTS();
+ }
+
+ public long getStartTS() {
+ return bcm.getStartTS();
+ }
+
public long getQbgprestartTS() {
return qbgprestartTS;
}
public void setQbgprestartTS(long qbgprestartTS) {
this.qbgprestartTS = qbgprestartTS;
}
+
+ public long getStaleStartTime() {
+ return bcm.getStaleStartTime();
+ }
+
+ public long getStaleEndTime() {
+ return bcm.getStaleEndTime();
+ }
+
+ public long getCfgReplayStartTime() {
+ return bcm.getCfgReplayStartTime();
+ }
+
+ public long getCfgReplayEndTime() {
+ return bcm.getCfgReplayEndTime();
+ }
+
+ public long getStaleCleanupTime() {
+ return bcm.getStaleCleanupTime();
+ }
+
+
}
*/
package org.opendaylight.netvirt.bgpmanager;
+import static java.util.stream.Collectors.toList;
+
import com.google.common.base.Optional;
import java.net.Inet4Address;
import java.net.Inet6Address;
import java.net.InetAddress;
+import java.util.ArrayList;
+import java.util.Collections;
+import java.util.List;
import java.util.concurrent.BlockingQueue;
import java.util.concurrent.LinkedBlockingQueue;
import javax.annotation.PostConstruct;
import org.opendaylight.controller.md.sal.binding.api.DataBroker;
import org.opendaylight.controller.md.sal.common.api.data.LogicalDatastoreType;
import org.opendaylight.genius.mdsalutil.MDSALUtil;
+import org.opendaylight.genius.mdsalutil.NwConstants;
import org.opendaylight.genius.utils.batching.ActionableResource;
import org.opendaylight.genius.utils.batching.ActionableResourceImpl;
import org.opendaylight.genius.utils.batching.DefaultBatchHandler;
import org.opendaylight.netvirt.bgpmanager.thrift.gen.af_safi;
import org.opendaylight.netvirt.bgpmanager.thrift.gen.encap_type;
import org.opendaylight.netvirt.bgpmanager.thrift.gen.protocol_type;
+import org.opendaylight.netvirt.fibmanager.api.IFibManager;
+import org.opendaylight.yang.gen.v1.urn.ericsson.params.xml.ns.yang.ebfd.rev190219.BfdConfig;
import org.opendaylight.yang.gen.v1.urn.ericsson.params.xml.ns.yang.ebgp.rev150901.Bgp;
import org.opendaylight.yang.gen.v1.urn.ericsson.params.xml.ns.yang.ebgp.rev150901.BgpControlPlaneType;
import org.opendaylight.yang.gen.v1.urn.ericsson.params.xml.ns.yang.ebgp.rev150901.EncapType;
import org.opendaylight.yang.gen.v1.urn.ericsson.params.xml.ns.yang.ebgp.rev150901.LayerType;
+import org.opendaylight.yang.gen.v1.urn.ericsson.params.xml.ns.yang.ebgp.rev150901.bgp.DcgwTepList;
import org.opendaylight.yang.gen.v1.urn.ericsson.params.xml.ns.yang.ebgp.rev150901.bgp.Vrfs;
import org.opendaylight.yang.gen.v1.urn.ericsson.params.xml.ns.yang.ebgp.rev150901.bgp.VrfsKey;
+import org.opendaylight.yang.gen.v1.urn.ericsson.params.xml.ns.yang.ebgp.rev150901.bgp.dcgw.tep.list.DcgwTep;
+import org.opendaylight.yang.gen.v1.urn.ericsson.params.xml.ns.yang.ebgp.rev150901.bgp.dcgw.tep.list.DcgwTepKey;
import org.opendaylight.yang.gen.v1.urn.ericsson.params.xml.ns.yang.ebgp.rev150901.bgp.vrfs.AddressFamiliesVrf;
import org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.IpAddress;
-import org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.IpAddressBuilder;
+import org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.Ipv4Address;
+import org.opendaylight.yang.gen.v1.urn.opendaylight.genius.interfacemanager.rev160406.TunnelTypeBase;
+import org.opendaylight.yang.gen.v1.urn.opendaylight.genius.interfacemanager.rev160406.TunnelTypeMplsOverGre;
+import org.opendaylight.yang.gen.v1.urn.opendaylight.genius.itm.op.rev160406.DpnEndpoints;
+import org.opendaylight.yang.gen.v1.urn.opendaylight.genius.itm.op.rev160406.dpn.endpoints.DPNTEPsInfo;
+import org.opendaylight.yang.gen.v1.urn.opendaylight.genius.itm.rev160406.DcGatewayIpList;
import org.opendaylight.yang.gen.v1.urn.opendaylight.netvirt.elan.rev150602.ElanInstances;
import org.opendaylight.yang.gen.v1.urn.opendaylight.netvirt.elan.rev150602.elan.instances.ElanInstance;
import org.opendaylight.yang.gen.v1.urn.opendaylight.netvirt.elan.rev150602.elan.instances.ElanInstanceKey;
private static final String RESOURCE_TYPE = "BGP-RESOURCES";
private static final int DEFAULT_BATCH_SIZE = 1000;
private static final int DEFAULT_BATCH_INTERVAL = 500;
+ private int enableBfdFlag = -1;
private final DataBroker dataBroker;
+ private final IFibManager fibManager;
+
private final BlockingQueue<ActionableResource> bgpResourcesBufferQ = new LinkedBlockingQueue<>();
@Inject
- public BgpUtil(DataBroker dataBroker) {
+ public BgpUtil(DataBroker dataBroker, final IFibManager fibManager) {
this.dataBroker = dataBroker;
+ this.fibManager = fibManager;
}
@PostConstruct
public static int getAFItranslatedfromPrefix(String argPrefix) {
int retValue = af_afi.AFI_IP.getValue();//default afiValue is 1 (= ipv4)
String prefixOnly;
- if (!argPrefix.contains("/")) {
+ if (argPrefix.indexOf("/") == -1) {
prefixOnly = argPrefix;
} else {
prefixOnly = argPrefix.substring(0, argPrefix.indexOf("/"));
InstanceIdentifier<ExternalTeps> externalTepsId = getExternalTepsIdentifier(elanName, tepIp);
ExternalTepsBuilder externalTepsBuilder = new ExternalTepsBuilder();
ExternalTepsKey externalTepsKey = externalTepsId.firstKeyOf(ExternalTeps.class);
- externalTepsBuilder.withKey(externalTepsKey);
externalTepsBuilder.setTepIp(externalTepsKey.getTepIp());
update(externalTepsId, externalTepsBuilder.build());
}
}
private static InstanceIdentifier<ExternalTeps> getExternalTepsIdentifier(String elanInstanceName, String tepIp) {
- IpAddress tepAdress = tepIp == null ? null : IpAddressBuilder.getDefaultInstance(tepIp);
+ IpAddress tepAdress = tepIp == null ? null : new IpAddress(new Ipv4Address(tepIp));
return InstanceIdentifier.builder(ElanInstances.class).child(ElanInstance.class,
new ElanInstanceKey(elanInstanceName)).child(ExternalTeps.class,
new ExternalTepsKey(tepAdress)).build();
.child(VrfEntry.class, new VrfEntryKey(vrfEntry.getDestPrefix())).build();
delete(vrfEntryId);
}
+
+ public void enableBfdFlag() {
+ enableBfdFlag = 1;
+ }
+
+ public void disableBfdFlag() {
+ enableBfdFlag = 0;
+ }
+
+ public boolean isBfdEnabled() {
+ if (enableBfdFlag == 1) {
+ return true;
+ } else if (enableBfdFlag == 0) {
+ return false;
+ }
+ BfdConfig bfdConfig = getBfdConfig();
+ if (bfdConfig != null) {
+ return bfdConfig.isBfdEnabled();
+ }
+ return false;
+ }
+
+ public BfdConfig getBfdConfig() {
+ InstanceIdentifier<BfdConfig> id =
+ InstanceIdentifier.builder(BfdConfig.class).build();
+ Optional<BfdConfig> bfdConfigOptional = MDSALUtil.read(dataBroker,
+ LogicalDatastoreType.CONFIGURATION, id);
+ if (bfdConfigOptional.isPresent()) {
+ return bfdConfigOptional.get();
+ }
+ return null;
+ }
+
+ public DcgwTepList getDcgwTepConfig() {
+ InstanceIdentifier<DcgwTepList> id =
+ InstanceIdentifier.builder(Bgp.class).child(DcgwTepList.class).build();
+ Optional<DcgwTepList> dcgwTepListOptional = MDSALUtil.read(dataBroker,
+ LogicalDatastoreType.CONFIGURATION, id);
+ if (dcgwTepListOptional.isPresent()) {
+ return dcgwTepListOptional.get();
+ }
+ return null;
+ }
+
+ public List<String> getDcgwTepConfig(String dcgwIp) {
+ InstanceIdentifier<DcgwTep> id =
+ InstanceIdentifier.builder(Bgp.class)
+ .child(DcgwTepList.class)
+ .child(DcgwTep.class, new DcgwTepKey(dcgwIp)).build();
+ Optional<DcgwTep> tepListOptional = MDSALUtil.read(dataBroker,
+ LogicalDatastoreType.CONFIGURATION, id);
+ if (tepListOptional.isPresent()) {
+ return tepListOptional.get().getTepIps();
+ }
+ LOG.debug("No tep configured for DCGW {}", dcgwIp);
+ return null;
+ }
+
+ public static List<DPNTEPsInfo> getDpnTEPsInfos(DataBroker dataBroker) {
+ InstanceIdentifier<DpnEndpoints> iid = InstanceIdentifier.builder(DpnEndpoints.class).build();
+ Optional<DpnEndpoints> dpnEndpoints = MDSALUtil.read(LogicalDatastoreType.CONFIGURATION, iid, dataBroker);
+ if (dpnEndpoints.isPresent()) {
+ return dpnEndpoints.get().getDPNTEPsInfo();
+ } else {
+ return new ArrayList<>();
+ }
+ }
+
+ private List<String> getDcGwIps() {
+ InstanceIdentifier<DcGatewayIpList> dcGatewayIpListid =
+ InstanceIdentifier.builder(DcGatewayIpList.class).build();
+ DcGatewayIpList dcGatewayIpListConfig =
+ MDSALUtil.read(dataBroker, LogicalDatastoreType.CONFIGURATION, dcGatewayIpListid).orNull();
+ if (dcGatewayIpListConfig == null) {
+ return Collections.EMPTY_LIST;
+ }
+ return dcGatewayIpListConfig.getDcGatewayIp()
+ .stream()
+ .filter(dcGwIp -> dcGwIp.getTunnnelType().equals(TunnelTypeMplsOverGre.class))
+ .map(dcGwIp -> String.valueOf(dcGwIp.getIpAddress().getIpv4Address())).sorted()
+ .collect(toList());
+ }
+
+
+ public void removeOrUpdateLBGroups(String tepIp, int addRemoveOrUpdate, boolean isTunnelUp) {
+ LOG.debug("removing bucket towards DCGW {}", tepIp);
+ List<String> availableDcGws = getDcGwIps();
+ getDpnTEPsInfos(dataBroker).forEach(dpnInfo -> {
+ if (NwConstants.MOD_FLOW == addRemoveOrUpdate) {
+ LOG.debug("Updating bucket in DPN {}", dpnInfo.getDPNID());
+ } else if (NwConstants.DEL_FLOW == addRemoveOrUpdate) {
+ LOG.debug("Deleting groups in DPN {}", dpnInfo.getDPNID());
+ }
+ Class<? extends TunnelTypeBase> tunType = TunnelTypeMplsOverGre.class;
+ fibManager.programDcGwLoadBalancingGroup(availableDcGws, dpnInfo.getDPNID(),
+ tepIp, addRemoveOrUpdate, isTunnelUp, tunType);
+ });
+ }
}
--- /dev/null
+/*
+ * Copyright (c) 2015 Ericsson India Global Services Pvt Ltd. and others. All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+
+package org.opendaylight.netvirt.bgpmanager.commands;
+
+import static org.opendaylight.netvirt.bgpmanager.oam.BgpConstants.MAX_DETECT_MULT;
+import static org.opendaylight.netvirt.bgpmanager.oam.BgpConstants.MIN_DETECT_MULT;
+import static org.opendaylight.netvirt.bgpmanager.oam.BgpConstants.MIN_RX_MAX;
+import static org.opendaylight.netvirt.bgpmanager.oam.BgpConstants.MIN_RX_MIN;
+import static org.opendaylight.netvirt.bgpmanager.oam.BgpConstants.MIN_TX_MAX;
+import static org.opendaylight.netvirt.bgpmanager.oam.BgpConstants.MIN_TX_MIN;
+
+import java.io.PrintStream;
+
+import org.apache.karaf.shell.commands.Argument;
+import org.apache.karaf.shell.commands.Command;
+import org.apache.karaf.shell.commands.Option;
+import org.apache.karaf.shell.console.OsgiCommandSupport;
+import org.opendaylight.netvirt.bgpmanager.BgpManager;
+import org.opendaylight.netvirt.bgpmanager.oam.BgpConstants;
+
+@Command(scope = "odl", name = "bfd-config",
+ description = "Add or delete BFD neighbor")
+public class Bfd extends OsgiCommandSupport {
+ private static final String RX = "--min-rx";
+ private static final String TX = "--min-tx";
+ private static final String DM = "--detect-mult";
+ private static final String MH = "--multi-hop";
+
+ @Argument(index = 0, name = "add|del", description = "The desired operation",
+ required = true, multiValued = false)
+ String action = null;
+
+ @Option(name = RX, aliases = {"-r"},
+ description = "Minimum BFD receive interval in millisec"
+ + "<" + MIN_RX_MIN + "-" + MIN_RX_MAX + ">",
+ required = false, multiValued = false)
+ String minRX = null;
+
+ @Option(name = TX, aliases = {"-t"},
+ description = "Minimum BFD transmit interval in millisec"
+ + "<" + MIN_TX_MIN + "-" + MIN_TX_MAX + ">",
+ required = false, multiValued = false)
+ String minTX = null;
+
+ @Option(name = DM, aliases = {"-d"},
+ description = "No of packet miss for marking session down"
+ + "<" + MIN_DETECT_MULT + "-" + MAX_DETECT_MULT + ">",
+ required = false, multiValued = false)
+ String detectMult = null;
+
+ @Option(name = MH, aliases = {"-m"},
+ description = "Multi-Hop or Single-Hop BFD"
+ + "<true/false>",
+ required = false, multiValued = false)
+ String multiHop = null;
+
+ private final BgpManager bgpManager;
+
+ public Bfd(BgpManager bgpManager) {
+ this.bgpManager = bgpManager;
+ }
+
+ private Object usage() {
+ session.getConsole().println(
+ "usage: bgp-config [" + RX + " min-rx-interval] [" + TX + " min-tx-interval] ["
+ + DM + " detect-multiplier] [" + MH + " true|false] <add|del>");
+ return null;
+ }
+
+ @Override
+ protected Object doExecute() throws Exception {
+ PrintStream ps = session.getConsole();
+ switch (action) {
+ case "add" :
+ int minrx = BgpConstants.BFD_DEFAULT_MIN_RX;
+ int mintx = BgpConstants.BFD_DEFAULT_MIN_TX;
+ int detectmult = BgpConstants.BFD_DEFAULT_DETECT_MULT;
+ boolean multihop = true;
+ if (minRX != null) {
+ if (!Commands.isValid(ps, minRX, Commands.Validators.INT, RX)) {
+ return null;
+ } else {
+ minrx = Integer.parseInt(minRX);
+ if (minrx < MIN_RX_MIN || minrx > MIN_RX_MAX) {
+ ps.println("error: value of RX should be between 50 and 50000");
+ return null;
+ }
+ }
+ }
+
+ if (minTX != null) {
+ if (!Commands.isValid(ps, minTX, Commands.Validators.INT, TX)) {
+ return null;
+ } else {
+ mintx = Integer.parseInt(minTX);
+ if (mintx < MIN_TX_MIN || mintx > MIN_TX_MAX) {
+ ps.println("error: value of TX should be between 1000 and 60000");
+ return null;
+ }
+ }
+ }
+
+ if (detectMult != null) {
+ if (!Commands.isValid(ps, detectMult, Commands.Validators.INT, DM)) {
+ return null;
+ } else {
+ detectmult = Integer.parseInt(detectMult);
+ if (detectmult < MIN_DETECT_MULT || detectmult > MAX_DETECT_MULT) {
+ ps.println("error: value of detectMult should be between 2 to 255");
+ return null;
+ }
+ }
+ }
+
+ if (multiHop != null) {
+ if (!multiHop.equals("true") && !multiHop.equals("false")) {
+ ps.println("error: " + MH + "must be true or false");
+ return null;
+ }
+ if (multiHop.equals("false")) {
+ multihop = false;
+ }
+ }
+
+ bgpManager.startBfd(detectmult, minrx, mintx, multihop);
+
+ break;
+ case "del" :
+ if (detectMult != null || minRX != null || minTX != null || multiHop != null) {
+ session.getConsole().println("note: some option(s) not needed; ignored");
+ }
+ bgpManager.stopBfd();
+ break;
+ default :
+ return usage();
+ }
+ return null;
+ }
+}
--- /dev/null
+/*
+ * Copyright (c) 2015 Ericsson India Global Services Pvt Ltd. and others. All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+
+
+package org.opendaylight.netvirt.bgpmanager.commands;
+
+import edu.umd.cs.findbugs.annotations.SuppressFBWarnings;
+import java.io.PrintStream;
+import org.apache.felix.service.command.CommandSession;
+import org.apache.karaf.shell.commands.Command;
+import org.apache.karaf.shell.console.OsgiCommandSupport;
+import org.opendaylight.netvirt.bgpmanager.BgpUtil;
+import org.opendaylight.yang.gen.v1.urn.ericsson.params.xml.ns.yang.ebfd.rev190219.BfdConfig;
+import org.opendaylight.yang.gen.v1.urn.ericsson.params.xml.ns.yang.ebgp.rev150901.bgp.DcgwTepList;
+
+
+
+@Command(scope = "odl", name = "bfd-cache",
+ description = "Text dump of BFD config cache")
+@SuppressFBWarnings("DM_DEFAULT_ENCODING")
+public class BfdCache extends OsgiCommandSupport {
+ private static final String MINRX = "min-rx";
+ private static final String MINTX = "min-tx";
+ private static final String DMULT = "detect-mult";
+ private static final String MLHOP = "multi-hop";
+ private static final String DCGWIP = "dcgw-ip";
+ private static final String TEPIP = "tep-ip";
+
+ private final BgpUtil bgpUtil;
+
+ public BfdCache(BgpUtil bgpUtil) {
+ this.bgpUtil = bgpUtil;
+ }
+
+ /*private Object usage() {
+ session.getConsole().println("usage: bfd-cache ");
+ return null;
+ }*/
+
+ public Object show(CommandSession session) throws Exception {
+ this.session = session;
+ return doExecute();
+ }
+
+ public Object show() throws Exception {
+ return doExecute();
+ }
+
+ @SuppressWarnings("resource")
+ @Override
+ protected Object doExecute() throws Exception {
+
+ PrintStream ps = session.getConsole();
+ BfdConfig bfdConfig = bgpUtil.getBfdConfig();
+ if (bfdConfig != null) {
+ boolean bfdEnabled = bfdConfig.isBfdEnabled();
+ ps.printf("%nbfd-enabled %s%n", bfdEnabled ? "yes" : "no");
+ int minrx = bfdConfig.getMinRx().intValue();
+ int mintx = bfdConfig.getMinTx().intValue();
+ int detectmult = bfdConfig.getDetectMult().intValue();
+ boolean multihop = bfdConfig.isMultihop();
+ ps.printf("%n\t%-15s %d%n\t%-15s %d%n\t%-15s %d%n\t%-15s %s%n",
+ MINRX, minrx, MINTX, mintx, DMULT, detectmult, MLHOP, multihop ? "yes" : "no");
+ } else {
+ ps.printf("%nbfd-enabled %s%n", "no");
+ }
+
+ DcgwTepList dcgwTepList = bgpUtil.getDcgwTepConfig();
+ if (dcgwTepList != null) {
+ dcgwTepList.getDcgwTep().forEach(dcgwTep -> {
+ ps.printf("%n%n%-15s %s", DCGWIP, dcgwTep.getDcGwIp());
+ dcgwTep.getTepIps().forEach(tep -> {
+ ps.printf("%n\t%-15s %s", TEPIP, tep);
+ });
+ });
+ ps.printf("%n");
+ }
+ return null;
+ }
+}
--- /dev/null
+/*
+ * Copyright (c) 2015 Ericsson India Global Services Pvt Ltd. and others. All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+
+package org.opendaylight.netvirt.bgpmanager.commands;
+
+import java.io.PrintStream;
+
+import org.apache.karaf.shell.commands.Argument;
+import org.apache.karaf.shell.commands.Command;
+import org.apache.karaf.shell.commands.Option;
+import org.apache.karaf.shell.console.OsgiCommandSupport;
+import org.opendaylight.netvirt.bgpmanager.BgpManager;
+
+
+@Command(scope = "odl", name = "associate-dcgw-tep",
+ description = "Add or delete DCGW BGP peer-ip to TEP mapping")
+public class DcgwTep extends OsgiCommandSupport {
+ private static final String DCGW = "--dc-gw";
+ private static final String TEP = "--tep";
+
+ @Argument(index = 0, name = "add|del", description = "The desired operation",
+ required = true, multiValued = false)
+ String action = null;
+
+ @Option(name = DCGW, aliases = {"-d"},
+ description = "DCGW BGP IP configured",
+ required = true, multiValued = false)
+ String dcgw = null;
+
+ @Option(name = TEP, aliases = {"-t"},
+ description = "TEP IP configured in the DCGW",
+ required = false, multiValued = false)
+ String tep = null;
+
+ private final BgpManager bgpManager;
+
+ public DcgwTep(BgpManager bgpManager) {
+ this.bgpManager = bgpManager;
+ }
+
+ private Object usage() {
+ session.getConsole().println(
+ "usage: associate-dcgw-tep" + DCGW + " dcgw-ip" + TEP + " tep-ip <add|del>");
+ return null;
+ }
+
+ @Override
+ protected Object doExecute() throws Exception {
+ PrintStream ps = session.getConsole();
+ switch (action) {
+ case "add" :
+ if (dcgw == null) {
+ ps.println("error: " + DCGW + " needed");
+ return null;
+ }
+ if (!Commands.isValid(session.getConsole(), dcgw, Commands.Validators.IPADDR, DCGW)) {
+ return null;
+ }
+ if (tep == null) {
+ ps.println("error: " + TEP + " needed");
+ return null;
+ }
+ if (!Commands.isValid(session.getConsole(), tep, Commands.Validators.IPADDR, TEP)) {
+ return null;
+ }
+ bgpManager.addDcgwTep(dcgw, tep);
+ break;
+
+ case "del" :
+ if (dcgw == null) {
+ ps.println("error: " + DCGW + " needed");
+ return null;
+ }
+ if (!Commands.isValid(session.getConsole(), dcgw, Commands.Validators.IPADDR, DCGW)) {
+ return null;
+ }
+ if (tep != null
+ && !Commands.isValid(session.getConsole(), tep, Commands.Validators.IPADDR, TEP)) {
+ return null;
+ }
+ bgpManager.delDcgwTep(dcgw, tep);
+ break;
+ default :
+ return usage();
+ }
+ return null;
+ }
+}
break;
case "setmaxpath":
if (rd != null && maxpath != null) {
- bgpConfigurationManager.multipaths(rd, Integer.parseInt(maxpath));
+ bgpConfigurationManager.setMultipaths(rd, Integer.parseInt(maxpath));
}
break;
String BGP_COUNTER_RD_ROUTE_COUNT = "BgpRdRouteCount";
String BGP_COUNTER_TOTAL_PFX = "BgpTotalPrefixes:Bgp_Total_Prefixes";
String BGP_DEF_LOG_LEVEL = "debugging";
- String BGP_DEF_LOG_FILE = "/opt/quagga/var/log/quagga/zrpc.init.log";
+ String BGP_DEF_LOG_FILE = "/opt/quagga/var/log/quagga/zrpcd.init.log";
+ String BFD_COUNTER_NBR_PKTS_RX = "BfdNeighborPacketsReceived";
+ String BFD_COUNTER_NBR_PKTS_TX = "BfdNeighborPacketsSent";
long DEFAULT_ETH_TAG = 0L;
+ int BGP_DEFAULT_MULTIPATH = 2;
+ int BFD_DEFAULT_DETECT_MULT = 3;
+ int BFD_DEFAULT_MIN_RX = 500;
+ int BFD_DEFAULT_MIN_TX = 6000;
+ int MIN_RX_MIN = 50;
+ int MIN_RX_MAX = 50000;
+ int MIN_TX_MIN = 1000;
+ int MIN_TX_MAX = 60000;
+ int MIN_DETECT_MULT = 2;
+ int MAX_DETECT_MULT = 255;
+ int BFD_DEFAULT_FAILURE_THRESHOLD = 0;
+ int BFD_DEFAULT_SUCCESS_THRESHOLD = 0;
}
public static final String BGP_VPNV6_SUMMARY_FILE = "cmd_ip_bgp_vpnv6_all_summary.txt";
public static final String BGP_VPNV4_SUMMARY_FILE = "cmd_ip_bgp_vpnv4_all_summary.txt";
public static final String BGP_EVPN_SUMMARY_FILE = "cmd_bgp_evpn_all_summary.txt";
+ public static final String BFD_NBR_DETAIL_FILE = "cmd_bfd_neighbors_details.txt";
+
+ // BFD related constants
+ public static final int LINE = 1; // line where the ip address of neigbor present after "NeighbroAddr"
+ public static final int NBR_IP_WORD_INDEX = 1; // word where the ip address is present (count start from 0)
+ public static final int RX_COUNT_WORD_INDEX = 1; // word where the Rx Count is present after split :
+ public static final int TX_COUNT_WORD_INDEX = 1; // word where the Tx Count is present after split :
private static final Logger LOG = LoggerFactory.getLogger(BgpCounters.class);
fetchCmdOutputs(BGP_VPNV4_FILE, "show ip bgp vpnv4 all");
fetchCmdOutputs(BGP_VPNV6_FILE, "show ip bgp vpnv6 all");
fetchCmdOutputs(BGP_EVPN_FILE, "show bgp l2vpn evpn all");
+ fetchCmdOutputs(BFD_NBR_DETAIL_FILE, "show bgp bfd neighbors details");
+
parseIpBgpSummary();
parseIpBgpVpnv4All();
parseIpBgpVpnv6All();
parseBgpL2vpnEvpnAll();
+ parseBfdNbrsDetails();
LOG.debug("Finished updating the counters from BGP");
}
final String tx = result[4];
Counter counter = getCounter(BgpConstants.BGP_COUNTER_NBR_PKTS_RX, as,
- rx, null, strIp, null);
+ rx, null, strIp, null, "bgp-peer");
updateCounter(counter, Long.parseLong(rx));
counter = getCounter(BgpConstants.BGP_COUNTER_NBR_PKTS_TX, as,
- null, tx, strIp, null);
+ null, tx, strIp, null, "bgp-peer");
updateCounter(counter, Long.parseLong(tx));
}
}
long bgpTotalPfxs = calculateBgpTotalPrefixes();
LOG.trace("BGP Total Prefixes:{}",bgpTotalPfxs);
Counter counter = getCounter(BgpConstants.BGP_COUNTER_TOTAL_PFX, null, null, null,
- null, null);
+ null, null, "bgp-peer");
updateCounter(counter, bgpTotalPfxs);
}
+ private void parseBfdNbrsDetails() {
+ File file = new File(BFD_NBR_DETAIL_FILE);
+ List<String> inputStrs = new ArrayList<>();
+
+ try (Scanner scanner = new Scanner(file)) {
+ while (scanner.hasNextLine()) {
+ inputStrs.add(scanner.nextLine());
+ }
+ } catch (IOException e) {
+ LOG.error("Could not process the file {}", file.getAbsolutePath());
+ return;
+ }
+ String neighborIPstr = null;
+ for (int i = 0; i < inputStrs.size(); i++) {
+ String instr = inputStrs.get(i);
+ if (instr.contains("NeighAddr") && instr.contains("State")) {
+ neighborIPstr = inputStrs.get(i + LINE).split("\\s+")[NBR_IP_WORD_INDEX];
+ if (!validate(neighborIPstr, af_afi.AFI_IP)) {
+ LOG.error("Invalid neighbor IP {}", neighborIPstr);
+ return;
+ }
+ }
+ if ((neighborIPstr != null) && inputStrs.get(i).contains("Rx Count:")
+ && inputStrs.get(i + 1).contains("Tx Count:")) {
+ //Rx Count:
+ long rxCount = 0;
+ try {
+ rxCount = Long.parseLong(inputStrs.get(i).split(":")[RX_COUNT_WORD_INDEX].trim());
+ }
+ catch (NumberFormatException e) {
+ LOG.error("Rx count Number format exception: {}",
+ inputStrs.get(i + 1).split(":")[RX_COUNT_WORD_INDEX].trim());
+ rxCount = 0;
+ }
+
+ //Tx Count:
+ long txCount = 0;
+ try {
+ txCount = Long.parseLong(inputStrs.get(i + 1).split(":")
+ [TX_COUNT_WORD_INDEX].trim());
+ } catch (NumberFormatException e) {
+ LOG.error("Tx count Number format exception: {}",
+ inputStrs.get(i + 1).split(":")[TX_COUNT_WORD_INDEX].trim());
+ txCount = 0;
+ }
+ Counter counter = getCounter(BgpConstants.BFD_COUNTER_NBR_PKTS_RX, null,
+ Long.toString(rxCount), null, neighborIPstr, null, "bfd-peer");
+ updateCounter(counter, rxCount);
+
+ counter = getCounter(BgpConstants.BFD_COUNTER_NBR_PKTS_TX, null,
+ null, Long.toString(txCount), neighborIPstr, null, "bfd-peer");
+ updateCounter(counter, txCount);
+
+ //Counter fetching is done, search for next BFD Neighbor IP
+ neighborIPstr = null;
+ }
+ }
+ }
+
private int processRouteCount(String rd, int startIndex, List<String> inputStrs) {
int num = startIndex;
long routeCount = 0;
String bgpRdRouteCountKey = BgpConstants.BGP_COUNTER_RD_ROUTE_COUNT + rd;
Counter counter = getCounter(BgpConstants.BGP_COUNTER_RD_ROUTE_COUNT, null, null, null,
- null, rd);
+ null, rd, "bgp-peer");
for (String str = inputStrs.get(num); str != null && !str.trim().equals("")
&& num < inputStrs.size();
resetFile(BGP_VPNV4_FILE);
resetFile(BGP_VPNV6_FILE);
resetFile(BGP_EVPN_FILE);
+ resetFile(BFD_NBR_DETAIL_FILE);
}
static void resetFile(String fileName) {
String[] result = str.split("\\s+");
if (result.length > 9) {
String strIp = result[0].trim();
- LOG.trace("strIp {}", strIp);
+ LOG.trace("strIp {} ", strIp);
if (!validate(strIp, afi)) {
break;
* @return counter object.
*/
private Counter getCounter(String counterName, String asValue,
- String rxValue, String txValue, String neighborIp, String rdValue) {
+ String rxValue, String txValue, String neighborIp, String rdValue, String peerType) {
String counterTypeEntityCounter = "entitycounter";
String labelKeyEntityType = "entitytype";
- String labelValEntityTypeBgpPeer = "bgp-peer";
+ String labelValEntityTypeBgpPeer = null;
String labelKeyAsId = "asid";
String labelKeyNeighborIp = "neighborip";
Counter counter = null;
+ if (peerType.equals("bgp-peer")) {
+ labelValEntityTypeBgpPeer = "bgp-peer";
+ } else if (peerType.equals("bfd-peer")) {
+ labelValEntityTypeBgpPeer = "bfd-peer";
+ } else {
+ //nothing defined, default to "bgp-peer"
+ labelValEntityTypeBgpPeer = "bgp-peer";
+ }
+
if (rxValue != null) {
/*
* Following is the key pattern for Counter BgpNeighborPacketsReceived
return counter;
}
+ public void clearBfdNbrCounters(String neighborIPstr) {
+ Counter bfdRxCounter = getCounter(BgpConstants.BFD_COUNTER_NBR_PKTS_RX, null,
+ Long.toString(0), null, neighborIPstr, null, "bfd-peer");
+ updateCounter(bfdRxCounter, 0);
+
+ Counter bfdTxCounter = getCounter(BgpConstants.BFD_COUNTER_NBR_PKTS_TX, null,
+ null, Long.toString(0), neighborIPstr, null, "bfd-peer");
+ updateCounter(bfdTxCounter, 0);
+ }
+
}
import org.apache.thrift.transport.TTransportException;
import org.opendaylight.netvirt.bgpmanager.BgpConfigurationManager;
import org.opendaylight.netvirt.bgpmanager.RetryOnException;
+import org.opendaylight.netvirt.bgpmanager.thrift.gen.BfdConfigData;
import org.opendaylight.netvirt.bgpmanager.thrift.gen.BgpConfigurator;
import org.opendaylight.netvirt.bgpmanager.thrift.gen.Routes;
import org.opendaylight.netvirt.bgpmanager.thrift.gen.af_afi;
private static final int CONNECTION_TIMEOUT = 60000;
private enum Optype {
- START, STOP, NBR, VRF, PFX, SRC, MHOP, LOG, AF, GR, MP, VRFMP, EOR, DELAY_EOR
+ START, STOP, NBR, VRF, PFX, SRC, MHOP, LOG, AF, GR, MP, VRFMP, EOR, DELAY_EOR, BFD, PEER_STATUS
}
private static class BgpOp {
Optype type;
boolean add;
+ boolean multiHop;
String[] strs;
int[] ints;
List<String> irts;
BgpOp() {
strs = new String[3];
- ints = new int[2];
+ ints = new int[3];
}
}
case DELAY_EOR:
bgpClient.send_enableEORDelay(op.delayEOR);
break;
+ case BFD:
+ BfdConfigData bfdConfigData = new BfdConfigData();
+ bfdConfigData.setBfdConfigDataVersion((byte)1);
+ bfdConfigData.setBfdDebounceDown(0);
+ bfdConfigData.setBfdDebounceUp(0);
+ bfdConfigData.setBfdFailureThreshold((byte)op.ints[0]);
+ bfdConfigData.setBfdRxInterval(op.ints[1]);
+ bfdConfigData.setBfdTxInterval(op.ints[2]);
+ bfdConfigData.setBfdMultihop(op.multiHop);
+ result = bop.add
+ ? bgpClient.enableBFDFailover(bfdConfigData)
+ : bgpClient.disableBFDFailover();
+ break;
+ case PEER_STATUS:
+ result = bgpClient.getPeerStatus(op.strs[0], op.asNumber).getValue();
+ break;
default:
break;
}
dispatch(bop);
}
+ public synchronized void addBfd(int detectMult, int minRx, int minTx, boolean multiHop)
+ throws TException, BgpRouterException {
+ bop.type = Optype.BFD;
+ bop.add = true;
+ bop.ints[0] = detectMult;
+ bop.ints[1] = minRx;
+ bop.ints[2] = minTx;
+ bop.multiHop = multiHop;
+ LOG.debug("Adding BFD config {} {} {} {}", detectMult, minRx, minTx, multiHop);
+ dispatch(bop);
+ }
+
+ public synchronized void delBfd() throws TException, BgpRouterException {
+ bop.type = Optype.BFD;
+ bop.add = false;
+ LOG.debug("Deleting BFD Config ");
+ dispatch(bop);
+ }
+
public int initRibSync(BgpSyncHandle handle) throws BgpRouterException {
if (bgpClient == null) {
throw new BgpRouterException(BgpRouterException.BGP_ERR_NOT_INITED);
LOG.debug("EOR delay time in Seconds sent");
dispatch(bop);
}
+
+ public synchronized void getPeerStatus(String nbrIp, long nbrAsNum)
+ throws TException, BgpRouterException {
+ bop.type = Optype.PEER_STATUS;
+ bop.strs[0] = nbrIp;
+ bop.asNumber = nbrAsNum;
+ dispatch(bop);
+ } // public getPeerStatus( nbrIp, nbrAsNum )
+
}
import com.google.common.collect.ImmutableBiMap;
import com.google.common.collect.ImmutableMap;
import java.util.Map;
+import org.opendaylight.netvirt.bgpmanager.thrift.gen.peer_status_type;
import org.opendaylight.netvirt.bgpmanager.thrift.gen.qbgpConstants;
public class BgpRouterException extends Exception {
public static final int BGP_ERR_NOT_ITER = qbgpConstants.BGP_ERR_NOT_ITER;
public static final int BGP_ERR_PARAM = qbgpConstants.BGP_ERR_PARAM;
public static final int BGP_ERR_NOT_SUPPORTED = qbgpConstants.BGP_ERR_NOT_SUPPORTED;
+ public static final int BGP_ERR_PEER_EXISTS = qbgpConstants.BGP_ERR_PEER_EXISTS;
+ public static final int BGP_PEER_DOWN = peer_status_type.PEER_DOWN.getValue();
+ public static final int BGP_PEER_NOTCONFIGURED = peer_status_type.PEER_NOTCONFIGURED.getValue();
+ public static final int BGP_PEER_UNKNOWN = peer_status_type.PEER_UNKNOWN.getValue();
+
private static final Map<Integer, String> MESSAGES = ImmutableBiMap.<Integer, String>builder()
.put(BGP_ERR_INITED, "(" + BGP_ERR_INITED + ") Attempt to reinitialize BgpRouter thrift client")
--- /dev/null
+/**\r
+ * Autogenerated by Thrift Compiler (0.9.3)\r
+ *\r
+ * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING\r
+ * @generated\r
+ */\r
+\r
+package org.opendaylight.netvirt.bgpmanager.thrift.gen;\r
+\r
+import org.apache.thrift.scheme.IScheme;\r
+import org.apache.thrift.scheme.SchemeFactory;\r
+import org.apache.thrift.scheme.StandardScheme;\r
+\r
+import org.apache.thrift.scheme.TupleScheme;\r
+import org.apache.thrift.protocol.TTupleProtocol;\r
+import org.apache.thrift.protocol.TProtocolException;\r
+import org.apache.thrift.EncodingUtils;\r
+import org.apache.thrift.TException;\r
+import org.apache.thrift.async.AsyncMethodCallback;\r
+import org.apache.thrift.server.AbstractNonblockingServer.*;\r
+import java.util.List;\r
+import java.util.ArrayList;\r
+import java.util.Map;\r
+import java.util.HashMap;\r
+import java.util.EnumMap;\r
+import java.util.Set;\r
+import java.util.HashSet;\r
+import java.util.EnumSet;\r
+import java.util.Collections;\r
+import java.util.BitSet;\r
+import java.nio.ByteBuffer;\r
+import java.util.Arrays;\r
+import javax.annotation.Generated;\r
+import org.slf4j.Logger;\r
+import org.slf4j.LoggerFactory;\r
+\r
+\r
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"})\r
+@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)", date = "2018-04-09")\r
+public class BfdConfigData implements org.apache.thrift.TBase<BfdConfigData, BfdConfigData._Fields>, java.io.Serializable, Cloneable, Comparable<BfdConfigData> {\r
+ private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("BfdConfigData");\r
+\r
+ private static final org.apache.thrift.protocol.TField BFD_CONFIG_DATA_VERSION_FIELD_DESC = new org.apache.thrift.protocol.TField("bfdConfigDataVersion", org.apache.thrift.protocol.TType.BYTE, (short)1);\r
+ private static final org.apache.thrift.protocol.TField BFD_RX_INTERVAL_FIELD_DESC = new org.apache.thrift.protocol.TField("bfdRxInterval", org.apache.thrift.protocol.TType.I32, (short)2);\r
+ private static final org.apache.thrift.protocol.TField BFD_FAILURE_THRESHOLD_FIELD_DESC = new org.apache.thrift.protocol.TField("bfdFailureThreshold", org.apache.thrift.protocol.TType.BYTE, (short)3);\r
+ private static final org.apache.thrift.protocol.TField BFD_TX_INTERVAL_FIELD_DESC = new org.apache.thrift.protocol.TField("bfdTxInterval", org.apache.thrift.protocol.TType.I32, (short)4);\r
+ private static final org.apache.thrift.protocol.TField BFD_DEBOUNCE_DOWN_FIELD_DESC = new org.apache.thrift.protocol.TField("bfdDebounceDown", org.apache.thrift.protocol.TType.I32, (short)5);\r
+ private static final org.apache.thrift.protocol.TField BFD_DEBOUNCE_UP_FIELD_DESC = new org.apache.thrift.protocol.TField("bfdDebounceUp", org.apache.thrift.protocol.TType.I32, (short)6);\r
+ private static final org.apache.thrift.protocol.TField BFD_MULTIHOP_FIELD_DESC = new org.apache.thrift.protocol.TField("bfdMultihop", org.apache.thrift.protocol.TType.BOOL, (short)7);\r
+\r
+ private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();\r
+ static {\r
+ schemes.put(StandardScheme.class, new BfdConfigDataStandardSchemeFactory());\r
+ schemes.put(TupleScheme.class, new BfdConfigDataTupleSchemeFactory());\r
+ }\r
+\r
+ public byte bfdConfigDataVersion; // required\r
+ public int bfdRxInterval; // optional\r
+ public byte bfdFailureThreshold; // optional\r
+ public int bfdTxInterval; // optional\r
+ public int bfdDebounceDown; // optional\r
+ public int bfdDebounceUp; // optional\r
+ public boolean bfdMultihop; // optional\r
+\r
+ /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */\r
+ public enum _Fields implements org.apache.thrift.TFieldIdEnum {\r
+ BFD_CONFIG_DATA_VERSION((short)1, "bfdConfigDataVersion"),\r
+ BFD_RX_INTERVAL((short)2, "bfdRxInterval"),\r
+ BFD_FAILURE_THRESHOLD((short)3, "bfdFailureThreshold"),\r
+ BFD_TX_INTERVAL((short)4, "bfdTxInterval"),\r
+ BFD_DEBOUNCE_DOWN((short)5, "bfdDebounceDown"),\r
+ BFD_DEBOUNCE_UP((short)6, "bfdDebounceUp"),\r
+ BFD_MULTIHOP((short)7, "bfdMultihop");\r
+\r
+ private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();\r
+\r
+ static {\r
+ for (_Fields field : EnumSet.allOf(_Fields.class)) {\r
+ byName.put(field.getFieldName(), field);\r
+ }\r
+ }\r
+\r
+ /**\r
+ * Find the _Fields constant that matches fieldId, or null if its not found.\r
+ */\r
+ public static _Fields findByThriftId(int fieldId) {\r
+ switch(fieldId) {\r
+ case 1: // BFD_CONFIG_DATA_VERSION\r
+ return BFD_CONFIG_DATA_VERSION;\r
+ case 2: // BFD_RX_INTERVAL\r
+ return BFD_RX_INTERVAL;\r
+ case 3: // BFD_FAILURE_THRESHOLD\r
+ return BFD_FAILURE_THRESHOLD;\r
+ case 4: // BFD_TX_INTERVAL\r
+ return BFD_TX_INTERVAL;\r
+ case 5: // BFD_DEBOUNCE_DOWN\r
+ return BFD_DEBOUNCE_DOWN;\r
+ case 6: // BFD_DEBOUNCE_UP\r
+ return BFD_DEBOUNCE_UP;\r
+ case 7: // BFD_MULTIHOP\r
+ return BFD_MULTIHOP;\r
+ default:\r
+ return null;\r
+ }\r
+ }\r
+\r
+ /**\r
+ * Find the _Fields constant that matches fieldId, throwing an exception\r
+ * if it is not found.\r
+ */\r
+ public static _Fields findByThriftIdOrThrow(int fieldId) {\r
+ _Fields fields = findByThriftId(fieldId);\r
+ if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");\r
+ return fields;\r
+ }\r
+\r
+ /**\r
+ * Find the _Fields constant that matches name, or null if its not found.\r
+ */\r
+ public static _Fields findByName(String name) {\r
+ return byName.get(name);\r
+ }\r
+\r
+ private final short _thriftId;\r
+ private final String _fieldName;\r
+\r
+ _Fields(short thriftId, String fieldName) {\r
+ _thriftId = thriftId;\r
+ _fieldName = fieldName;\r
+ }\r
+\r
+ public short getThriftFieldId() {\r
+ return _thriftId;\r
+ }\r
+\r
+ public String getFieldName() {\r
+ return _fieldName;\r
+ }\r
+ }\r
+\r
+ // isset id assignments\r
+ private static final int __BFDCONFIGDATAVERSION_ISSET_ID = 0;\r
+ private static final int __BFDRXINTERVAL_ISSET_ID = 1;\r
+ private static final int __BFDFAILURETHRESHOLD_ISSET_ID = 2;\r
+ private static final int __BFDTXINTERVAL_ISSET_ID = 3;\r
+ private static final int __BFDDEBOUNCEDOWN_ISSET_ID = 4;\r
+ private static final int __BFDDEBOUNCEUP_ISSET_ID = 5;\r
+ private static final int __BFDMULTIHOP_ISSET_ID = 6;\r
+ private byte __isset_bitfield = 0;\r
+ private static final _Fields optionals[] = {_Fields.BFD_RX_INTERVAL,_Fields.BFD_FAILURE_THRESHOLD,_Fields.BFD_TX_INTERVAL,_Fields.BFD_DEBOUNCE_DOWN,_Fields.BFD_DEBOUNCE_UP,_Fields.BFD_MULTIHOP};\r
+ public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;\r
+ static {\r
+ Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);\r
+ tmpMap.put(_Fields.BFD_CONFIG_DATA_VERSION, new org.apache.thrift.meta_data.FieldMetaData("bfdConfigDataVersion", org.apache.thrift.TFieldRequirementType.DEFAULT,\r
+ new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.BYTE)));\r
+ tmpMap.put(_Fields.BFD_RX_INTERVAL, new org.apache.thrift.meta_data.FieldMetaData("bfdRxInterval", org.apache.thrift.TFieldRequirementType.OPTIONAL,\r
+ new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I32)));\r
+ tmpMap.put(_Fields.BFD_FAILURE_THRESHOLD, new org.apache.thrift.meta_data.FieldMetaData("bfdFailureThreshold", org.apache.thrift.TFieldRequirementType.OPTIONAL,\r
+ new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.BYTE)));\r
+ tmpMap.put(_Fields.BFD_TX_INTERVAL, new org.apache.thrift.meta_data.FieldMetaData("bfdTxInterval", org.apache.thrift.TFieldRequirementType.OPTIONAL,\r
+ new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I32)));\r
+ tmpMap.put(_Fields.BFD_DEBOUNCE_DOWN, new org.apache.thrift.meta_data.FieldMetaData("bfdDebounceDown", org.apache.thrift.TFieldRequirementType.OPTIONAL,\r
+ new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I32)));\r
+ tmpMap.put(_Fields.BFD_DEBOUNCE_UP, new org.apache.thrift.meta_data.FieldMetaData("bfdDebounceUp", org.apache.thrift.TFieldRequirementType.OPTIONAL,\r
+ new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I32)));\r
+ tmpMap.put(_Fields.BFD_MULTIHOP, new org.apache.thrift.meta_data.FieldMetaData("bfdMultihop", org.apache.thrift.TFieldRequirementType.OPTIONAL,\r
+ new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.BOOL)));\r
+ metaDataMap = Collections.unmodifiableMap(tmpMap);\r
+ org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(BfdConfigData.class, metaDataMap);\r
+ }\r
+\r
+ public BfdConfigData() {\r
+ }\r
+\r
+ public BfdConfigData(\r
+ byte bfdConfigDataVersion)\r
+ {\r
+ this();\r
+ this.bfdConfigDataVersion = bfdConfigDataVersion;\r
+ setBfdConfigDataVersionIsSet(true);\r
+ }\r
+\r
+ /**\r
+ * Performs a deep copy on <i>other</i>.\r
+ */\r
+ public BfdConfigData(BfdConfigData other) {\r
+ __isset_bitfield = other.__isset_bitfield;\r
+ this.bfdConfigDataVersion = other.bfdConfigDataVersion;\r
+ this.bfdRxInterval = other.bfdRxInterval;\r
+ this.bfdFailureThreshold = other.bfdFailureThreshold;\r
+ this.bfdTxInterval = other.bfdTxInterval;\r
+ this.bfdDebounceDown = other.bfdDebounceDown;\r
+ this.bfdDebounceUp = other.bfdDebounceUp;\r
+ this.bfdMultihop = other.bfdMultihop;\r
+ }\r
+\r
+ public BfdConfigData deepCopy() {\r
+ return new BfdConfigData(this);\r
+ }\r
+\r
+ @Override\r
+ public void clear() {\r
+ setBfdConfigDataVersionIsSet(false);\r
+ this.bfdConfigDataVersion = 0;\r
+ setBfdRxIntervalIsSet(false);\r
+ this.bfdRxInterval = 0;\r
+ setBfdFailureThresholdIsSet(false);\r
+ this.bfdFailureThreshold = 0;\r
+ setBfdTxIntervalIsSet(false);\r
+ this.bfdTxInterval = 0;\r
+ setBfdDebounceDownIsSet(false);\r
+ this.bfdDebounceDown = 0;\r
+ setBfdDebounceUpIsSet(false);\r
+ this.bfdDebounceUp = 0;\r
+ setBfdMultihopIsSet(false);\r
+ this.bfdMultihop = false;\r
+ }\r
+\r
+ public byte getBfdConfigDataVersion() {\r
+ return this.bfdConfigDataVersion;\r
+ }\r
+\r
+ public BfdConfigData setBfdConfigDataVersion(byte bfdConfigDataVersion) {\r
+ this.bfdConfigDataVersion = bfdConfigDataVersion;\r
+ setBfdConfigDataVersionIsSet(true);\r
+ return this;\r
+ }\r
+\r
+ public void unsetBfdConfigDataVersion() {\r
+ __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __BFDCONFIGDATAVERSION_ISSET_ID);\r
+ }\r
+\r
+ /** Returns true if field bfdConfigDataVersion is set (has been assigned a value) and false otherwise */\r
+ public boolean isSetBfdConfigDataVersion() {\r
+ return EncodingUtils.testBit(__isset_bitfield, __BFDCONFIGDATAVERSION_ISSET_ID);\r
+ }\r
+\r
+ public void setBfdConfigDataVersionIsSet(boolean value) {\r
+ __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __BFDCONFIGDATAVERSION_ISSET_ID, value);\r
+ }\r
+\r
+ public int getBfdRxInterval() {\r
+ return this.bfdRxInterval;\r
+ }\r
+\r
+ public BfdConfigData setBfdRxInterval(int bfdRxInterval) {\r
+ this.bfdRxInterval = bfdRxInterval;\r
+ setBfdRxIntervalIsSet(true);\r
+ return this;\r
+ }\r
+\r
+ public void unsetBfdRxInterval() {\r
+ __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __BFDRXINTERVAL_ISSET_ID);\r
+ }\r
+\r
+ /** Returns true if field bfdRxInterval is set (has been assigned a value) and false otherwise */\r
+ public boolean isSetBfdRxInterval() {\r
+ return EncodingUtils.testBit(__isset_bitfield, __BFDRXINTERVAL_ISSET_ID);\r
+ }\r
+\r
+ public void setBfdRxIntervalIsSet(boolean value) {\r
+ __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __BFDRXINTERVAL_ISSET_ID, value);\r
+ }\r
+\r
+ public byte getBfdFailureThreshold() {\r
+ return this.bfdFailureThreshold;\r
+ }\r
+\r
+ public BfdConfigData setBfdFailureThreshold(byte bfdFailureThreshold) {\r
+ this.bfdFailureThreshold = bfdFailureThreshold;\r
+ setBfdFailureThresholdIsSet(true);\r
+ return this;\r
+ }\r
+\r
+ public void unsetBfdFailureThreshold() {\r
+ __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __BFDFAILURETHRESHOLD_ISSET_ID);\r
+ }\r
+\r
+ /** Returns true if field bfdFailureThreshold is set (has been assigned a value) and false otherwise */\r
+ public boolean isSetBfdFailureThreshold() {\r
+ return EncodingUtils.testBit(__isset_bitfield, __BFDFAILURETHRESHOLD_ISSET_ID);\r
+ }\r
+\r
+ public void setBfdFailureThresholdIsSet(boolean value) {\r
+ __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __BFDFAILURETHRESHOLD_ISSET_ID, value);\r
+ }\r
+\r
+ public int getBfdTxInterval() {\r
+ return this.bfdTxInterval;\r
+ }\r
+\r
+ public BfdConfigData setBfdTxInterval(int bfdTxInterval) {\r
+ this.bfdTxInterval = bfdTxInterval;\r
+ setBfdTxIntervalIsSet(true);\r
+ return this;\r
+ }\r
+\r
+ public void unsetBfdTxInterval() {\r
+ __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __BFDTXINTERVAL_ISSET_ID);\r
+ }\r
+\r
+ /** Returns true if field bfdTxInterval is set (has been assigned a value) and false otherwise */\r
+ public boolean isSetBfdTxInterval() {\r
+ return EncodingUtils.testBit(__isset_bitfield, __BFDTXINTERVAL_ISSET_ID);\r
+ }\r
+\r
+ public void setBfdTxIntervalIsSet(boolean value) {\r
+ __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __BFDTXINTERVAL_ISSET_ID, value);\r
+ }\r
+\r
+ public int getBfdDebounceDown() {\r
+ return this.bfdDebounceDown;\r
+ }\r
+\r
+ public BfdConfigData setBfdDebounceDown(int bfdDebounceDown) {\r
+ this.bfdDebounceDown = bfdDebounceDown;\r
+ setBfdDebounceDownIsSet(true);\r
+ return this;\r
+ }\r
+\r
+ public void unsetBfdDebounceDown() {\r
+ __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __BFDDEBOUNCEDOWN_ISSET_ID);\r
+ }\r
+\r
+ /** Returns true if field bfdDebounceDown is set (has been assigned a value) and false otherwise */\r
+ public boolean isSetBfdDebounceDown() {\r
+ return EncodingUtils.testBit(__isset_bitfield, __BFDDEBOUNCEDOWN_ISSET_ID);\r
+ }\r
+\r
+ public void setBfdDebounceDownIsSet(boolean value) {\r
+ __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __BFDDEBOUNCEDOWN_ISSET_ID, value);\r
+ }\r
+\r
+ public int getBfdDebounceUp() {\r
+ return this.bfdDebounceUp;\r
+ }\r
+\r
+ public BfdConfigData setBfdDebounceUp(int bfdDebounceUp) {\r
+ this.bfdDebounceUp = bfdDebounceUp;\r
+ setBfdDebounceUpIsSet(true);\r
+ return this;\r
+ }\r
+\r
+ public void unsetBfdDebounceUp() {\r
+ __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __BFDDEBOUNCEUP_ISSET_ID);\r
+ }\r
+\r
+ /** Returns true if field bfdDebounceUp is set (has been assigned a value) and false otherwise */\r
+ public boolean isSetBfdDebounceUp() {\r
+ return EncodingUtils.testBit(__isset_bitfield, __BFDDEBOUNCEUP_ISSET_ID);\r
+ }\r
+\r
+ public void setBfdDebounceUpIsSet(boolean value) {\r
+ __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __BFDDEBOUNCEUP_ISSET_ID, value);\r
+ }\r
+\r
+ public boolean isBfdMultihop() {\r
+ return this.bfdMultihop;\r
+ }\r
+\r
+ public BfdConfigData setBfdMultihop(boolean bfdMultihop) {\r
+ this.bfdMultihop = bfdMultihop;\r
+ setBfdMultihopIsSet(true);\r
+ return this;\r
+ }\r
+\r
+ public void unsetBfdMultihop() {\r
+ __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __BFDMULTIHOP_ISSET_ID);\r
+ }\r
+\r
+ /** Returns true if field bfdMultihop is set (has been assigned a value) and false otherwise */\r
+ public boolean isSetBfdMultihop() {\r
+ return EncodingUtils.testBit(__isset_bitfield, __BFDMULTIHOP_ISSET_ID);\r
+ }\r
+\r
+ public void setBfdMultihopIsSet(boolean value) {\r
+ __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __BFDMULTIHOP_ISSET_ID, value);\r
+ }\r
+\r
+ public void setFieldValue(_Fields field, Object value) {\r
+ switch (field) {\r
+ case BFD_CONFIG_DATA_VERSION:\r
+ if (value == null) {\r
+ unsetBfdConfigDataVersion();\r
+ } else {\r
+ setBfdConfigDataVersion((Byte)value);\r
+ }\r
+ break;\r
+\r
+ case BFD_RX_INTERVAL:\r
+ if (value == null) {\r
+ unsetBfdRxInterval();\r
+ } else {\r
+ setBfdRxInterval((Integer)value);\r
+ }\r
+ break;\r
+\r
+ case BFD_FAILURE_THRESHOLD:\r
+ if (value == null) {\r
+ unsetBfdFailureThreshold();\r
+ } else {\r
+ setBfdFailureThreshold((Byte)value);\r
+ }\r
+ break;\r
+\r
+ case BFD_TX_INTERVAL:\r
+ if (value == null) {\r
+ unsetBfdTxInterval();\r
+ } else {\r
+ setBfdTxInterval((Integer)value);\r
+ }\r
+ break;\r
+\r
+ case BFD_DEBOUNCE_DOWN:\r
+ if (value == null) {\r
+ unsetBfdDebounceDown();\r
+ } else {\r
+ setBfdDebounceDown((Integer)value);\r
+ }\r
+ break;\r
+\r
+ case BFD_DEBOUNCE_UP:\r
+ if (value == null) {\r
+ unsetBfdDebounceUp();\r
+ } else {\r
+ setBfdDebounceUp((Integer)value);\r
+ }\r
+ break;\r
+\r
+ case BFD_MULTIHOP:\r
+ if (value == null) {\r
+ unsetBfdMultihop();\r
+ } else {\r
+ setBfdMultihop((Boolean)value);\r
+ }\r
+ break;\r
+\r
+ }\r
+ }\r
+\r
+ public Object getFieldValue(_Fields field) {\r
+ switch (field) {\r
+ case BFD_CONFIG_DATA_VERSION:\r
+ return getBfdConfigDataVersion();\r
+\r
+ case BFD_RX_INTERVAL:\r
+ return getBfdRxInterval();\r
+\r
+ case BFD_FAILURE_THRESHOLD:\r
+ return getBfdFailureThreshold();\r
+\r
+ case BFD_TX_INTERVAL:\r
+ return getBfdTxInterval();\r
+\r
+ case BFD_DEBOUNCE_DOWN:\r
+ return getBfdDebounceDown();\r
+\r
+ case BFD_DEBOUNCE_UP:\r
+ return getBfdDebounceUp();\r
+\r
+ case BFD_MULTIHOP:\r
+ return isBfdMultihop();\r
+\r
+ }\r
+ throw new IllegalStateException();\r
+ }\r
+\r
+ /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */\r
+ public boolean isSet(_Fields field) {\r
+ if (field == null) {\r
+ throw new IllegalArgumentException();\r
+ }\r
+\r
+ switch (field) {\r
+ case BFD_CONFIG_DATA_VERSION:\r
+ return isSetBfdConfigDataVersion();\r
+ case BFD_RX_INTERVAL:\r
+ return isSetBfdRxInterval();\r
+ case BFD_FAILURE_THRESHOLD:\r
+ return isSetBfdFailureThreshold();\r
+ case BFD_TX_INTERVAL:\r
+ return isSetBfdTxInterval();\r
+ case BFD_DEBOUNCE_DOWN:\r
+ return isSetBfdDebounceDown();\r
+ case BFD_DEBOUNCE_UP:\r
+ return isSetBfdDebounceUp();\r
+ case BFD_MULTIHOP:\r
+ return isSetBfdMultihop();\r
+ }\r
+ throw new IllegalStateException();\r
+ }\r
+\r
+ @Override\r
+ public boolean equals(Object that) {\r
+ if (that == null)\r
+ return false;\r
+ if (that instanceof BfdConfigData)\r
+ return this.equals((BfdConfigData)that);\r
+ return false;\r
+ }\r
+\r
+ public boolean equals(BfdConfigData that) {\r
+ if (that == null)\r
+ return false;\r
+\r
+ boolean this_present_bfdConfigDataVersion = true;\r
+ boolean that_present_bfdConfigDataVersion = true;\r
+ if (this_present_bfdConfigDataVersion || that_present_bfdConfigDataVersion) {\r
+ if (!(this_present_bfdConfigDataVersion && that_present_bfdConfigDataVersion))\r
+ return false;\r
+ if (this.bfdConfigDataVersion != that.bfdConfigDataVersion)\r
+ return false;\r
+ }\r
+\r
+ boolean this_present_bfdRxInterval = true && this.isSetBfdRxInterval();\r
+ boolean that_present_bfdRxInterval = true && that.isSetBfdRxInterval();\r
+ if (this_present_bfdRxInterval || that_present_bfdRxInterval) {\r
+ if (!(this_present_bfdRxInterval && that_present_bfdRxInterval))\r
+ return false;\r
+ if (this.bfdRxInterval != that.bfdRxInterval)\r
+ return false;\r
+ }\r
+\r
+ boolean this_present_bfdFailureThreshold = true && this.isSetBfdFailureThreshold();\r
+ boolean that_present_bfdFailureThreshold = true && that.isSetBfdFailureThreshold();\r
+ if (this_present_bfdFailureThreshold || that_present_bfdFailureThreshold) {\r
+ if (!(this_present_bfdFailureThreshold && that_present_bfdFailureThreshold))\r
+ return false;\r
+ if (this.bfdFailureThreshold != that.bfdFailureThreshold)\r
+ return false;\r
+ }\r
+\r
+ boolean this_present_bfdTxInterval = true && this.isSetBfdTxInterval();\r
+ boolean that_present_bfdTxInterval = true && that.isSetBfdTxInterval();\r
+ if (this_present_bfdTxInterval || that_present_bfdTxInterval) {\r
+ if (!(this_present_bfdTxInterval && that_present_bfdTxInterval))\r
+ return false;\r
+ if (this.bfdTxInterval != that.bfdTxInterval)\r
+ return false;\r
+ }\r
+\r
+ boolean this_present_bfdDebounceDown = true && this.isSetBfdDebounceDown();\r
+ boolean that_present_bfdDebounceDown = true && that.isSetBfdDebounceDown();\r
+ if (this_present_bfdDebounceDown || that_present_bfdDebounceDown) {\r
+ if (!(this_present_bfdDebounceDown && that_present_bfdDebounceDown))\r
+ return false;\r
+ if (this.bfdDebounceDown != that.bfdDebounceDown)\r
+ return false;\r
+ }\r
+\r
+ boolean this_present_bfdDebounceUp = true && this.isSetBfdDebounceUp();\r
+ boolean that_present_bfdDebounceUp = true && that.isSetBfdDebounceUp();\r
+ if (this_present_bfdDebounceUp || that_present_bfdDebounceUp) {\r
+ if (!(this_present_bfdDebounceUp && that_present_bfdDebounceUp))\r
+ return false;\r
+ if (this.bfdDebounceUp != that.bfdDebounceUp)\r
+ return false;\r
+ }\r
+\r
+ boolean this_present_bfdMultihop = true && this.isSetBfdMultihop();\r
+ boolean that_present_bfdMultihop = true && that.isSetBfdMultihop();\r
+ if (this_present_bfdMultihop || that_present_bfdMultihop) {\r
+ if (!(this_present_bfdMultihop && that_present_bfdMultihop))\r
+ return false;\r
+ if (this.bfdMultihop != that.bfdMultihop)\r
+ return false;\r
+ }\r
+\r
+ return true;\r
+ }\r
+\r
+ @Override\r
+ public int hashCode() {\r
+ List<Object> list = new ArrayList<Object>();\r
+\r
+ boolean present_bfdConfigDataVersion = true;\r
+ list.add(present_bfdConfigDataVersion);\r
+ if (present_bfdConfigDataVersion)\r
+ list.add(bfdConfigDataVersion);\r
+\r
+ boolean present_bfdRxInterval = true && (isSetBfdRxInterval());\r
+ list.add(present_bfdRxInterval);\r
+ if (present_bfdRxInterval)\r
+ list.add(bfdRxInterval);\r
+\r
+ boolean present_bfdFailureThreshold = true && (isSetBfdFailureThreshold());\r
+ list.add(present_bfdFailureThreshold);\r
+ if (present_bfdFailureThreshold)\r
+ list.add(bfdFailureThreshold);\r
+\r
+ boolean present_bfdTxInterval = true && (isSetBfdTxInterval());\r
+ list.add(present_bfdTxInterval);\r
+ if (present_bfdTxInterval)\r
+ list.add(bfdTxInterval);\r
+\r
+ boolean present_bfdDebounceDown = true && (isSetBfdDebounceDown());\r
+ list.add(present_bfdDebounceDown);\r
+ if (present_bfdDebounceDown)\r
+ list.add(bfdDebounceDown);\r
+\r
+ boolean present_bfdDebounceUp = true && (isSetBfdDebounceUp());\r
+ list.add(present_bfdDebounceUp);\r
+ if (present_bfdDebounceUp)\r
+ list.add(bfdDebounceUp);\r
+\r
+ boolean present_bfdMultihop = true && (isSetBfdMultihop());\r
+ list.add(present_bfdMultihop);\r
+ if (present_bfdMultihop)\r
+ list.add(bfdMultihop);\r
+\r
+ return list.hashCode();\r
+ }\r
+\r
+ @Override\r
+ public int compareTo(BfdConfigData other) {\r
+ if (!getClass().equals(other.getClass())) {\r
+ return getClass().getName().compareTo(other.getClass().getName());\r
+ }\r
+\r
+ int lastComparison = 0;\r
+\r
+ lastComparison = Boolean.valueOf(isSetBfdConfigDataVersion()).compareTo(other.isSetBfdConfigDataVersion());\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ if (isSetBfdConfigDataVersion()) {\r
+ lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.bfdConfigDataVersion, other.bfdConfigDataVersion);\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ }\r
+ lastComparison = Boolean.valueOf(isSetBfdRxInterval()).compareTo(other.isSetBfdRxInterval());\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ if (isSetBfdRxInterval()) {\r
+ lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.bfdRxInterval, other.bfdRxInterval);\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ }\r
+ lastComparison = Boolean.valueOf(isSetBfdFailureThreshold()).compareTo(other.isSetBfdFailureThreshold());\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ if (isSetBfdFailureThreshold()) {\r
+ lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.bfdFailureThreshold, other.bfdFailureThreshold);\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ }\r
+ lastComparison = Boolean.valueOf(isSetBfdTxInterval()).compareTo(other.isSetBfdTxInterval());\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ if (isSetBfdTxInterval()) {\r
+ lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.bfdTxInterval, other.bfdTxInterval);\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ }\r
+ lastComparison = Boolean.valueOf(isSetBfdDebounceDown()).compareTo(other.isSetBfdDebounceDown());\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ if (isSetBfdDebounceDown()) {\r
+ lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.bfdDebounceDown, other.bfdDebounceDown);\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ }\r
+ lastComparison = Boolean.valueOf(isSetBfdDebounceUp()).compareTo(other.isSetBfdDebounceUp());\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ if (isSetBfdDebounceUp()) {\r
+ lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.bfdDebounceUp, other.bfdDebounceUp);\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ }\r
+ lastComparison = Boolean.valueOf(isSetBfdMultihop()).compareTo(other.isSetBfdMultihop());\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ if (isSetBfdMultihop()) {\r
+ lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.bfdMultihop, other.bfdMultihop);\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ }\r
+ return 0;\r
+ }\r
+\r
+ public _Fields fieldForId(int fieldId) {\r
+ return _Fields.findByThriftId(fieldId);\r
+ }\r
+\r
+ public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {\r
+ schemes.get(iprot.getScheme()).getScheme().read(iprot, this);\r
+ }\r
+\r
+ public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {\r
+ schemes.get(oprot.getScheme()).getScheme().write(oprot, this);\r
+ }\r
+\r
+ @Override\r
+ public String toString() {\r
+ StringBuilder sb = new StringBuilder("BfdConfigData(");\r
+ boolean first = true;\r
+\r
+ sb.append("bfdConfigDataVersion:");\r
+ sb.append(this.bfdConfigDataVersion);\r
+ first = false;\r
+ if (isSetBfdRxInterval()) {\r
+ if (!first) sb.append(", ");\r
+ sb.append("bfdRxInterval:");\r
+ sb.append(this.bfdRxInterval);\r
+ first = false;\r
+ }\r
+ if (isSetBfdFailureThreshold()) {\r
+ if (!first) sb.append(", ");\r
+ sb.append("bfdFailureThreshold:");\r
+ sb.append(this.bfdFailureThreshold);\r
+ first = false;\r
+ }\r
+ if (isSetBfdTxInterval()) {\r
+ if (!first) sb.append(", ");\r
+ sb.append("bfdTxInterval:");\r
+ sb.append(this.bfdTxInterval);\r
+ first = false;\r
+ }\r
+ if (isSetBfdDebounceDown()) {\r
+ if (!first) sb.append(", ");\r
+ sb.append("bfdDebounceDown:");\r
+ sb.append(this.bfdDebounceDown);\r
+ first = false;\r
+ }\r
+ if (isSetBfdDebounceUp()) {\r
+ if (!first) sb.append(", ");\r
+ sb.append("bfdDebounceUp:");\r
+ sb.append(this.bfdDebounceUp);\r
+ first = false;\r
+ }\r
+ if (isSetBfdMultihop()) {\r
+ if (!first) sb.append(", ");\r
+ sb.append("bfdMultihop:");\r
+ sb.append(this.bfdMultihop);\r
+ first = false;\r
+ }\r
+ sb.append(")");\r
+ return sb.toString();\r
+ }\r
+\r
+ public void validate() throws org.apache.thrift.TException {\r
+ // check for required fields\r
+ // check for sub-struct validity\r
+ }\r
+\r
+ private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {\r
+ try {\r
+ write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));\r
+ } catch (org.apache.thrift.TException te) {\r
+ throw new java.io.IOException(te);\r
+ }\r
+ }\r
+\r
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {\r
+ try {\r
+ // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.\r
+ __isset_bitfield = 0;\r
+ read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));\r
+ } catch (org.apache.thrift.TException te) {\r
+ throw new java.io.IOException(te);\r
+ }\r
+ }\r
+\r
+ private static class BfdConfigDataStandardSchemeFactory implements SchemeFactory {\r
+ public BfdConfigDataStandardScheme getScheme() {\r
+ return new BfdConfigDataStandardScheme();\r
+ }\r
+ }\r
+\r
+ private static class BfdConfigDataStandardScheme extends StandardScheme<BfdConfigData> {\r
+\r
+ public void read(org.apache.thrift.protocol.TProtocol iprot, BfdConfigData struct) throws org.apache.thrift.TException {\r
+ org.apache.thrift.protocol.TField schemeField;\r
+ iprot.readStructBegin();\r
+ while (true)\r
+ {\r
+ schemeField = iprot.readFieldBegin();\r
+ if (schemeField.type == org.apache.thrift.protocol.TType.STOP) {\r
+ break;\r
+ }\r
+ switch (schemeField.id) {\r
+ case 1: // BFD_CONFIG_DATA_VERSION\r
+ if (schemeField.type == org.apache.thrift.protocol.TType.BYTE) {\r
+ struct.bfdConfigDataVersion = iprot.readByte();\r
+ struct.setBfdConfigDataVersionIsSet(true);\r
+ } else {\r
+ org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);\r
+ }\r
+ break;\r
+ case 2: // BFD_RX_INTERVAL\r
+ if (schemeField.type == org.apache.thrift.protocol.TType.I32) {\r
+ struct.bfdRxInterval = iprot.readI32();\r
+ struct.setBfdRxIntervalIsSet(true);\r
+ } else {\r
+ org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);\r
+ }\r
+ break;\r
+ case 3: // BFD_FAILURE_THRESHOLD\r
+ if (schemeField.type == org.apache.thrift.protocol.TType.BYTE) {\r
+ struct.bfdFailureThreshold = iprot.readByte();\r
+ struct.setBfdFailureThresholdIsSet(true);\r
+ } else {\r
+ org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);\r
+ }\r
+ break;\r
+ case 4: // BFD_TX_INTERVAL\r
+ if (schemeField.type == org.apache.thrift.protocol.TType.I32) {\r
+ struct.bfdTxInterval = iprot.readI32();\r
+ struct.setBfdTxIntervalIsSet(true);\r
+ } else {\r
+ org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);\r
+ }\r
+ break;\r
+ case 5: // BFD_DEBOUNCE_DOWN\r
+ if (schemeField.type == org.apache.thrift.protocol.TType.I32) {\r
+ struct.bfdDebounceDown = iprot.readI32();\r
+ struct.setBfdDebounceDownIsSet(true);\r
+ } else {\r
+ org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);\r
+ }\r
+ break;\r
+ case 6: // BFD_DEBOUNCE_UP\r
+ if (schemeField.type == org.apache.thrift.protocol.TType.I32) {\r
+ struct.bfdDebounceUp = iprot.readI32();\r
+ struct.setBfdDebounceUpIsSet(true);\r
+ } else {\r
+ org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);\r
+ }\r
+ break;\r
+ case 7: // BFD_MULTIHOP\r
+ if (schemeField.type == org.apache.thrift.protocol.TType.BOOL) {\r
+ struct.bfdMultihop = iprot.readBool();\r
+ struct.setBfdMultihopIsSet(true);\r
+ } else {\r
+ org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);\r
+ }\r
+ break;\r
+ default:\r
+ org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);\r
+ }\r
+ iprot.readFieldEnd();\r
+ }\r
+ iprot.readStructEnd();\r
+\r
+ // check for required fields of primitive type, which can't be checked in the validate method\r
+ struct.validate();\r
+ }\r
+\r
+ public void write(org.apache.thrift.protocol.TProtocol oprot, BfdConfigData struct) throws org.apache.thrift.TException {\r
+ struct.validate();\r
+\r
+ oprot.writeStructBegin(STRUCT_DESC);\r
+ oprot.writeFieldBegin(BFD_CONFIG_DATA_VERSION_FIELD_DESC);\r
+ oprot.writeByte(struct.bfdConfigDataVersion);\r
+ oprot.writeFieldEnd();\r
+ if (struct.isSetBfdRxInterval()) {\r
+ oprot.writeFieldBegin(BFD_RX_INTERVAL_FIELD_DESC);\r
+ oprot.writeI32(struct.bfdRxInterval);\r
+ oprot.writeFieldEnd();\r
+ }\r
+ if (struct.isSetBfdFailureThreshold()) {\r
+ oprot.writeFieldBegin(BFD_FAILURE_THRESHOLD_FIELD_DESC);\r
+ oprot.writeByte(struct.bfdFailureThreshold);\r
+ oprot.writeFieldEnd();\r
+ }\r
+ if (struct.isSetBfdTxInterval()) {\r
+ oprot.writeFieldBegin(BFD_TX_INTERVAL_FIELD_DESC);\r
+ oprot.writeI32(struct.bfdTxInterval);\r
+ oprot.writeFieldEnd();\r
+ }\r
+ if (struct.isSetBfdDebounceDown()) {\r
+ oprot.writeFieldBegin(BFD_DEBOUNCE_DOWN_FIELD_DESC);\r
+ oprot.writeI32(struct.bfdDebounceDown);\r
+ oprot.writeFieldEnd();\r
+ }\r
+ if (struct.isSetBfdDebounceUp()) {\r
+ oprot.writeFieldBegin(BFD_DEBOUNCE_UP_FIELD_DESC);\r
+ oprot.writeI32(struct.bfdDebounceUp);\r
+ oprot.writeFieldEnd();\r
+ }\r
+ if (struct.isSetBfdMultihop()) {\r
+ oprot.writeFieldBegin(BFD_MULTIHOP_FIELD_DESC);\r
+ oprot.writeBool(struct.bfdMultihop);\r
+ oprot.writeFieldEnd();\r
+ }\r
+ oprot.writeFieldStop();\r
+ oprot.writeStructEnd();\r
+ }\r
+\r
+ }\r
+\r
+ private static class BfdConfigDataTupleSchemeFactory implements SchemeFactory {\r
+ public BfdConfigDataTupleScheme getScheme() {\r
+ return new BfdConfigDataTupleScheme();\r
+ }\r
+ }\r
+\r
+ private static class BfdConfigDataTupleScheme extends TupleScheme<BfdConfigData> {\r
+\r
+ @Override\r
+ public void write(org.apache.thrift.protocol.TProtocol prot, BfdConfigData struct) throws org.apache.thrift.TException {\r
+ TTupleProtocol oprot = (TTupleProtocol) prot;\r
+ BitSet optionals = new BitSet();\r
+ if (struct.isSetBfdConfigDataVersion()) {\r
+ optionals.set(0);\r
+ }\r
+ if (struct.isSetBfdRxInterval()) {\r
+ optionals.set(1);\r
+ }\r
+ if (struct.isSetBfdFailureThreshold()) {\r
+ optionals.set(2);\r
+ }\r
+ if (struct.isSetBfdTxInterval()) {\r
+ optionals.set(3);\r
+ }\r
+ if (struct.isSetBfdDebounceDown()) {\r
+ optionals.set(4);\r
+ }\r
+ if (struct.isSetBfdDebounceUp()) {\r
+ optionals.set(5);\r
+ }\r
+ if (struct.isSetBfdMultihop()) {\r
+ optionals.set(6);\r
+ }\r
+ oprot.writeBitSet(optionals, 7);\r
+ if (struct.isSetBfdConfigDataVersion()) {\r
+ oprot.writeByte(struct.bfdConfigDataVersion);\r
+ }\r
+ if (struct.isSetBfdRxInterval()) {\r
+ oprot.writeI32(struct.bfdRxInterval);\r
+ }\r
+ if (struct.isSetBfdFailureThreshold()) {\r
+ oprot.writeByte(struct.bfdFailureThreshold);\r
+ }\r
+ if (struct.isSetBfdTxInterval()) {\r
+ oprot.writeI32(struct.bfdTxInterval);\r
+ }\r
+ if (struct.isSetBfdDebounceDown()) {\r
+ oprot.writeI32(struct.bfdDebounceDown);\r
+ }\r
+ if (struct.isSetBfdDebounceUp()) {\r
+ oprot.writeI32(struct.bfdDebounceUp);\r
+ }\r
+ if (struct.isSetBfdMultihop()) {\r
+ oprot.writeBool(struct.bfdMultihop);\r
+ }\r
+ }\r
+\r
+ @Override\r
+ public void read(org.apache.thrift.protocol.TProtocol prot, BfdConfigData struct) throws org.apache.thrift.TException {\r
+ TTupleProtocol iprot = (TTupleProtocol) prot;\r
+ BitSet incoming = iprot.readBitSet(7);\r
+ if (incoming.get(0)) {\r
+ struct.bfdConfigDataVersion = iprot.readByte();\r
+ struct.setBfdConfigDataVersionIsSet(true);\r
+ }\r
+ if (incoming.get(1)) {\r
+ struct.bfdRxInterval = iprot.readI32();\r
+ struct.setBfdRxIntervalIsSet(true);\r
+ }\r
+ if (incoming.get(2)) {\r
+ struct.bfdFailureThreshold = iprot.readByte();\r
+ struct.setBfdFailureThresholdIsSet(true);\r
+ }\r
+ if (incoming.get(3)) {\r
+ struct.bfdTxInterval = iprot.readI32();\r
+ struct.setBfdTxIntervalIsSet(true);\r
+ }\r
+ if (incoming.get(4)) {\r
+ struct.bfdDebounceDown = iprot.readI32();\r
+ struct.setBfdDebounceDownIsSet(true);\r
+ }\r
+ if (incoming.get(5)) {\r
+ struct.bfdDebounceUp = iprot.readI32();\r
+ struct.setBfdDebounceUpIsSet(true);\r
+ }\r
+ if (incoming.get(6)) {\r
+ struct.bfdMultihop = iprot.readBool();\r
+ struct.setBfdMultihopIsSet(true);\r
+ }\r
+ }\r
+ }\r
+\r
+}\r
+\r
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
- package org.opendaylight.netvirt.bgpmanager.thrift.gen;
+
+package org.opendaylight.netvirt.bgpmanager.thrift.gen;
+
import org.apache.thrift.scheme.IScheme;
import org.apache.thrift.scheme.SchemeFactory;
import org.apache.thrift.scheme.StandardScheme;
import org.slf4j.LoggerFactory;
@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"})
-@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)", date = "2017-09-13")
+@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)", date = "2018-06-18")
public class BgpConfigurator {
public interface Iface {
- public int startBgp(long asNumber, String routerId, int port, int holdTime, int keepAliveTime, int stalepathTime, boolean announceFlush) throws org.apache.thrift.TException;
+ public int startBgp(long asNumber, String routerId, int port, int holdTime, int keepAliveTime, int stalepathTime, boolean announceFbit) throws org.apache.thrift.TException;
public int stopBgp(long asNumber) throws org.apache.thrift.TException;
public int delVrf(String rd, af_afi afi, af_safi safi) throws org.apache.thrift.TException;
- public int pushRoute(protocol_type p_type, String prefix, String nexthop, String rd, int ethtag, String esi, String macaddress, int l3label, int l2label, encap_type enc_type, String routermac, af_afi afi) throws org.apache.thrift.TException;
+ public int pushRoute(protocol_type p_type, String prefix, String nexthop, String rd, long ethtag, String esi, String macaddress, int l3label, int l2label, encap_type enc_type, String routermac, af_afi afi) throws org.apache.thrift.TException;
- public int withdrawRoute(protocol_type p_type, String prefix, String rd, int ethtag, String esi, String macaddress, af_afi afi) throws org.apache.thrift.TException;
+ public int withdrawRoute(protocol_type p_type, String prefix, String rd, long ethtag, String esi, String macaddress, af_afi afi) throws org.apache.thrift.TException;
public int setEbgpMultihop(String peerIp, int nHops) throws org.apache.thrift.TException;
public int sendEOR() throws org.apache.thrift.TException;
+ public int enableBFDFailover(BfdConfigData bfdConfig) throws org.apache.thrift.TException;
+
+ public int disableBFDFailover() throws org.apache.thrift.TException;
+
+ public peer_status_type getPeerStatus(String ipAddress, long asNumber) throws org.apache.thrift.TException;
+
}
public interface AsyncIface {
- public void startBgp(long asNumber, String routerId, int port, int holdTime, int keepAliveTime, int stalepathTime, boolean announceFlush, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
+ public void startBgp(long asNumber, String routerId, int port, int holdTime, int keepAliveTime, int stalepathTime, boolean announceFbit, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
public void stopBgp(long asNumber, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
public void delVrf(String rd, af_afi afi, af_safi safi, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
- public void pushRoute(protocol_type p_type, String prefix, String nexthop, String rd, int ethtag, String esi, String macaddress, int l3label, int l2label, encap_type enc_type, String routermac, af_afi afi, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
+ public void pushRoute(protocol_type p_type, String prefix, String nexthop, String rd, long ethtag, String esi, String macaddress, int l3label, int l2label, encap_type enc_type, String routermac, af_afi afi, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
- public void withdrawRoute(protocol_type p_type, String prefix, String rd, int ethtag, String esi, String macaddress, af_afi afi, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
+ public void withdrawRoute(protocol_type p_type, String prefix, String rd, long ethtag, String esi, String macaddress, af_afi afi, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
public void setEbgpMultihop(String peerIp, int nHops, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
public void sendEOR(org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
+ public void enableBFDFailover(BfdConfigData bfdConfig, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
+
+ public void disableBFDFailover(org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
+
+ public void getPeerStatus(String ipAddress, long asNumber, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
+
}
public static class Client extends org.apache.thrift.TServiceClient implements Iface {
public static class Factory implements org.apache.thrift.TServiceClientFactory<Client> {
public Factory() {}
- @Override
- public Client getClient(org.apache.thrift.protocol.TProtocol prot) {
+ public Client getClient(org.apache.thrift.protocol.TProtocol prot) {
return new Client(prot);
}
- @Override
- public Client getClient(org.apache.thrift.protocol.TProtocol iprot, org.apache.thrift.protocol.TProtocol oprot) {
+ public Client getClient(org.apache.thrift.protocol.TProtocol iprot, org.apache.thrift.protocol.TProtocol oprot) {
return new Client(iprot, oprot);
}
}
super(iprot, oprot);
}
- @Override
- public int startBgp(long asNumber, String routerId, int port, int holdTime, int keepAliveTime, int stalepathTime, boolean announceFlush) throws org.apache.thrift.TException
+ public int startBgp(long asNumber, String routerId, int port, int holdTime, int keepAliveTime, int stalepathTime, boolean announceFbit) throws org.apache.thrift.TException
{
- send_startBgp(asNumber, routerId, port, holdTime, keepAliveTime, stalepathTime, announceFlush);
+ send_startBgp(asNumber, routerId, port, holdTime, keepAliveTime, stalepathTime, announceFbit);
return recv_startBgp();
}
- public void send_startBgp(long asNumber, String routerId, int port, int holdTime, int keepAliveTime, int stalepathTime, boolean announceFlush) throws org.apache.thrift.TException
+ public void send_startBgp(long asNumber, String routerId, int port, int holdTime, int keepAliveTime, int stalepathTime, boolean announceFbit) throws org.apache.thrift.TException
{
startBgp_args args = new startBgp_args();
args.setAsNumber(asNumber);
args.setHoldTime(holdTime);
args.setKeepAliveTime(keepAliveTime);
args.setStalepathTime(stalepathTime);
- args.setAnnounceFlush(announceFlush);
+ args.setAnnounceFbit(announceFbit);
sendBase("startBgp", args);
}
throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "startBgp failed: unknown result");
}
- @Override
- public int stopBgp(long asNumber) throws org.apache.thrift.TException
+ public int stopBgp(long asNumber) throws org.apache.thrift.TException
{
send_stopBgp(asNumber);
return recv_stopBgp();
throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "stopBgp failed: unknown result");
}
- @Override
- public int createPeer(String ipAddress, long asNumber) throws org.apache.thrift.TException
+ public int createPeer(String ipAddress, long asNumber) throws org.apache.thrift.TException
{
send_createPeer(ipAddress, asNumber);
return recv_createPeer();
throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "createPeer failed: unknown result");
}
- @Override
- public int setPeerSecret(String ipAddress, String rfc2385_sharedSecret) throws org.apache.thrift.TException
+ public int setPeerSecret(String ipAddress, String rfc2385_sharedSecret) throws org.apache.thrift.TException
{
send_setPeerSecret(ipAddress, rfc2385_sharedSecret);
return recv_setPeerSecret();
throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "setPeerSecret failed: unknown result");
}
- @Override
- public int deletePeer(String ipAddress) throws org.apache.thrift.TException
+ public int deletePeer(String ipAddress) throws org.apache.thrift.TException
{
send_deletePeer(ipAddress);
return recv_deletePeer();
throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "deletePeer failed: unknown result");
}
- @Override
- public int addVrf(layer_type l_type, String rd, List<String> irts, List<String> erts, af_afi afi, af_safi safi) throws org.apache.thrift.TException
+ public int addVrf(layer_type l_type, String rd, List<String> irts, List<String> erts, af_afi afi, af_safi safi) throws org.apache.thrift.TException
{
send_addVrf(l_type, rd, irts, erts, afi, safi);
return recv_addVrf();
throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "addVrf failed: unknown result");
}
- @Override
- public int delVrf(String rd, af_afi afi, af_safi safi) throws org.apache.thrift.TException
+ public int delVrf(String rd, af_afi afi, af_safi safi) throws org.apache.thrift.TException
{
send_delVrf(rd, afi, safi);
return recv_delVrf();
throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "delVrf failed: unknown result");
}
- @Override
- public int pushRoute(protocol_type p_type, String prefix, String nexthop, String rd, int ethtag, String esi, String macaddress, int l3label, int l2label, encap_type enc_type, String routermac, af_afi afi) throws org.apache.thrift.TException
+ public int pushRoute(protocol_type p_type, String prefix, String nexthop, String rd, long ethtag, String esi, String macaddress, int l3label, int l2label, encap_type enc_type, String routermac, af_afi afi) throws org.apache.thrift.TException
{
send_pushRoute(p_type, prefix, nexthop, rd, ethtag, esi, macaddress, l3label, l2label, enc_type, routermac, afi);
return recv_pushRoute();
}
- public void send_pushRoute(protocol_type p_type, String prefix, String nexthop, String rd, int ethtag, String esi, String macaddress, int l3label, int l2label, encap_type enc_type, String routermac, af_afi afi) throws org.apache.thrift.TException
+ public void send_pushRoute(protocol_type p_type, String prefix, String nexthop, String rd, long ethtag, String esi, String macaddress, int l3label, int l2label, encap_type enc_type, String routermac, af_afi afi) throws org.apache.thrift.TException
{
pushRoute_args args = new pushRoute_args();
args.setP_type(p_type);
throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "pushRoute failed: unknown result");
}
- @Override
- public int withdrawRoute(protocol_type p_type, String prefix, String rd, int ethtag, String esi, String macaddress, af_afi afi) throws org.apache.thrift.TException
+ public int withdrawRoute(protocol_type p_type, String prefix, String rd, long ethtag, String esi, String macaddress, af_afi afi) throws org.apache.thrift.TException
{
send_withdrawRoute(p_type, prefix, rd, ethtag, esi, macaddress, afi);
return recv_withdrawRoute();
}
- public void send_withdrawRoute(protocol_type p_type, String prefix, String rd, int ethtag, String esi, String macaddress, af_afi afi) throws org.apache.thrift.TException
+ public void send_withdrawRoute(protocol_type p_type, String prefix, String rd, long ethtag, String esi, String macaddress, af_afi afi) throws org.apache.thrift.TException
{
withdrawRoute_args args = new withdrawRoute_args();
args.setP_type(p_type);
throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "withdrawRoute failed: unknown result");
}
- @Override
- public int setEbgpMultihop(String peerIp, int nHops) throws org.apache.thrift.TException
+ public int setEbgpMultihop(String peerIp, int nHops) throws org.apache.thrift.TException
{
send_setEbgpMultihop(peerIp, nHops);
return recv_setEbgpMultihop();
throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "setEbgpMultihop failed: unknown result");
}
- @Override
- public int unsetEbgpMultihop(String peerIp) throws org.apache.thrift.TException
+ public int unsetEbgpMultihop(String peerIp) throws org.apache.thrift.TException
{
send_unsetEbgpMultihop(peerIp);
return recv_unsetEbgpMultihop();
throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "unsetEbgpMultihop failed: unknown result");
}
- @Override
- public int setUpdateSource(String peerIp, String srcIp) throws org.apache.thrift.TException
+ public int setUpdateSource(String peerIp, String srcIp) throws org.apache.thrift.TException
{
send_setUpdateSource(peerIp, srcIp);
return recv_setUpdateSource();
throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "setUpdateSource failed: unknown result");
}
- @Override
- public int unsetUpdateSource(String peerIp) throws org.apache.thrift.TException
+ public int unsetUpdateSource(String peerIp) throws org.apache.thrift.TException
{
send_unsetUpdateSource(peerIp);
return recv_unsetUpdateSource();
throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "unsetUpdateSource failed: unknown result");
}
- @Override
- public int enableAddressFamily(String peerIp, af_afi afi, af_safi safi) throws org.apache.thrift.TException
+ public int enableAddressFamily(String peerIp, af_afi afi, af_safi safi) throws org.apache.thrift.TException
{
send_enableAddressFamily(peerIp, afi, safi);
return recv_enableAddressFamily();
throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "enableAddressFamily failed: unknown result");
}
- @Override
- public int disableAddressFamily(String peerIp, af_afi afi, af_safi safi) throws org.apache.thrift.TException
+ public int disableAddressFamily(String peerIp, af_afi afi, af_safi safi) throws org.apache.thrift.TException
{
send_disableAddressFamily(peerIp, afi, safi);
return recv_disableAddressFamily();
throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "disableAddressFamily failed: unknown result");
}
- @Override
- public int setLogConfig(String logFileName, String logLevel) throws org.apache.thrift.TException
+ public int setLogConfig(String logFileName, String logLevel) throws org.apache.thrift.TException
{
send_setLogConfig(logFileName, logLevel);
return recv_setLogConfig();
throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "setLogConfig failed: unknown result");
}
- @Override
- public int enableGracefulRestart(int stalepathTime) throws org.apache.thrift.TException
+ public int enableGracefulRestart(int stalepathTime) throws org.apache.thrift.TException
{
send_enableGracefulRestart(stalepathTime);
return recv_enableGracefulRestart();
throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "enableGracefulRestart failed: unknown result");
}
- @Override
- public int disableGracefulRestart() throws org.apache.thrift.TException
+ public int disableGracefulRestart() throws org.apache.thrift.TException
{
send_disableGracefulRestart();
return recv_disableGracefulRestart();
throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "disableGracefulRestart failed: unknown result");
}
- @Override
- public Routes getRoutes(protocol_type p_type, int optype, int winSize, af_afi afi) throws org.apache.thrift.TException
+ public Routes getRoutes(protocol_type p_type, int optype, int winSize, af_afi afi) throws org.apache.thrift.TException
{
send_getRoutes(p_type, optype, winSize, afi);
return recv_getRoutes();
throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getRoutes failed: unknown result");
}
- @Override
- public int enableMultipath(af_afi afi, af_safi safi) throws org.apache.thrift.TException
+ public int enableMultipath(af_afi afi, af_safi safi) throws org.apache.thrift.TException
{
send_enableMultipath(afi, safi);
return recv_enableMultipath();
throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "enableMultipath failed: unknown result");
}
- @Override
- public int disableMultipath(af_afi afi, af_safi safi) throws org.apache.thrift.TException
+ public int disableMultipath(af_afi afi, af_safi safi) throws org.apache.thrift.TException
{
send_disableMultipath(afi, safi);
return recv_disableMultipath();
throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "disableMultipath failed: unknown result");
}
- @Override
- public int multipaths(String rd, int maxPath) throws org.apache.thrift.TException
+ public int multipaths(String rd, int maxPath) throws org.apache.thrift.TException
{
send_multipaths(rd, maxPath);
return recv_multipaths();
throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "sendEOR failed: unknown result");
}
+ public int enableBFDFailover(BfdConfigData bfdConfig) throws org.apache.thrift.TException
+ {
+ send_enableBFDFailover(bfdConfig);
+ return recv_enableBFDFailover();
+ }
+
+ public void send_enableBFDFailover(BfdConfigData bfdConfig) throws org.apache.thrift.TException
+ {
+ enableBFDFailover_args args = new enableBFDFailover_args();
+ args.setBfdConfig(bfdConfig);
+ sendBase("enableBFDFailover", args);
+ }
+
+ public int recv_enableBFDFailover() throws org.apache.thrift.TException
+ {
+ enableBFDFailover_result result = new enableBFDFailover_result();
+ receiveBase(result, "enableBFDFailover");
+ if (result.isSetSuccess()) {
+ return result.success;
+ }
+ throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "enableBFDFailover failed: unknown result");
+ }
+
+ public int disableBFDFailover() throws org.apache.thrift.TException
+ {
+ send_disableBFDFailover();
+ return recv_disableBFDFailover();
+ }
+
+ public void send_disableBFDFailover() throws org.apache.thrift.TException
+ {
+ disableBFDFailover_args args = new disableBFDFailover_args();
+ sendBase("disableBFDFailover", args);
+ }
+
+ public int recv_disableBFDFailover() throws org.apache.thrift.TException
+ {
+ disableBFDFailover_result result = new disableBFDFailover_result();
+ receiveBase(result, "disableBFDFailover");
+ if (result.isSetSuccess()) {
+ return result.success;
+ }
+ throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "disableBFDFailover failed: unknown result");
+ }
+
+ public peer_status_type getPeerStatus(String ipAddress, long asNumber) throws org.apache.thrift.TException
+ {
+ send_getPeerStatus(ipAddress, asNumber);
+ return recv_getPeerStatus();
+ }
+
+ public void send_getPeerStatus(String ipAddress, long asNumber) throws org.apache.thrift.TException
+ {
+ getPeerStatus_args args = new getPeerStatus_args();
+ args.setIpAddress(ipAddress);
+ args.setAsNumber(asNumber);
+ sendBase("getPeerStatus", args);
+ }
+
+ public peer_status_type recv_getPeerStatus() throws org.apache.thrift.TException
+ {
+ getPeerStatus_result result = new getPeerStatus_result();
+ receiveBase(result, "getPeerStatus");
+ if (result.isSetSuccess()) {
+ return result.success;
+ }
+ throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getPeerStatus failed: unknown result");
+ }
+
}
public static class AsyncClient extends org.apache.thrift.async.TAsyncClient implements AsyncIface {
public static class Factory implements org.apache.thrift.async.TAsyncClientFactory<AsyncClient> {
- private final org.apache.thrift.async.TAsyncClientManager clientManager;
- private final org.apache.thrift.protocol.TProtocolFactory protocolFactory;
+ private org.apache.thrift.async.TAsyncClientManager clientManager;
+ private org.apache.thrift.protocol.TProtocolFactory protocolFactory;
public Factory(org.apache.thrift.async.TAsyncClientManager clientManager, org.apache.thrift.protocol.TProtocolFactory protocolFactory) {
this.clientManager = clientManager;
this.protocolFactory = protocolFactory;
}
- @Override
- public AsyncClient getAsyncClient(org.apache.thrift.transport.TNonblockingTransport transport) {
+ public AsyncClient getAsyncClient(org.apache.thrift.transport.TNonblockingTransport transport) {
return new AsyncClient(protocolFactory, clientManager, transport);
}
}
super(protocolFactory, clientManager, transport);
}
- @Override
- public void startBgp(long asNumber, String routerId, int port, int holdTime, int keepAliveTime, int stalepathTime, boolean announceFlush, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {
+ public void startBgp(long asNumber, String routerId, int port, int holdTime, int keepAliveTime, int stalepathTime, boolean announceFbit, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {
checkReady();
- startBgp_call method_call = new startBgp_call(asNumber, routerId, port, holdTime, keepAliveTime, stalepathTime, announceFlush, resultHandler, this, ___protocolFactory, ___transport);
+ startBgp_call method_call = new startBgp_call(asNumber, routerId, port, holdTime, keepAliveTime, stalepathTime, announceFbit, resultHandler, this, ___protocolFactory, ___transport);
this.___currentMethod = method_call;
___manager.call(method_call);
}
public static class startBgp_call extends org.apache.thrift.async.TAsyncMethodCall {
- private final long asNumber;
- private final String routerId;
- private final int port;
- private final int holdTime;
- private final int keepAliveTime;
- private final int stalepathTime;
- private final boolean announceFlush;
- public startBgp_call(long asNumber, String routerId, int port, int holdTime, int keepAliveTime, int stalepathTime, boolean announceFlush, org.apache.thrift.async.AsyncMethodCallback resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
+ private long asNumber;
+ private String routerId;
+ private int port;
+ private int holdTime;
+ private int keepAliveTime;
+ private int stalepathTime;
+ private boolean announceFbit;
+ public startBgp_call(long asNumber, String routerId, int port, int holdTime, int keepAliveTime, int stalepathTime, boolean announceFbit, org.apache.thrift.async.AsyncMethodCallback resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
super(client, protocolFactory, transport, resultHandler, false);
this.asNumber = asNumber;
this.routerId = routerId;
this.holdTime = holdTime;
this.keepAliveTime = keepAliveTime;
this.stalepathTime = stalepathTime;
- this.announceFlush = announceFlush;
+ this.announceFbit = announceFbit;
}
- @Override
- public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
+ public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("startBgp", org.apache.thrift.protocol.TMessageType.CALL, 0));
startBgp_args args = new startBgp_args();
args.setAsNumber(asNumber);
args.setHoldTime(holdTime);
args.setKeepAliveTime(keepAliveTime);
args.setStalepathTime(stalepathTime);
- args.setAnnounceFlush(announceFlush);
+ args.setAnnounceFbit(announceFbit);
args.write(prot);
prot.writeMessageEnd();
}
}
}
- @Override
- public void stopBgp(long asNumber, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {
+ public void stopBgp(long asNumber, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {
checkReady();
stopBgp_call method_call = new stopBgp_call(asNumber, resultHandler, this, ___protocolFactory, ___transport);
this.___currentMethod = method_call;
}
public static class stopBgp_call extends org.apache.thrift.async.TAsyncMethodCall {
- private final long asNumber;
+ private long asNumber;
public stopBgp_call(long asNumber, org.apache.thrift.async.AsyncMethodCallback resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
super(client, protocolFactory, transport, resultHandler, false);
this.asNumber = asNumber;
}
- @Override
- public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
+ public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("stopBgp", org.apache.thrift.protocol.TMessageType.CALL, 0));
stopBgp_args args = new stopBgp_args();
args.setAsNumber(asNumber);
}
}
- @Override
- public void createPeer(String ipAddress, long asNumber, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {
+ public void createPeer(String ipAddress, long asNumber, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {
checkReady();
createPeer_call method_call = new createPeer_call(ipAddress, asNumber, resultHandler, this, ___protocolFactory, ___transport);
this.___currentMethod = method_call;
}
public static class createPeer_call extends org.apache.thrift.async.TAsyncMethodCall {
- private final String ipAddress;
- private final long asNumber;
+ private String ipAddress;
+ private long asNumber;
public createPeer_call(String ipAddress, long asNumber, org.apache.thrift.async.AsyncMethodCallback resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
super(client, protocolFactory, transport, resultHandler, false);
this.ipAddress = ipAddress;
this.asNumber = asNumber;
}
- @Override
- public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
+ public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("createPeer", org.apache.thrift.protocol.TMessageType.CALL, 0));
createPeer_args args = new createPeer_args();
args.setIpAddress(ipAddress);
}
}
- @Override
- public void setPeerSecret(String ipAddress, String rfc2385_sharedSecret, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {
+ public void setPeerSecret(String ipAddress, String rfc2385_sharedSecret, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {
checkReady();
setPeerSecret_call method_call = new setPeerSecret_call(ipAddress, rfc2385_sharedSecret, resultHandler, this, ___protocolFactory, ___transport);
this.___currentMethod = method_call;
}
public static class setPeerSecret_call extends org.apache.thrift.async.TAsyncMethodCall {
- private final String ipAddress;
- private final String rfc2385_sharedSecret;
+ private String ipAddress;
+ private String rfc2385_sharedSecret;
public setPeerSecret_call(String ipAddress, String rfc2385_sharedSecret, org.apache.thrift.async.AsyncMethodCallback resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
super(client, protocolFactory, transport, resultHandler, false);
this.ipAddress = ipAddress;
this.rfc2385_sharedSecret = rfc2385_sharedSecret;
}
- @Override
- public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
+ public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("setPeerSecret", org.apache.thrift.protocol.TMessageType.CALL, 0));
setPeerSecret_args args = new setPeerSecret_args();
args.setIpAddress(ipAddress);
}
}
- @Override
- public void deletePeer(String ipAddress, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {
+ public void deletePeer(String ipAddress, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {
checkReady();
deletePeer_call method_call = new deletePeer_call(ipAddress, resultHandler, this, ___protocolFactory, ___transport);
this.___currentMethod = method_call;
}
public static class deletePeer_call extends org.apache.thrift.async.TAsyncMethodCall {
- private final String ipAddress;
+ private String ipAddress;
public deletePeer_call(String ipAddress, org.apache.thrift.async.AsyncMethodCallback resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
super(client, protocolFactory, transport, resultHandler, false);
this.ipAddress = ipAddress;
}
- @Override
- public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
+ public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("deletePeer", org.apache.thrift.protocol.TMessageType.CALL, 0));
deletePeer_args args = new deletePeer_args();
args.setIpAddress(ipAddress);
}
}
- @Override
- public void addVrf(layer_type l_type, String rd, List<String> irts, List<String> erts, af_afi afi, af_safi safi, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {
+ public void addVrf(layer_type l_type, String rd, List<String> irts, List<String> erts, af_afi afi, af_safi safi, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {
checkReady();
addVrf_call method_call = new addVrf_call(l_type, rd, irts, erts, afi, safi, resultHandler, this, ___protocolFactory, ___transport);
this.___currentMethod = method_call;
this.safi = safi;
}
- @Override
- public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
+ public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("addVrf", org.apache.thrift.protocol.TMessageType.CALL, 0));
addVrf_args args = new addVrf_args();
args.setL_type(l_type);
}
}
- @Override
- public void delVrf(String rd, af_afi afi, af_safi safi, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {
+ public void delVrf(String rd, af_afi afi, af_safi safi, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {
checkReady();
delVrf_call method_call = new delVrf_call(rd, afi, safi, resultHandler, this, ___protocolFactory, ___transport);
this.___currentMethod = method_call;
this.safi = safi;
}
- @Override
- public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
+ public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("delVrf", org.apache.thrift.protocol.TMessageType.CALL, 0));
delVrf_args args = new delVrf_args();
args.setRd(rd);
}
}
- @Override
- public void pushRoute(protocol_type p_type, String prefix, String nexthop, String rd, int ethtag, String esi, String macaddress, int l3label, int l2label, encap_type enc_type, String routermac, af_afi afi, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {
+ public void pushRoute(protocol_type p_type, String prefix, String nexthop, String rd, long ethtag, String esi, String macaddress, int l3label, int l2label, encap_type enc_type, String routermac, af_afi afi, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {
checkReady();
pushRoute_call method_call = new pushRoute_call(p_type, prefix, nexthop, rd, ethtag, esi, macaddress, l3label, l2label, enc_type, routermac, afi, resultHandler, this, ___protocolFactory, ___transport);
this.___currentMethod = method_call;
}
public static class pushRoute_call extends org.apache.thrift.async.TAsyncMethodCall {
- private final protocol_type p_type;
- private final String prefix;
- private final String nexthop;
- private final String rd;
- private final int ethtag;
- private final String esi;
- private final String macaddress;
- private final int l3label;
- private final int l2label;
- private final encap_type enc_type;
- private final String routermac;
- private final af_afi afi;
- public pushRoute_call(protocol_type p_type, String prefix, String nexthop, String rd, int ethtag, String esi, String macaddress, int l3label, int l2label, encap_type enc_type, String routermac, af_afi afi, org.apache.thrift.async.AsyncMethodCallback resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
+ private protocol_type p_type;
+ private String prefix;
+ private String nexthop;
+ private String rd;
+ private long ethtag;
+ private String esi;
+ private String macaddress;
+ private int l3label;
+ private int l2label;
+ private encap_type enc_type;
+ private String routermac;
+ private af_afi afi;
+ public pushRoute_call(protocol_type p_type, String prefix, String nexthop, String rd, long ethtag, String esi, String macaddress, int l3label, int l2label, encap_type enc_type, String routermac, af_afi afi, org.apache.thrift.async.AsyncMethodCallback resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
super(client, protocolFactory, transport, resultHandler, false);
this.p_type = p_type;
this.prefix = prefix;
this.afi = afi;
}
- @Override
- public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
+ public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("pushRoute", org.apache.thrift.protocol.TMessageType.CALL, 0));
pushRoute_args args = new pushRoute_args();
args.setP_type(p_type);
}
}
- @Override
- public void withdrawRoute(protocol_type p_type, String prefix, String rd, int ethtag, String esi, String macaddress, af_afi afi, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {
+ public void withdrawRoute(protocol_type p_type, String prefix, String rd, long ethtag, String esi, String macaddress, af_afi afi, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {
checkReady();
withdrawRoute_call method_call = new withdrawRoute_call(p_type, prefix, rd, ethtag, esi, macaddress, afi, resultHandler, this, ___protocolFactory, ___transport);
this.___currentMethod = method_call;
}
public static class withdrawRoute_call extends org.apache.thrift.async.TAsyncMethodCall {
- private final protocol_type p_type;
- private final String prefix;
- private final String rd;
- private final int ethtag;
- private final String esi;
- private final String macaddress;
- private final af_afi afi;
- public withdrawRoute_call(protocol_type p_type, String prefix, String rd, int ethtag, String esi, String macaddress, af_afi afi, org.apache.thrift.async.AsyncMethodCallback resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
+ private protocol_type p_type;
+ private String prefix;
+ private String rd;
+ private long ethtag;
+ private String esi;
+ private String macaddress;
+ private af_afi afi;
+ public withdrawRoute_call(protocol_type p_type, String prefix, String rd, long ethtag, String esi, String macaddress, af_afi afi, org.apache.thrift.async.AsyncMethodCallback resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
super(client, protocolFactory, transport, resultHandler, false);
this.p_type = p_type;
this.prefix = prefix;
this.afi = afi;
}
- @Override
- public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
+ public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("withdrawRoute", org.apache.thrift.protocol.TMessageType.CALL, 0));
withdrawRoute_args args = new withdrawRoute_args();
args.setP_type(p_type);
}
}
- @Override
- public void setEbgpMultihop(String peerIp, int nHops, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {
+ public void setEbgpMultihop(String peerIp, int nHops, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {
checkReady();
setEbgpMultihop_call method_call = new setEbgpMultihop_call(peerIp, nHops, resultHandler, this, ___protocolFactory, ___transport);
this.___currentMethod = method_call;
}
public static class setEbgpMultihop_call extends org.apache.thrift.async.TAsyncMethodCall {
- private final String peerIp;
- private final int nHops;
+ private String peerIp;
+ private int nHops;
public setEbgpMultihop_call(String peerIp, int nHops, org.apache.thrift.async.AsyncMethodCallback resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
super(client, protocolFactory, transport, resultHandler, false);
this.peerIp = peerIp;
this.nHops = nHops;
}
- @Override
- public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
+ public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("setEbgpMultihop", org.apache.thrift.protocol.TMessageType.CALL, 0));
setEbgpMultihop_args args = new setEbgpMultihop_args();
args.setPeerIp(peerIp);
}
}
- @Override
- public void unsetEbgpMultihop(String peerIp, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {
+ public void unsetEbgpMultihop(String peerIp, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {
checkReady();
unsetEbgpMultihop_call method_call = new unsetEbgpMultihop_call(peerIp, resultHandler, this, ___protocolFactory, ___transport);
this.___currentMethod = method_call;
}
public static class unsetEbgpMultihop_call extends org.apache.thrift.async.TAsyncMethodCall {
- private final String peerIp;
+ private String peerIp;
public unsetEbgpMultihop_call(String peerIp, org.apache.thrift.async.AsyncMethodCallback resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
super(client, protocolFactory, transport, resultHandler, false);
this.peerIp = peerIp;
}
- @Override
- public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
+ public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("unsetEbgpMultihop", org.apache.thrift.protocol.TMessageType.CALL, 0));
unsetEbgpMultihop_args args = new unsetEbgpMultihop_args();
args.setPeerIp(peerIp);
}
}
- @Override
- public void setUpdateSource(String peerIp, String srcIp, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {
+ public void setUpdateSource(String peerIp, String srcIp, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {
checkReady();
setUpdateSource_call method_call = new setUpdateSource_call(peerIp, srcIp, resultHandler, this, ___protocolFactory, ___transport);
this.___currentMethod = method_call;
}
public static class setUpdateSource_call extends org.apache.thrift.async.TAsyncMethodCall {
- private final String peerIp;
- private final String srcIp;
+ private String peerIp;
+ private String srcIp;
public setUpdateSource_call(String peerIp, String srcIp, org.apache.thrift.async.AsyncMethodCallback resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
super(client, protocolFactory, transport, resultHandler, false);
this.peerIp = peerIp;
this.srcIp = srcIp;
}
- @Override
- public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
+ public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("setUpdateSource", org.apache.thrift.protocol.TMessageType.CALL, 0));
setUpdateSource_args args = new setUpdateSource_args();
args.setPeerIp(peerIp);
}
}
- @Override
- public void unsetUpdateSource(String peerIp, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {
+ public void unsetUpdateSource(String peerIp, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {
checkReady();
unsetUpdateSource_call method_call = new unsetUpdateSource_call(peerIp, resultHandler, this, ___protocolFactory, ___transport);
this.___currentMethod = method_call;
}
public static class unsetUpdateSource_call extends org.apache.thrift.async.TAsyncMethodCall {
- private final String peerIp;
+ private String peerIp;
public unsetUpdateSource_call(String peerIp, org.apache.thrift.async.AsyncMethodCallback resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
super(client, protocolFactory, transport, resultHandler, false);
this.peerIp = peerIp;
}
- @Override
- public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
+ public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("unsetUpdateSource", org.apache.thrift.protocol.TMessageType.CALL, 0));
unsetUpdateSource_args args = new unsetUpdateSource_args();
args.setPeerIp(peerIp);
}
}
- @Override
- public void enableAddressFamily(String peerIp, af_afi afi, af_safi safi, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {
+ public void enableAddressFamily(String peerIp, af_afi afi, af_safi safi, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {
checkReady();
enableAddressFamily_call method_call = new enableAddressFamily_call(peerIp, afi, safi, resultHandler, this, ___protocolFactory, ___transport);
this.___currentMethod = method_call;
}
public static class enableAddressFamily_call extends org.apache.thrift.async.TAsyncMethodCall {
- private final String peerIp;
- private final af_afi afi;
- private final af_safi safi;
+ private String peerIp;
+ private af_afi afi;
+ private af_safi safi;
public enableAddressFamily_call(String peerIp, af_afi afi, af_safi safi, org.apache.thrift.async.AsyncMethodCallback resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
super(client, protocolFactory, transport, resultHandler, false);
this.peerIp = peerIp;
this.safi = safi;
}
- @Override
- public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
+ public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("enableAddressFamily", org.apache.thrift.protocol.TMessageType.CALL, 0));
enableAddressFamily_args args = new enableAddressFamily_args();
args.setPeerIp(peerIp);
}
}
- @Override
- public void disableAddressFamily(String peerIp, af_afi afi, af_safi safi, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {
+ public void disableAddressFamily(String peerIp, af_afi afi, af_safi safi, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {
checkReady();
disableAddressFamily_call method_call = new disableAddressFamily_call(peerIp, afi, safi, resultHandler, this, ___protocolFactory, ___transport);
this.___currentMethod = method_call;
}
public static class disableAddressFamily_call extends org.apache.thrift.async.TAsyncMethodCall {
- private final String peerIp;
- private final af_afi afi;
- private final af_safi safi;
+ private String peerIp;
+ private af_afi afi;
+ private af_safi safi;
public disableAddressFamily_call(String peerIp, af_afi afi, af_safi safi, org.apache.thrift.async.AsyncMethodCallback resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
super(client, protocolFactory, transport, resultHandler, false);
this.peerIp = peerIp;
this.safi = safi;
}
- @Override
- public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
+ public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("disableAddressFamily", org.apache.thrift.protocol.TMessageType.CALL, 0));
disableAddressFamily_args args = new disableAddressFamily_args();
args.setPeerIp(peerIp);
}
}
- @Override
- public void setLogConfig(String logFileName, String logLevel, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {
+ public void setLogConfig(String logFileName, String logLevel, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {
checkReady();
setLogConfig_call method_call = new setLogConfig_call(logFileName, logLevel, resultHandler, this, ___protocolFactory, ___transport);
this.___currentMethod = method_call;
}
public static class setLogConfig_call extends org.apache.thrift.async.TAsyncMethodCall {
- private final String logFileName;
- private final String logLevel;
+ private String logFileName;
+ private String logLevel;
public setLogConfig_call(String logFileName, String logLevel, org.apache.thrift.async.AsyncMethodCallback resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
super(client, protocolFactory, transport, resultHandler, false);
this.logFileName = logFileName;
this.logLevel = logLevel;
}
- @Override
- public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
+ public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("setLogConfig", org.apache.thrift.protocol.TMessageType.CALL, 0));
setLogConfig_args args = new setLogConfig_args();
args.setLogFileName(logFileName);
}
}
- @Override
- public void enableGracefulRestart(int stalepathTime, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {
+ public void enableGracefulRestart(int stalepathTime, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {
checkReady();
enableGracefulRestart_call method_call = new enableGracefulRestart_call(stalepathTime, resultHandler, this, ___protocolFactory, ___transport);
this.___currentMethod = method_call;
}
public static class enableGracefulRestart_call extends org.apache.thrift.async.TAsyncMethodCall {
- private final int stalepathTime;
+ private int stalepathTime;
public enableGracefulRestart_call(int stalepathTime, org.apache.thrift.async.AsyncMethodCallback resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
super(client, protocolFactory, transport, resultHandler, false);
this.stalepathTime = stalepathTime;
}
- @Override
- public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
+ public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("enableGracefulRestart", org.apache.thrift.protocol.TMessageType.CALL, 0));
enableGracefulRestart_args args = new enableGracefulRestart_args();
args.setStalepathTime(stalepathTime);
}
}
- @Override
- public void disableGracefulRestart(org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {
+ public void disableGracefulRestart(org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {
checkReady();
disableGracefulRestart_call method_call = new disableGracefulRestart_call(resultHandler, this, ___protocolFactory, ___transport);
this.___currentMethod = method_call;
super(client, protocolFactory, transport, resultHandler, false);
}
- @Override
- public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
+ public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("disableGracefulRestart", org.apache.thrift.protocol.TMessageType.CALL, 0));
disableGracefulRestart_args args = new disableGracefulRestart_args();
args.write(prot);
}
}
- @Override
- public void getRoutes(protocol_type p_type, int optype, int winSize, af_afi afi, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {
+ public void getRoutes(protocol_type p_type, int optype, int winSize, af_afi afi, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {
checkReady();
getRoutes_call method_call = new getRoutes_call(p_type, optype, winSize, afi, resultHandler, this, ___protocolFactory, ___transport);
this.___currentMethod = method_call;
}
public static class getRoutes_call extends org.apache.thrift.async.TAsyncMethodCall {
- private final protocol_type p_type;
- private final int optype;
- private final int winSize;
- private final af_afi afi;
+ private protocol_type p_type;
+ private int optype;
+ private int winSize;
+ private af_afi afi;
public getRoutes_call(protocol_type p_type, int optype, int winSize, af_afi afi, org.apache.thrift.async.AsyncMethodCallback resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
super(client, protocolFactory, transport, resultHandler, false);
this.p_type = p_type;
this.afi = afi;
}
- @Override
- public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
+ public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getRoutes", org.apache.thrift.protocol.TMessageType.CALL, 0));
getRoutes_args args = new getRoutes_args();
args.setP_type(p_type);
}
}
- @Override
- public void enableMultipath(af_afi afi, af_safi safi, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {
+ public void enableMultipath(af_afi afi, af_safi safi, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {
checkReady();
enableMultipath_call method_call = new enableMultipath_call(afi, safi, resultHandler, this, ___protocolFactory, ___transport);
this.___currentMethod = method_call;
}
public static class enableMultipath_call extends org.apache.thrift.async.TAsyncMethodCall {
- private final af_afi afi;
- private final af_safi safi;
+ private af_afi afi;
+ private af_safi safi;
public enableMultipath_call(af_afi afi, af_safi safi, org.apache.thrift.async.AsyncMethodCallback resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
super(client, protocolFactory, transport, resultHandler, false);
this.afi = afi;
this.safi = safi;
}
- @Override
- public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
+ public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("enableMultipath", org.apache.thrift.protocol.TMessageType.CALL, 0));
enableMultipath_args args = new enableMultipath_args();
args.setAfi(afi);
}
}
- @Override
- public void disableMultipath(af_afi afi, af_safi safi, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {
+ public void disableMultipath(af_afi afi, af_safi safi, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {
checkReady();
disableMultipath_call method_call = new disableMultipath_call(afi, safi, resultHandler, this, ___protocolFactory, ___transport);
this.___currentMethod = method_call;
}
public static class disableMultipath_call extends org.apache.thrift.async.TAsyncMethodCall {
- private final af_afi afi;
- private final af_safi safi;
+ private af_afi afi;
+ private af_safi safi;
public disableMultipath_call(af_afi afi, af_safi safi, org.apache.thrift.async.AsyncMethodCallback resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
super(client, protocolFactory, transport, resultHandler, false);
this.afi = afi;
this.safi = safi;
}
- @Override
- public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
+ public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("disableMultipath", org.apache.thrift.protocol.TMessageType.CALL, 0));
disableMultipath_args args = new disableMultipath_args();
args.setAfi(afi);
}
}
- @Override
- public void multipaths(String rd, int maxPath, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {
+ public void multipaths(String rd, int maxPath, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {
checkReady();
multipaths_call method_call = new multipaths_call(rd, maxPath, resultHandler, this, ___protocolFactory, ___transport);
this.___currentMethod = method_call;
}
public static class multipaths_call extends org.apache.thrift.async.TAsyncMethodCall {
- private final String rd;
- private final int maxPath;
+ private String rd;
+ private int maxPath;
public multipaths_call(String rd, int maxPath, org.apache.thrift.async.AsyncMethodCallback resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
super(client, protocolFactory, transport, resultHandler, false);
this.rd = rd;
this.maxPath = maxPath;
}
- @Override
- public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
+ public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("multipaths", org.apache.thrift.protocol.TMessageType.CALL, 0));
multipaths_args args = new multipaths_args();
args.setRd(rd);
}
org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
- return new Client(prot).recv_multipaths();
+ return (new Client(prot)).recv_multipaths();
}
}
}
org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
- return new Client(prot).recv_enableEORDelay();
+ return (new Client(prot)).recv_enableEORDelay();
}
}
}
}
+ public void enableBFDFailover(BfdConfigData bfdConfig, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {
+ checkReady();
+ enableBFDFailover_call method_call = new enableBFDFailover_call(bfdConfig, resultHandler, this, ___protocolFactory, ___transport);
+ this.___currentMethod = method_call;
+ ___manager.call(method_call);
+ }
+
+ public static class enableBFDFailover_call extends org.apache.thrift.async.TAsyncMethodCall {
+ private BfdConfigData bfdConfig;
+ public enableBFDFailover_call(BfdConfigData bfdConfig, org.apache.thrift.async.AsyncMethodCallback resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
+ super(client, protocolFactory, transport, resultHandler, false);
+ this.bfdConfig = bfdConfig;
+ }
+
+ public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
+ prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("enableBFDFailover", org.apache.thrift.protocol.TMessageType.CALL, 0));
+ enableBFDFailover_args args = new enableBFDFailover_args();
+ args.setBfdConfig(bfdConfig);
+ args.write(prot);
+ prot.writeMessageEnd();
+ }
+
+ public int getResult() throws org.apache.thrift.TException {
+ if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
+ throw new IllegalStateException("Method call not finished!");
+ }
+ org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
+ org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
+ return (new Client(prot)).recv_enableBFDFailover();
+ }
+ }
+
+ public void disableBFDFailover(org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {
+ checkReady();
+ disableBFDFailover_call method_call = new disableBFDFailover_call(resultHandler, this, ___protocolFactory, ___transport);
+ this.___currentMethod = method_call;
+ ___manager.call(method_call);
+ }
+
+ public static class disableBFDFailover_call extends org.apache.thrift.async.TAsyncMethodCall {
+ public disableBFDFailover_call(org.apache.thrift.async.AsyncMethodCallback resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
+ super(client, protocolFactory, transport, resultHandler, false);
+ }
+
+ public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
+ prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("disableBFDFailover", org.apache.thrift.protocol.TMessageType.CALL, 0));
+ disableBFDFailover_args args = new disableBFDFailover_args();
+ args.write(prot);
+ prot.writeMessageEnd();
+ }
+
+ public int getResult() throws org.apache.thrift.TException {
+ if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
+ throw new IllegalStateException("Method call not finished!");
+ }
+ org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
+ org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
+ return (new Client(prot)).recv_disableBFDFailover();
+ }
+ }
+
+ public void getPeerStatus(String ipAddress, long asNumber, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {
+ checkReady();
+ getPeerStatus_call method_call = new getPeerStatus_call(ipAddress, asNumber, resultHandler, this, ___protocolFactory, ___transport);
+ this.___currentMethod = method_call;
+ ___manager.call(method_call);
+ }
+
+ public static class getPeerStatus_call extends org.apache.thrift.async.TAsyncMethodCall {
+ private String ipAddress;
+ private long asNumber;
+ public getPeerStatus_call(String ipAddress, long asNumber, org.apache.thrift.async.AsyncMethodCallback resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
+ super(client, protocolFactory, transport, resultHandler, false);
+ this.ipAddress = ipAddress;
+ this.asNumber = asNumber;
+ }
+
+ public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
+ prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getPeerStatus", org.apache.thrift.protocol.TMessageType.CALL, 0));
+ getPeerStatus_args args = new getPeerStatus_args();
+ args.setIpAddress(ipAddress);
+ args.setAsNumber(asNumber);
+ args.write(prot);
+ prot.writeMessageEnd();
+ }
+
+ public peer_status_type getResult() throws org.apache.thrift.TException {
+ if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
+ throw new IllegalStateException("Method call not finished!");
+ }
+ org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
+ org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
+ return (new Client(prot)).recv_getPeerStatus();
+ }
+ }
+
}
public static class Processor<I extends Iface> extends org.apache.thrift.TBaseProcessor<I> implements org.apache.thrift.TProcessor {
- private static final Logger LOG = LoggerFactory.getLogger(Processor.class.getName());
+ private static final Logger LOGGER = LoggerFactory.getLogger(Processor.class.getName());
public Processor(I iface) {
super(iface, getProcessMap(new HashMap<String, org.apache.thrift.ProcessFunction<I, ? extends org.apache.thrift.TBase>>()));
}
processMap.put("multipaths", new multipaths());
processMap.put("enableEORDelay", new enableEORDelay());
processMap.put("sendEOR", new sendEOR());
+ processMap.put("enableBFDFailover", new enableBFDFailover());
+ processMap.put("disableBFDFailover", new disableBFDFailover());
+ processMap.put("getPeerStatus", new getPeerStatus());
return processMap;
}
super("startBgp");
}
- @Override
- public startBgp_args getEmptyArgsInstance() {
+ public startBgp_args getEmptyArgsInstance() {
return new startBgp_args();
}
- @Override
- protected boolean isOneway() {
+ protected boolean isOneway() {
return false;
}
- @Override
- public startBgp_result getResult(I iface, startBgp_args args) throws org.apache.thrift.TException {
+ public startBgp_result getResult(I iface, startBgp_args args) throws org.apache.thrift.TException {
startBgp_result result = new startBgp_result();
- result.success = iface.startBgp(args.asNumber, args.routerId, args.port, args.holdTime, args.keepAliveTime, args.stalepathTime, args.announceFlush);
+ result.success = iface.startBgp(args.asNumber, args.routerId, args.port, args.holdTime, args.keepAliveTime, args.stalepathTime, args.announceFbit);
result.setSuccessIsSet(true);
return result;
}
super("stopBgp");
}
- @Override
- public stopBgp_args getEmptyArgsInstance() {
+ public stopBgp_args getEmptyArgsInstance() {
return new stopBgp_args();
}
- @Override
- protected boolean isOneway() {
+ protected boolean isOneway() {
return false;
}
- @Override
- public stopBgp_result getResult(I iface, stopBgp_args args) throws org.apache.thrift.TException {
+ public stopBgp_result getResult(I iface, stopBgp_args args) throws org.apache.thrift.TException {
stopBgp_result result = new stopBgp_result();
result.success = iface.stopBgp(args.asNumber);
result.setSuccessIsSet(true);
super("createPeer");
}
- @Override
- public createPeer_args getEmptyArgsInstance() {
+ public createPeer_args getEmptyArgsInstance() {
return new createPeer_args();
}
- @Override
- protected boolean isOneway() {
+ protected boolean isOneway() {
return false;
}
- @Override
- public createPeer_result getResult(I iface, createPeer_args args) throws org.apache.thrift.TException {
+ public createPeer_result getResult(I iface, createPeer_args args) throws org.apache.thrift.TException {
createPeer_result result = new createPeer_result();
result.success = iface.createPeer(args.ipAddress, args.asNumber);
result.setSuccessIsSet(true);
super("setPeerSecret");
}
- @Override
- public setPeerSecret_args getEmptyArgsInstance() {
+ public setPeerSecret_args getEmptyArgsInstance() {
return new setPeerSecret_args();
}
- @Override
- protected boolean isOneway() {
+ protected boolean isOneway() {
return false;
}
- @Override
- public setPeerSecret_result getResult(I iface, setPeerSecret_args args) throws org.apache.thrift.TException {
+ public setPeerSecret_result getResult(I iface, setPeerSecret_args args) throws org.apache.thrift.TException {
setPeerSecret_result result = new setPeerSecret_result();
result.success = iface.setPeerSecret(args.ipAddress, args.rfc2385_sharedSecret);
result.setSuccessIsSet(true);
super("deletePeer");
}
- @Override
- public deletePeer_args getEmptyArgsInstance() {
+ public deletePeer_args getEmptyArgsInstance() {
return new deletePeer_args();
}
- @Override
- protected boolean isOneway() {
+ protected boolean isOneway() {
return false;
}
- @Override
- public deletePeer_result getResult(I iface, deletePeer_args args) throws org.apache.thrift.TException {
+ public deletePeer_result getResult(I iface, deletePeer_args args) throws org.apache.thrift.TException {
deletePeer_result result = new deletePeer_result();
result.success = iface.deletePeer(args.ipAddress);
result.setSuccessIsSet(true);
super("addVrf");
}
- @Override
- public addVrf_args getEmptyArgsInstance() {
+ public addVrf_args getEmptyArgsInstance() {
return new addVrf_args();
}
- @Override
- protected boolean isOneway() {
+ protected boolean isOneway() {
return false;
}
- @Override
- public addVrf_result getResult(I iface, addVrf_args args) throws org.apache.thrift.TException {
+ public addVrf_result getResult(I iface, addVrf_args args) throws org.apache.thrift.TException {
addVrf_result result = new addVrf_result();
result.success = iface.addVrf(args.l_type, args.rd, args.irts, args.erts, args.afi, args.safi);
result.setSuccessIsSet(true);
super("delVrf");
}
- @Override
- public delVrf_args getEmptyArgsInstance() {
+ public delVrf_args getEmptyArgsInstance() {
return new delVrf_args();
}
- @Override
- protected boolean isOneway() {
+ protected boolean isOneway() {
return false;
}
- @Override
- public delVrf_result getResult(I iface, delVrf_args args) throws org.apache.thrift.TException {
+ public delVrf_result getResult(I iface, delVrf_args args) throws org.apache.thrift.TException {
delVrf_result result = new delVrf_result();
result.success = iface.delVrf(args.rd, args.afi, args.safi);
result.setSuccessIsSet(true);
super("pushRoute");
}
- @Override
- public pushRoute_args getEmptyArgsInstance() {
+ public pushRoute_args getEmptyArgsInstance() {
return new pushRoute_args();
}
- @Override
- protected boolean isOneway() {
+ protected boolean isOneway() {
return false;
}
- @Override
- public pushRoute_result getResult(I iface, pushRoute_args args) throws org.apache.thrift.TException {
+ public pushRoute_result getResult(I iface, pushRoute_args args) throws org.apache.thrift.TException {
pushRoute_result result = new pushRoute_result();
result.success = iface.pushRoute(args.p_type, args.prefix, args.nexthop, args.rd, args.ethtag, args.esi, args.macaddress, args.l3label, args.l2label, args.enc_type, args.routermac, args.afi);
result.setSuccessIsSet(true);
super("withdrawRoute");
}
- @Override
- public withdrawRoute_args getEmptyArgsInstance() {
+ public withdrawRoute_args getEmptyArgsInstance() {
return new withdrawRoute_args();
}
- @Override
- protected boolean isOneway() {
+ protected boolean isOneway() {
return false;
}
- @Override
- public withdrawRoute_result getResult(I iface, withdrawRoute_args args) throws org.apache.thrift.TException {
+ public withdrawRoute_result getResult(I iface, withdrawRoute_args args) throws org.apache.thrift.TException {
withdrawRoute_result result = new withdrawRoute_result();
result.success = iface.withdrawRoute(args.p_type, args.prefix, args.rd, args.ethtag, args.esi, args.macaddress, args.afi);
result.setSuccessIsSet(true);
super("setEbgpMultihop");
}
- @Override
- public setEbgpMultihop_args getEmptyArgsInstance() {
+ public setEbgpMultihop_args getEmptyArgsInstance() {
return new setEbgpMultihop_args();
}
- @Override
- protected boolean isOneway() {
+ protected boolean isOneway() {
return false;
}
- @Override
- public setEbgpMultihop_result getResult(I iface, setEbgpMultihop_args args) throws org.apache.thrift.TException {
+ public setEbgpMultihop_result getResult(I iface, setEbgpMultihop_args args) throws org.apache.thrift.TException {
setEbgpMultihop_result result = new setEbgpMultihop_result();
result.success = iface.setEbgpMultihop(args.peerIp, args.nHops);
result.setSuccessIsSet(true);
super("unsetEbgpMultihop");
}
- @Override
- public unsetEbgpMultihop_args getEmptyArgsInstance() {
+ public unsetEbgpMultihop_args getEmptyArgsInstance() {
return new unsetEbgpMultihop_args();
}
- @Override
- protected boolean isOneway() {
+ protected boolean isOneway() {
return false;
}
- @Override
- public unsetEbgpMultihop_result getResult(I iface, unsetEbgpMultihop_args args) throws org.apache.thrift.TException {
+ public unsetEbgpMultihop_result getResult(I iface, unsetEbgpMultihop_args args) throws org.apache.thrift.TException {
unsetEbgpMultihop_result result = new unsetEbgpMultihop_result();
result.success = iface.unsetEbgpMultihop(args.peerIp);
result.setSuccessIsSet(true);
super("setUpdateSource");
}
- @Override
- public setUpdateSource_args getEmptyArgsInstance() {
+ public setUpdateSource_args getEmptyArgsInstance() {
return new setUpdateSource_args();
}
- @Override
- protected boolean isOneway() {
+ protected boolean isOneway() {
return false;
}
- @Override
- public setUpdateSource_result getResult(I iface, setUpdateSource_args args) throws org.apache.thrift.TException {
+ public setUpdateSource_result getResult(I iface, setUpdateSource_args args) throws org.apache.thrift.TException {
setUpdateSource_result result = new setUpdateSource_result();
result.success = iface.setUpdateSource(args.peerIp, args.srcIp);
result.setSuccessIsSet(true);
super("unsetUpdateSource");
}
- @Override
- public unsetUpdateSource_args getEmptyArgsInstance() {
+ public unsetUpdateSource_args getEmptyArgsInstance() {
return new unsetUpdateSource_args();
}
- @Override
- protected boolean isOneway() {
+ protected boolean isOneway() {
return false;
}
- @Override
- public unsetUpdateSource_result getResult(I iface, unsetUpdateSource_args args) throws org.apache.thrift.TException {
+ public unsetUpdateSource_result getResult(I iface, unsetUpdateSource_args args) throws org.apache.thrift.TException {
unsetUpdateSource_result result = new unsetUpdateSource_result();
result.success = iface.unsetUpdateSource(args.peerIp);
result.setSuccessIsSet(true);
super("enableAddressFamily");
}
- @Override
- public enableAddressFamily_args getEmptyArgsInstance() {
+ public enableAddressFamily_args getEmptyArgsInstance() {
return new enableAddressFamily_args();
}
- @Override
- protected boolean isOneway() {
+ protected boolean isOneway() {
return false;
}
- @Override
- public enableAddressFamily_result getResult(I iface, enableAddressFamily_args args) throws org.apache.thrift.TException {
+ public enableAddressFamily_result getResult(I iface, enableAddressFamily_args args) throws org.apache.thrift.TException {
enableAddressFamily_result result = new enableAddressFamily_result();
result.success = iface.enableAddressFamily(args.peerIp, args.afi, args.safi);
result.setSuccessIsSet(true);
super("disableAddressFamily");
}
- @Override
- public disableAddressFamily_args getEmptyArgsInstance() {
+ public disableAddressFamily_args getEmptyArgsInstance() {
return new disableAddressFamily_args();
}
- @Override
- protected boolean isOneway() {
+ protected boolean isOneway() {
return false;
}
- @Override
- public disableAddressFamily_result getResult(I iface, disableAddressFamily_args args) throws org.apache.thrift.TException {
+ public disableAddressFamily_result getResult(I iface, disableAddressFamily_args args) throws org.apache.thrift.TException {
disableAddressFamily_result result = new disableAddressFamily_result();
result.success = iface.disableAddressFamily(args.peerIp, args.afi, args.safi);
result.setSuccessIsSet(true);
super("setLogConfig");
}
- @Override
- public setLogConfig_args getEmptyArgsInstance() {
+ public setLogConfig_args getEmptyArgsInstance() {
return new setLogConfig_args();
}
- @Override
- protected boolean isOneway() {
+ protected boolean isOneway() {
return false;
}
- @Override
- public setLogConfig_result getResult(I iface, setLogConfig_args args) throws org.apache.thrift.TException {
+ public setLogConfig_result getResult(I iface, setLogConfig_args args) throws org.apache.thrift.TException {
setLogConfig_result result = new setLogConfig_result();
result.success = iface.setLogConfig(args.logFileName, args.logLevel);
result.setSuccessIsSet(true);
super("enableGracefulRestart");
}
- @Override
- public enableGracefulRestart_args getEmptyArgsInstance() {
+ public enableGracefulRestart_args getEmptyArgsInstance() {
return new enableGracefulRestart_args();
}
- @Override
- protected boolean isOneway() {
+ protected boolean isOneway() {
return false;
}
- @Override
- public enableGracefulRestart_result getResult(I iface, enableGracefulRestart_args args) throws org.apache.thrift.TException {
+ public enableGracefulRestart_result getResult(I iface, enableGracefulRestart_args args) throws org.apache.thrift.TException {
enableGracefulRestart_result result = new enableGracefulRestart_result();
result.success = iface.enableGracefulRestart(args.stalepathTime);
result.setSuccessIsSet(true);
super("disableGracefulRestart");
}
- @Override
- public disableGracefulRestart_args getEmptyArgsInstance() {
+ public disableGracefulRestart_args getEmptyArgsInstance() {
return new disableGracefulRestart_args();
}
- @Override
- protected boolean isOneway() {
+ protected boolean isOneway() {
return false;
}
- @Override
- public disableGracefulRestart_result getResult(I iface, disableGracefulRestart_args args) throws org.apache.thrift.TException {
+ public disableGracefulRestart_result getResult(I iface, disableGracefulRestart_args args) throws org.apache.thrift.TException {
disableGracefulRestart_result result = new disableGracefulRestart_result();
result.success = iface.disableGracefulRestart();
result.setSuccessIsSet(true);
super("getRoutes");
}
- @Override
- public getRoutes_args getEmptyArgsInstance() {
+ public getRoutes_args getEmptyArgsInstance() {
return new getRoutes_args();
}
- @Override
- protected boolean isOneway() {
+ protected boolean isOneway() {
return false;
}
- @Override
- public getRoutes_result getResult(I iface, getRoutes_args args) throws org.apache.thrift.TException {
+ public getRoutes_result getResult(I iface, getRoutes_args args) throws org.apache.thrift.TException {
getRoutes_result result = new getRoutes_result();
result.success = iface.getRoutes(args.p_type, args.optype, args.winSize, args.afi);
return result;
super("enableMultipath");
}
- @Override
- public enableMultipath_args getEmptyArgsInstance() {
+ public enableMultipath_args getEmptyArgsInstance() {
return new enableMultipath_args();
}
- @Override
- protected boolean isOneway() {
+ protected boolean isOneway() {
return false;
}
- @Override
- public enableMultipath_result getResult(I iface, enableMultipath_args args) throws org.apache.thrift.TException {
+ public enableMultipath_result getResult(I iface, enableMultipath_args args) throws org.apache.thrift.TException {
enableMultipath_result result = new enableMultipath_result();
result.success = iface.enableMultipath(args.afi, args.safi);
result.setSuccessIsSet(true);
super("disableMultipath");
}
- @Override
- public disableMultipath_args getEmptyArgsInstance() {
+ public disableMultipath_args getEmptyArgsInstance() {
return new disableMultipath_args();
}
- @Override
- protected boolean isOneway() {
+ protected boolean isOneway() {
return false;
}
- @Override
- public disableMultipath_result getResult(I iface, disableMultipath_args args) throws org.apache.thrift.TException {
+ public disableMultipath_result getResult(I iface, disableMultipath_args args) throws org.apache.thrift.TException {
disableMultipath_result result = new disableMultipath_result();
result.success = iface.disableMultipath(args.afi, args.safi);
result.setSuccessIsSet(true);
super("multipaths");
}
- @Override
- public multipaths_args getEmptyArgsInstance() {
+ public multipaths_args getEmptyArgsInstance() {
return new multipaths_args();
}
- @Override
- protected boolean isOneway() {
+ protected boolean isOneway() {
return false;
}
- @Override
- public multipaths_result getResult(I iface, multipaths_args args) throws org.apache.thrift.TException {
+ public multipaths_result getResult(I iface, multipaths_args args) throws org.apache.thrift.TException {
multipaths_result result = new multipaths_result();
result.success = iface.multipaths(args.rd, args.maxPath);
result.setSuccessIsSet(true);
}
}
+ public static class enableBFDFailover<I extends Iface> extends org.apache.thrift.ProcessFunction<I, enableBFDFailover_args> {
+ public enableBFDFailover() {
+ super("enableBFDFailover");
+ }
+
+ public enableBFDFailover_args getEmptyArgsInstance() {
+ return new enableBFDFailover_args();
+ }
+
+ protected boolean isOneway() {
+ return false;
+ }
+
+ public enableBFDFailover_result getResult(I iface, enableBFDFailover_args args) throws org.apache.thrift.TException {
+ enableBFDFailover_result result = new enableBFDFailover_result();
+ result.success = iface.enableBFDFailover(args.bfdConfig);
+ result.setSuccessIsSet(true);
+ return result;
+ }
+ }
+
+ public static class disableBFDFailover<I extends Iface> extends org.apache.thrift.ProcessFunction<I, disableBFDFailover_args> {
+ public disableBFDFailover() {
+ super("disableBFDFailover");
+ }
+
+ public disableBFDFailover_args getEmptyArgsInstance() {
+ return new disableBFDFailover_args();
+ }
+
+ protected boolean isOneway() {
+ return false;
+ }
+
+ public disableBFDFailover_result getResult(I iface, disableBFDFailover_args args) throws org.apache.thrift.TException {
+ disableBFDFailover_result result = new disableBFDFailover_result();
+ result.success = iface.disableBFDFailover();
+ result.setSuccessIsSet(true);
+ return result;
+ }
+ }
+
+ public static class getPeerStatus<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getPeerStatus_args> {
+ public getPeerStatus() {
+ super("getPeerStatus");
+ }
+
+ public getPeerStatus_args getEmptyArgsInstance() {
+ return new getPeerStatus_args();
+ }
+
+ protected boolean isOneway() {
+ return false;
+ }
+
+ public getPeerStatus_result getResult(I iface, getPeerStatus_args args) throws org.apache.thrift.TException {
+ getPeerStatus_result result = new getPeerStatus_result();
+ result.success = iface.getPeerStatus(args.ipAddress, args.asNumber);
+ return result;
+ }
+ }
+
}
public static class AsyncProcessor<I extends AsyncIface> extends org.apache.thrift.TBaseAsyncProcessor<I> {
- private static final Logger LOG = LoggerFactory.getLogger(AsyncProcessor.class.getName());
+ private static final Logger LOGGER = LoggerFactory.getLogger(AsyncProcessor.class.getName());
public AsyncProcessor(I iface) {
super(iface, getProcessMap(new HashMap<String, org.apache.thrift.AsyncProcessFunction<I, ? extends org.apache.thrift.TBase, ?>>()));
}
processMap.put("multipaths", new multipaths());
processMap.put("enableEORDelay", new enableEORDelay());
processMap.put("sendEOR", new sendEOR());
+ processMap.put("enableBFDFailover", new enableBFDFailover());
+ processMap.put("disableBFDFailover", new disableBFDFailover());
+ processMap.put("getPeerStatus", new getPeerStatus());
return processMap;
}
super("startBgp");
}
- @Override
- public startBgp_args getEmptyArgsInstance() {
+ public startBgp_args getEmptyArgsInstance() {
return new startBgp_args();
}
- @Override
- public AsyncMethodCallback<Integer> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
+ public AsyncMethodCallback<Integer> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
final org.apache.thrift.AsyncProcessFunction fcall = this;
return new AsyncMethodCallback<Integer>() {
- @Override
- public void onComplete(Integer o) {
+ public void onComplete(Integer o) {
startBgp_result result = new startBgp_result();
result.success = o;
result.setSuccessIsSet(true);
fcall.sendResponse(fb,result, org.apache.thrift.protocol.TMessageType.REPLY,seqid);
return;
} catch (Exception e) {
- LOG.error("Exception writing to internal frame buffer", e);
+ LOGGER.error("Exception writing to internal frame buffer", e);
}
fb.close();
}
- @Override
- public void onError(Exception e) {
+ public void onError(Exception e) {
byte msgType = org.apache.thrift.protocol.TMessageType.REPLY;
org.apache.thrift.TBase msg;
startBgp_result result = new startBgp_result();
fcall.sendResponse(fb,msg,msgType,seqid);
return;
} catch (Exception ex) {
- LOG.error("Exception writing to internal frame buffer", ex);
+ LOGGER.error("Exception writing to internal frame buffer", ex);
}
fb.close();
}
};
}
- @Override
- protected boolean isOneway() {
+ protected boolean isOneway() {
return false;
}
- @Override
- public void start(I iface, startBgp_args args, org.apache.thrift.async.AsyncMethodCallback<Integer> resultHandler) throws TException {
- iface.startBgp(args.asNumber, args.routerId, args.port, args.holdTime, args.keepAliveTime, args.stalepathTime, args.announceFlush,resultHandler);
+ public void start(I iface, startBgp_args args, org.apache.thrift.async.AsyncMethodCallback<Integer> resultHandler) throws TException {
+ iface.startBgp(args.asNumber, args.routerId, args.port, args.holdTime, args.keepAliveTime, args.stalepathTime, args.announceFbit,resultHandler);
}
}
super("stopBgp");
}
- @Override
- public stopBgp_args getEmptyArgsInstance() {
+ public stopBgp_args getEmptyArgsInstance() {
return new stopBgp_args();
}
- @Override
- public AsyncMethodCallback<Integer> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
+ public AsyncMethodCallback<Integer> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
final org.apache.thrift.AsyncProcessFunction fcall = this;
return new AsyncMethodCallback<Integer>() {
- @Override
- public void onComplete(Integer o) {
+ public void onComplete(Integer o) {
stopBgp_result result = new stopBgp_result();
result.success = o;
result.setSuccessIsSet(true);
fcall.sendResponse(fb,result, org.apache.thrift.protocol.TMessageType.REPLY,seqid);
return;
} catch (Exception e) {
- LOG.error("Exception writing to internal frame buffer", e);
+ LOGGER.error("Exception writing to internal frame buffer", e);
}
fb.close();
}
- @Override
- public void onError(Exception e) {
+ public void onError(Exception e) {
byte msgType = org.apache.thrift.protocol.TMessageType.REPLY;
org.apache.thrift.TBase msg;
stopBgp_result result = new stopBgp_result();
fcall.sendResponse(fb,msg,msgType,seqid);
return;
} catch (Exception ex) {
- LOG.error("Exception writing to internal frame buffer", ex);
+ LOGGER.error("Exception writing to internal frame buffer", ex);
}
fb.close();
}
};
}
- @Override
- protected boolean isOneway() {
+ protected boolean isOneway() {
return false;
}
- @Override
- public void start(I iface, stopBgp_args args, org.apache.thrift.async.AsyncMethodCallback<Integer> resultHandler) throws TException {
+ public void start(I iface, stopBgp_args args, org.apache.thrift.async.AsyncMethodCallback<Integer> resultHandler) throws TException {
iface.stopBgp(args.asNumber,resultHandler);
}
}
super("createPeer");
}
- @Override
- public createPeer_args getEmptyArgsInstance() {
+ public createPeer_args getEmptyArgsInstance() {
return new createPeer_args();
}
- @Override
- public AsyncMethodCallback<Integer> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
+ public AsyncMethodCallback<Integer> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
final org.apache.thrift.AsyncProcessFunction fcall = this;
return new AsyncMethodCallback<Integer>() {
- @Override
- public void onComplete(Integer o) {
+ public void onComplete(Integer o) {
createPeer_result result = new createPeer_result();
result.success = o;
result.setSuccessIsSet(true);
fcall.sendResponse(fb,result, org.apache.thrift.protocol.TMessageType.REPLY,seqid);
return;
} catch (Exception e) {
- LOG.error("Exception writing to internal frame buffer", e);
+ LOGGER.error("Exception writing to internal frame buffer", e);
}
fb.close();
}
- @Override
- public void onError(Exception e) {
+ public void onError(Exception e) {
byte msgType = org.apache.thrift.protocol.TMessageType.REPLY;
org.apache.thrift.TBase msg;
createPeer_result result = new createPeer_result();
fcall.sendResponse(fb,msg,msgType,seqid);
return;
} catch (Exception ex) {
- LOG.error("Exception writing to internal frame buffer", ex);
+ LOGGER.error("Exception writing to internal frame buffer", ex);
}
fb.close();
}
};
}
- @Override
- protected boolean isOneway() {
+ protected boolean isOneway() {
return false;
}
- @Override
- public void start(I iface, createPeer_args args, org.apache.thrift.async.AsyncMethodCallback<Integer> resultHandler) throws TException {
+ public void start(I iface, createPeer_args args, org.apache.thrift.async.AsyncMethodCallback<Integer> resultHandler) throws TException {
iface.createPeer(args.ipAddress, args.asNumber,resultHandler);
}
}
super("setPeerSecret");
}
- @Override
- public setPeerSecret_args getEmptyArgsInstance() {
+ public setPeerSecret_args getEmptyArgsInstance() {
return new setPeerSecret_args();
}
- @Override
- public AsyncMethodCallback<Integer> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
+ public AsyncMethodCallback<Integer> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
final org.apache.thrift.AsyncProcessFunction fcall = this;
return new AsyncMethodCallback<Integer>() {
- @Override
- public void onComplete(Integer o) {
+ public void onComplete(Integer o) {
setPeerSecret_result result = new setPeerSecret_result();
result.success = o;
result.setSuccessIsSet(true);
fcall.sendResponse(fb,result, org.apache.thrift.protocol.TMessageType.REPLY,seqid);
return;
} catch (Exception e) {
- LOG.error("Exception writing to internal frame buffer", e);
+ LOGGER.error("Exception writing to internal frame buffer", e);
}
fb.close();
}
- @Override
- public void onError(Exception e) {
+ public void onError(Exception e) {
byte msgType = org.apache.thrift.protocol.TMessageType.REPLY;
org.apache.thrift.TBase msg;
setPeerSecret_result result = new setPeerSecret_result();
fcall.sendResponse(fb,msg,msgType,seqid);
return;
} catch (Exception ex) {
- LOG.error("Exception writing to internal frame buffer", ex);
+ LOGGER.error("Exception writing to internal frame buffer", ex);
}
fb.close();
}
};
}
- @Override
- protected boolean isOneway() {
+ protected boolean isOneway() {
return false;
}
- @Override
- public void start(I iface, setPeerSecret_args args, org.apache.thrift.async.AsyncMethodCallback<Integer> resultHandler) throws TException {
+ public void start(I iface, setPeerSecret_args args, org.apache.thrift.async.AsyncMethodCallback<Integer> resultHandler) throws TException {
iface.setPeerSecret(args.ipAddress, args.rfc2385_sharedSecret,resultHandler);
}
}
super("deletePeer");
}
- @Override
- public deletePeer_args getEmptyArgsInstance() {
+ public deletePeer_args getEmptyArgsInstance() {
return new deletePeer_args();
}
- @Override
- public AsyncMethodCallback<Integer> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
+ public AsyncMethodCallback<Integer> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
final org.apache.thrift.AsyncProcessFunction fcall = this;
return new AsyncMethodCallback<Integer>() {
- @Override
- public void onComplete(Integer o) {
+ public void onComplete(Integer o) {
deletePeer_result result = new deletePeer_result();
result.success = o;
result.setSuccessIsSet(true);
fcall.sendResponse(fb,result, org.apache.thrift.protocol.TMessageType.REPLY,seqid);
return;
} catch (Exception e) {
- LOG.error("Exception writing to internal frame buffer", e);
+ LOGGER.error("Exception writing to internal frame buffer", e);
}
fb.close();
}
- @Override
- public void onError(Exception e) {
+ public void onError(Exception e) {
byte msgType = org.apache.thrift.protocol.TMessageType.REPLY;
org.apache.thrift.TBase msg;
deletePeer_result result = new deletePeer_result();
fcall.sendResponse(fb,msg,msgType,seqid);
return;
} catch (Exception ex) {
- LOG.error("Exception writing to internal frame buffer", ex);
+ LOGGER.error("Exception writing to internal frame buffer", ex);
}
fb.close();
}
};
}
- @Override
- protected boolean isOneway() {
+ protected boolean isOneway() {
return false;
}
- @Override
- public void start(I iface, deletePeer_args args, org.apache.thrift.async.AsyncMethodCallback<Integer> resultHandler) throws TException {
+ public void start(I iface, deletePeer_args args, org.apache.thrift.async.AsyncMethodCallback<Integer> resultHandler) throws TException {
iface.deletePeer(args.ipAddress,resultHandler);
}
}
super("addVrf");
}
- @Override
- public addVrf_args getEmptyArgsInstance() {
+ public addVrf_args getEmptyArgsInstance() {
return new addVrf_args();
}
- @Override
- public AsyncMethodCallback<Integer> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
+ public AsyncMethodCallback<Integer> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
final org.apache.thrift.AsyncProcessFunction fcall = this;
return new AsyncMethodCallback<Integer>() {
- @Override
- public void onComplete(Integer o) {
+ public void onComplete(Integer o) {
addVrf_result result = new addVrf_result();
result.success = o;
result.setSuccessIsSet(true);
fcall.sendResponse(fb,result, org.apache.thrift.protocol.TMessageType.REPLY,seqid);
return;
} catch (Exception e) {
- LOG.error("Exception writing to internal frame buffer", e);
+ LOGGER.error("Exception writing to internal frame buffer", e);
}
fb.close();
}
- @Override
- public void onError(Exception e) {
+ public void onError(Exception e) {
byte msgType = org.apache.thrift.protocol.TMessageType.REPLY;
org.apache.thrift.TBase msg;
addVrf_result result = new addVrf_result();
fcall.sendResponse(fb,msg,msgType,seqid);
return;
} catch (Exception ex) {
- LOG.error("Exception writing to internal frame buffer", ex);
+ LOGGER.error("Exception writing to internal frame buffer", ex);
}
fb.close();
}
};
}
- @Override
- protected boolean isOneway() {
+ protected boolean isOneway() {
return false;
}
- @Override
- public void start(I iface, addVrf_args args, org.apache.thrift.async.AsyncMethodCallback<Integer> resultHandler) throws TException {
+ public void start(I iface, addVrf_args args, org.apache.thrift.async.AsyncMethodCallback<Integer> resultHandler) throws TException {
iface.addVrf(args.l_type, args.rd, args.irts, args.erts, args.afi, args.safi,resultHandler);
}
}
super("delVrf");
}
- @Override
- public delVrf_args getEmptyArgsInstance() {
+ public delVrf_args getEmptyArgsInstance() {
return new delVrf_args();
}
- @Override
- public AsyncMethodCallback<Integer> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
+ public AsyncMethodCallback<Integer> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
final org.apache.thrift.AsyncProcessFunction fcall = this;
return new AsyncMethodCallback<Integer>() {
- @Override
- public void onComplete(Integer o) {
+ public void onComplete(Integer o) {
delVrf_result result = new delVrf_result();
result.success = o;
result.setSuccessIsSet(true);
fcall.sendResponse(fb,result, org.apache.thrift.protocol.TMessageType.REPLY,seqid);
return;
} catch (Exception e) {
- LOG.error("Exception writing to internal frame buffer", e);
+ LOGGER.error("Exception writing to internal frame buffer", e);
}
fb.close();
}
- @Override
- public void onError(Exception e) {
+ public void onError(Exception e) {
byte msgType = org.apache.thrift.protocol.TMessageType.REPLY;
org.apache.thrift.TBase msg;
delVrf_result result = new delVrf_result();
fcall.sendResponse(fb,msg,msgType,seqid);
return;
} catch (Exception ex) {
- LOG.error("Exception writing to internal frame buffer", ex);
+ LOGGER.error("Exception writing to internal frame buffer", ex);
}
fb.close();
}
};
}
- @Override
- protected boolean isOneway() {
+ protected boolean isOneway() {
return false;
}
- @Override
- public void start(I iface, delVrf_args args, org.apache.thrift.async.AsyncMethodCallback<Integer> resultHandler) throws TException {
+ public void start(I iface, delVrf_args args, org.apache.thrift.async.AsyncMethodCallback<Integer> resultHandler) throws TException {
iface.delVrf(args.rd, args.afi, args.safi,resultHandler);
}
}
super("pushRoute");
}
- @Override
- public pushRoute_args getEmptyArgsInstance() {
+ public pushRoute_args getEmptyArgsInstance() {
return new pushRoute_args();
}
- @Override
- public AsyncMethodCallback<Integer> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
+ public AsyncMethodCallback<Integer> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
final org.apache.thrift.AsyncProcessFunction fcall = this;
return new AsyncMethodCallback<Integer>() {
- @Override
- public void onComplete(Integer o) {
+ public void onComplete(Integer o) {
pushRoute_result result = new pushRoute_result();
result.success = o;
result.setSuccessIsSet(true);
fcall.sendResponse(fb,result, org.apache.thrift.protocol.TMessageType.REPLY,seqid);
return;
} catch (Exception e) {
- LOG.error("Exception writing to internal frame buffer", e);
+ LOGGER.error("Exception writing to internal frame buffer", e);
}
fb.close();
}
- @Override
- public void onError(Exception e) {
+ public void onError(Exception e) {
byte msgType = org.apache.thrift.protocol.TMessageType.REPLY;
org.apache.thrift.TBase msg;
pushRoute_result result = new pushRoute_result();
fcall.sendResponse(fb,msg,msgType,seqid);
return;
} catch (Exception ex) {
- LOG.error("Exception writing to internal frame buffer", ex);
+ LOGGER.error("Exception writing to internal frame buffer", ex);
}
fb.close();
}
};
}
- @Override
- protected boolean isOneway() {
+ protected boolean isOneway() {
return false;
}
- @Override
- public void start(I iface, pushRoute_args args, org.apache.thrift.async.AsyncMethodCallback<Integer> resultHandler) throws TException {
+ public void start(I iface, pushRoute_args args, org.apache.thrift.async.AsyncMethodCallback<Integer> resultHandler) throws TException {
iface.pushRoute(args.p_type, args.prefix, args.nexthop, args.rd, args.ethtag, args.esi, args.macaddress, args.l3label, args.l2label, args.enc_type, args.routermac, args.afi,resultHandler);
}
}
super("withdrawRoute");
}
- @Override
- public withdrawRoute_args getEmptyArgsInstance() {
+ public withdrawRoute_args getEmptyArgsInstance() {
return new withdrawRoute_args();
}
- @Override
- public AsyncMethodCallback<Integer> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
+ public AsyncMethodCallback<Integer> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
final org.apache.thrift.AsyncProcessFunction fcall = this;
return new AsyncMethodCallback<Integer>() {
- @Override
- public void onComplete(Integer o) {
+ public void onComplete(Integer o) {
withdrawRoute_result result = new withdrawRoute_result();
result.success = o;
result.setSuccessIsSet(true);
fcall.sendResponse(fb,result, org.apache.thrift.protocol.TMessageType.REPLY,seqid);
return;
} catch (Exception e) {
- LOG.error("Exception writing to internal frame buffer", e);
+ LOGGER.error("Exception writing to internal frame buffer", e);
}
fb.close();
}
- @Override
- public void onError(Exception e) {
+ public void onError(Exception e) {
byte msgType = org.apache.thrift.protocol.TMessageType.REPLY;
org.apache.thrift.TBase msg;
withdrawRoute_result result = new withdrawRoute_result();
fcall.sendResponse(fb,msg,msgType,seqid);
return;
} catch (Exception ex) {
- LOG.error("Exception writing to internal frame buffer", ex);
+ LOGGER.error("Exception writing to internal frame buffer", ex);
}
fb.close();
}
};
}
- @Override
- protected boolean isOneway() {
+ protected boolean isOneway() {
return false;
}
- @Override
- public void start(I iface, withdrawRoute_args args, org.apache.thrift.async.AsyncMethodCallback<Integer> resultHandler) throws TException {
+ public void start(I iface, withdrawRoute_args args, org.apache.thrift.async.AsyncMethodCallback<Integer> resultHandler) throws TException {
iface.withdrawRoute(args.p_type, args.prefix, args.rd, args.ethtag, args.esi, args.macaddress, args.afi,resultHandler);
}
}
super("setEbgpMultihop");
}
- @Override
- public setEbgpMultihop_args getEmptyArgsInstance() {
+ public setEbgpMultihop_args getEmptyArgsInstance() {
return new setEbgpMultihop_args();
}
- @Override
- public AsyncMethodCallback<Integer> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
+ public AsyncMethodCallback<Integer> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
final org.apache.thrift.AsyncProcessFunction fcall = this;
return new AsyncMethodCallback<Integer>() {
- @Override
- public void onComplete(Integer o) {
+ public void onComplete(Integer o) {
setEbgpMultihop_result result = new setEbgpMultihop_result();
result.success = o;
result.setSuccessIsSet(true);
fcall.sendResponse(fb,result, org.apache.thrift.protocol.TMessageType.REPLY,seqid);
return;
} catch (Exception e) {
- LOG.error("Exception writing to internal frame buffer", e);
+ LOGGER.error("Exception writing to internal frame buffer", e);
}
fb.close();
}
- @Override
- public void onError(Exception e) {
+ public void onError(Exception e) {
byte msgType = org.apache.thrift.protocol.TMessageType.REPLY;
org.apache.thrift.TBase msg;
setEbgpMultihop_result result = new setEbgpMultihop_result();
fcall.sendResponse(fb,msg,msgType,seqid);
return;
} catch (Exception ex) {
- LOG.error("Exception writing to internal frame buffer", ex);
+ LOGGER.error("Exception writing to internal frame buffer", ex);
}
fb.close();
}
};
}
- @Override
- protected boolean isOneway() {
+ protected boolean isOneway() {
return false;
}
- @Override
- public void start(I iface, setEbgpMultihop_args args, org.apache.thrift.async.AsyncMethodCallback<Integer> resultHandler) throws TException {
+ public void start(I iface, setEbgpMultihop_args args, org.apache.thrift.async.AsyncMethodCallback<Integer> resultHandler) throws TException {
iface.setEbgpMultihop(args.peerIp, args.nHops,resultHandler);
}
}
super("unsetEbgpMultihop");
}
- @Override
- public unsetEbgpMultihop_args getEmptyArgsInstance() {
+ public unsetEbgpMultihop_args getEmptyArgsInstance() {
return new unsetEbgpMultihop_args();
}
- @Override
- public AsyncMethodCallback<Integer> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
+ public AsyncMethodCallback<Integer> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
final org.apache.thrift.AsyncProcessFunction fcall = this;
return new AsyncMethodCallback<Integer>() {
- @Override
- public void onComplete(Integer o) {
+ public void onComplete(Integer o) {
unsetEbgpMultihop_result result = new unsetEbgpMultihop_result();
result.success = o;
result.setSuccessIsSet(true);
fcall.sendResponse(fb,result, org.apache.thrift.protocol.TMessageType.REPLY,seqid);
return;
} catch (Exception e) {
- LOG.error("Exception writing to internal frame buffer", e);
+ LOGGER.error("Exception writing to internal frame buffer", e);
}
fb.close();
}
- @Override
- public void onError(Exception e) {
+ public void onError(Exception e) {
byte msgType = org.apache.thrift.protocol.TMessageType.REPLY;
org.apache.thrift.TBase msg;
unsetEbgpMultihop_result result = new unsetEbgpMultihop_result();
fcall.sendResponse(fb,msg,msgType,seqid);
return;
} catch (Exception ex) {
- LOG.error("Exception writing to internal frame buffer", ex);
+ LOGGER.error("Exception writing to internal frame buffer", ex);
}
fb.close();
}
};
}
- @Override
- protected boolean isOneway() {
+ protected boolean isOneway() {
return false;
}
- @Override
- public void start(I iface, unsetEbgpMultihop_args args, org.apache.thrift.async.AsyncMethodCallback<Integer> resultHandler) throws TException {
+ public void start(I iface, unsetEbgpMultihop_args args, org.apache.thrift.async.AsyncMethodCallback<Integer> resultHandler) throws TException {
iface.unsetEbgpMultihop(args.peerIp,resultHandler);
}
}
super("setUpdateSource");
}
- @Override
- public setUpdateSource_args getEmptyArgsInstance() {
+ public setUpdateSource_args getEmptyArgsInstance() {
return new setUpdateSource_args();
}
- @Override
- public AsyncMethodCallback<Integer> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
+ public AsyncMethodCallback<Integer> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
final org.apache.thrift.AsyncProcessFunction fcall = this;
return new AsyncMethodCallback<Integer>() {
- @Override
- public void onComplete(Integer o) {
+ public void onComplete(Integer o) {
setUpdateSource_result result = new setUpdateSource_result();
result.success = o;
result.setSuccessIsSet(true);
fcall.sendResponse(fb,result, org.apache.thrift.protocol.TMessageType.REPLY,seqid);
return;
} catch (Exception e) {
- LOG.error("Exception writing to internal frame buffer", e);
+ LOGGER.error("Exception writing to internal frame buffer", e);
}
fb.close();
}
- @Override
- public void onError(Exception e) {
+ public void onError(Exception e) {
byte msgType = org.apache.thrift.protocol.TMessageType.REPLY;
org.apache.thrift.TBase msg;
setUpdateSource_result result = new setUpdateSource_result();
fcall.sendResponse(fb,msg,msgType,seqid);
return;
} catch (Exception ex) {
- LOG.error("Exception writing to internal frame buffer", ex);
+ LOGGER.error("Exception writing to internal frame buffer", ex);
}
fb.close();
}
};
}
- @Override
- protected boolean isOneway() {
+ protected boolean isOneway() {
return false;
}
- @Override
- public void start(I iface, setUpdateSource_args args, org.apache.thrift.async.AsyncMethodCallback<Integer> resultHandler) throws TException {
+ public void start(I iface, setUpdateSource_args args, org.apache.thrift.async.AsyncMethodCallback<Integer> resultHandler) throws TException {
iface.setUpdateSource(args.peerIp, args.srcIp,resultHandler);
}
}
super("unsetUpdateSource");
}
- @Override
- public unsetUpdateSource_args getEmptyArgsInstance() {
+ public unsetUpdateSource_args getEmptyArgsInstance() {
return new unsetUpdateSource_args();
}
- @Override
- public AsyncMethodCallback<Integer> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
+ public AsyncMethodCallback<Integer> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
final org.apache.thrift.AsyncProcessFunction fcall = this;
return new AsyncMethodCallback<Integer>() {
- @Override
- public void onComplete(Integer o) {
+ public void onComplete(Integer o) {
unsetUpdateSource_result result = new unsetUpdateSource_result();
result.success = o;
result.setSuccessIsSet(true);
fcall.sendResponse(fb,result, org.apache.thrift.protocol.TMessageType.REPLY,seqid);
return;
} catch (Exception e) {
- LOG.error("Exception writing to internal frame buffer", e);
+ LOGGER.error("Exception writing to internal frame buffer", e);
}
fb.close();
}
- @Override
- public void onError(Exception e) {
+ public void onError(Exception e) {
byte msgType = org.apache.thrift.protocol.TMessageType.REPLY;
org.apache.thrift.TBase msg;
unsetUpdateSource_result result = new unsetUpdateSource_result();
fcall.sendResponse(fb,msg,msgType,seqid);
return;
} catch (Exception ex) {
- LOG.error("Exception writing to internal frame buffer", ex);
+ LOGGER.error("Exception writing to internal frame buffer", ex);
}
fb.close();
}
};
}
- @Override
- protected boolean isOneway() {
+ protected boolean isOneway() {
return false;
}
- @Override
- public void start(I iface, unsetUpdateSource_args args, org.apache.thrift.async.AsyncMethodCallback<Integer> resultHandler) throws TException {
+ public void start(I iface, unsetUpdateSource_args args, org.apache.thrift.async.AsyncMethodCallback<Integer> resultHandler) throws TException {
iface.unsetUpdateSource(args.peerIp,resultHandler);
}
}
super("enableAddressFamily");
}
- @Override
- public enableAddressFamily_args getEmptyArgsInstance() {
+ public enableAddressFamily_args getEmptyArgsInstance() {
return new enableAddressFamily_args();
}
- @Override
- public AsyncMethodCallback<Integer> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
+ public AsyncMethodCallback<Integer> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
final org.apache.thrift.AsyncProcessFunction fcall = this;
return new AsyncMethodCallback<Integer>() {
- @Override
- public void onComplete(Integer o) {
+ public void onComplete(Integer o) {
enableAddressFamily_result result = new enableAddressFamily_result();
result.success = o;
result.setSuccessIsSet(true);
fcall.sendResponse(fb,result, org.apache.thrift.protocol.TMessageType.REPLY,seqid);
return;
} catch (Exception e) {
- LOG.error("Exception writing to internal frame buffer", e);
+ LOGGER.error("Exception writing to internal frame buffer", e);
}
fb.close();
}
- @Override
- public void onError(Exception e) {
+ public void onError(Exception e) {
byte msgType = org.apache.thrift.protocol.TMessageType.REPLY;
org.apache.thrift.TBase msg;
enableAddressFamily_result result = new enableAddressFamily_result();
fcall.sendResponse(fb,msg,msgType,seqid);
return;
} catch (Exception ex) {
- LOG.error("Exception writing to internal frame buffer", ex);
+ LOGGER.error("Exception writing to internal frame buffer", ex);
}
fb.close();
}
};
}
- @Override
- protected boolean isOneway() {
+ protected boolean isOneway() {
return false;
}
- @Override
- public void start(I iface, enableAddressFamily_args args, org.apache.thrift.async.AsyncMethodCallback<Integer> resultHandler) throws TException {
+ public void start(I iface, enableAddressFamily_args args, org.apache.thrift.async.AsyncMethodCallback<Integer> resultHandler) throws TException {
iface.enableAddressFamily(args.peerIp, args.afi, args.safi,resultHandler);
}
}
super("disableAddressFamily");
}
- @Override
- public disableAddressFamily_args getEmptyArgsInstance() {
+ public disableAddressFamily_args getEmptyArgsInstance() {
return new disableAddressFamily_args();
}
- @Override
- public AsyncMethodCallback<Integer> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
+ public AsyncMethodCallback<Integer> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
final org.apache.thrift.AsyncProcessFunction fcall = this;
return new AsyncMethodCallback<Integer>() {
- @Override
- public void onComplete(Integer o) {
+ public void onComplete(Integer o) {
disableAddressFamily_result result = new disableAddressFamily_result();
result.success = o;
result.setSuccessIsSet(true);
fcall.sendResponse(fb,result, org.apache.thrift.protocol.TMessageType.REPLY,seqid);
return;
} catch (Exception e) {
- LOG.error("Exception writing to internal frame buffer", e);
+ LOGGER.error("Exception writing to internal frame buffer", e);
}
fb.close();
}
- @Override
- public void onError(Exception e) {
+ public void onError(Exception e) {
byte msgType = org.apache.thrift.protocol.TMessageType.REPLY;
org.apache.thrift.TBase msg;
disableAddressFamily_result result = new disableAddressFamily_result();
fcall.sendResponse(fb,msg,msgType,seqid);
return;
} catch (Exception ex) {
- LOG.error("Exception writing to internal frame buffer", ex);
+ LOGGER.error("Exception writing to internal frame buffer", ex);
}
fb.close();
}
};
}
- @Override
- protected boolean isOneway() {
+ protected boolean isOneway() {
return false;
}
- @Override
- public void start(I iface, disableAddressFamily_args args, org.apache.thrift.async.AsyncMethodCallback<Integer> resultHandler) throws TException {
+ public void start(I iface, disableAddressFamily_args args, org.apache.thrift.async.AsyncMethodCallback<Integer> resultHandler) throws TException {
iface.disableAddressFamily(args.peerIp, args.afi, args.safi,resultHandler);
}
}
super("setLogConfig");
}
- @Override
- public setLogConfig_args getEmptyArgsInstance() {
+ public setLogConfig_args getEmptyArgsInstance() {
return new setLogConfig_args();
}
- @Override
- public AsyncMethodCallback<Integer> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
+ public AsyncMethodCallback<Integer> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
final org.apache.thrift.AsyncProcessFunction fcall = this;
return new AsyncMethodCallback<Integer>() {
- @Override
- public void onComplete(Integer o) {
+ public void onComplete(Integer o) {
setLogConfig_result result = new setLogConfig_result();
result.success = o;
result.setSuccessIsSet(true);
fcall.sendResponse(fb,result, org.apache.thrift.protocol.TMessageType.REPLY,seqid);
return;
} catch (Exception e) {
- LOG.error("Exception writing to internal frame buffer", e);
+ LOGGER.error("Exception writing to internal frame buffer", e);
}
fb.close();
}
- @Override
- public void onError(Exception e) {
+ public void onError(Exception e) {
byte msgType = org.apache.thrift.protocol.TMessageType.REPLY;
org.apache.thrift.TBase msg;
setLogConfig_result result = new setLogConfig_result();
fcall.sendResponse(fb,msg,msgType,seqid);
return;
} catch (Exception ex) {
- LOG.error("Exception writing to internal frame buffer", ex);
+ LOGGER.error("Exception writing to internal frame buffer", ex);
}
fb.close();
}
};
}
- @Override
- protected boolean isOneway() {
+ protected boolean isOneway() {
return false;
}
- @Override
- public void start(I iface, setLogConfig_args args, org.apache.thrift.async.AsyncMethodCallback<Integer> resultHandler) throws TException {
+ public void start(I iface, setLogConfig_args args, org.apache.thrift.async.AsyncMethodCallback<Integer> resultHandler) throws TException {
iface.setLogConfig(args.logFileName, args.logLevel,resultHandler);
}
}
super("enableGracefulRestart");
}
- @Override
- public enableGracefulRestart_args getEmptyArgsInstance() {
+ public enableGracefulRestart_args getEmptyArgsInstance() {
return new enableGracefulRestart_args();
}
- @Override
- public AsyncMethodCallback<Integer> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
+ public AsyncMethodCallback<Integer> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
final org.apache.thrift.AsyncProcessFunction fcall = this;
return new AsyncMethodCallback<Integer>() {
- @Override
- public void onComplete(Integer o) {
+ public void onComplete(Integer o) {
enableGracefulRestart_result result = new enableGracefulRestart_result();
result.success = o;
result.setSuccessIsSet(true);
fcall.sendResponse(fb,result, org.apache.thrift.protocol.TMessageType.REPLY,seqid);
return;
} catch (Exception e) {
- LOG.error("Exception writing to internal frame buffer", e);
+ LOGGER.error("Exception writing to internal frame buffer", e);
}
fb.close();
}
- @Override
- public void onError(Exception e) {
+ public void onError(Exception e) {
byte msgType = org.apache.thrift.protocol.TMessageType.REPLY;
org.apache.thrift.TBase msg;
enableGracefulRestart_result result = new enableGracefulRestart_result();
fcall.sendResponse(fb,msg,msgType,seqid);
return;
} catch (Exception ex) {
- LOG.error("Exception writing to internal frame buffer", ex);
+ LOGGER.error("Exception writing to internal frame buffer", ex);
}
fb.close();
}
};
}
- @Override
- protected boolean isOneway() {
+ protected boolean isOneway() {
return false;
}
- @Override
- public void start(I iface, enableGracefulRestart_args args, org.apache.thrift.async.AsyncMethodCallback<Integer> resultHandler) throws TException {
+ public void start(I iface, enableGracefulRestart_args args, org.apache.thrift.async.AsyncMethodCallback<Integer> resultHandler) throws TException {
iface.enableGracefulRestart(args.stalepathTime,resultHandler);
}
}
super("disableGracefulRestart");
}
- @Override
- public disableGracefulRestart_args getEmptyArgsInstance() {
+ public disableGracefulRestart_args getEmptyArgsInstance() {
return new disableGracefulRestart_args();
}
- @Override
- public AsyncMethodCallback<Integer> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
+ public AsyncMethodCallback<Integer> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
final org.apache.thrift.AsyncProcessFunction fcall = this;
return new AsyncMethodCallback<Integer>() {
- @Override
- public void onComplete(Integer o) {
+ public void onComplete(Integer o) {
disableGracefulRestart_result result = new disableGracefulRestart_result();
result.success = o;
result.setSuccessIsSet(true);
fcall.sendResponse(fb,result, org.apache.thrift.protocol.TMessageType.REPLY,seqid);
return;
} catch (Exception e) {
- LOG.error("Exception writing to internal frame buffer", e);
+ LOGGER.error("Exception writing to internal frame buffer", e);
}
fb.close();
}
- @Override
- public void onError(Exception e) {
+ public void onError(Exception e) {
byte msgType = org.apache.thrift.protocol.TMessageType.REPLY;
org.apache.thrift.TBase msg;
disableGracefulRestart_result result = new disableGracefulRestart_result();
fcall.sendResponse(fb,msg,msgType,seqid);
return;
} catch (Exception ex) {
- LOG.error("Exception writing to internal frame buffer", ex);
+ LOGGER.error("Exception writing to internal frame buffer", ex);
}
fb.close();
}
};
}
- @Override
- protected boolean isOneway() {
+ protected boolean isOneway() {
return false;
}
- @Override
- public void start(I iface, disableGracefulRestart_args args, org.apache.thrift.async.AsyncMethodCallback<Integer> resultHandler) throws TException {
+ public void start(I iface, disableGracefulRestart_args args, org.apache.thrift.async.AsyncMethodCallback<Integer> resultHandler) throws TException {
iface.disableGracefulRestart(resultHandler);
}
}
super("getRoutes");
}
- @Override
- public getRoutes_args getEmptyArgsInstance() {
+ public getRoutes_args getEmptyArgsInstance() {
return new getRoutes_args();
}
- @Override
- public AsyncMethodCallback<Routes> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
+ public AsyncMethodCallback<Routes> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
final org.apache.thrift.AsyncProcessFunction fcall = this;
return new AsyncMethodCallback<Routes>() {
- @Override
- public void onComplete(Routes o) {
+ public void onComplete(Routes o) {
getRoutes_result result = new getRoutes_result();
result.success = o;
try {
fcall.sendResponse(fb,result, org.apache.thrift.protocol.TMessageType.REPLY,seqid);
return;
} catch (Exception e) {
- LOG.error("Exception writing to internal frame buffer", e);
+ LOGGER.error("Exception writing to internal frame buffer", e);
}
fb.close();
}
- @Override
- public void onError(Exception e) {
+ public void onError(Exception e) {
byte msgType = org.apache.thrift.protocol.TMessageType.REPLY;
org.apache.thrift.TBase msg;
getRoutes_result result = new getRoutes_result();
fcall.sendResponse(fb,msg,msgType,seqid);
return;
} catch (Exception ex) {
- LOG.error("Exception writing to internal frame buffer", ex);
+ LOGGER.error("Exception writing to internal frame buffer", ex);
}
fb.close();
}
};
}
- @Override
- protected boolean isOneway() {
+ protected boolean isOneway() {
return false;
}
- @Override
- public void start(I iface, getRoutes_args args, org.apache.thrift.async.AsyncMethodCallback<Routes> resultHandler) throws TException {
+ public void start(I iface, getRoutes_args args, org.apache.thrift.async.AsyncMethodCallback<Routes> resultHandler) throws TException {
iface.getRoutes(args.p_type, args.optype, args.winSize, args.afi,resultHandler);
}
}
super("enableMultipath");
}
- @Override
- public enableMultipath_args getEmptyArgsInstance() {
+ public enableMultipath_args getEmptyArgsInstance() {
return new enableMultipath_args();
}
- @Override
- public AsyncMethodCallback<Integer> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
+ public AsyncMethodCallback<Integer> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
final org.apache.thrift.AsyncProcessFunction fcall = this;
return new AsyncMethodCallback<Integer>() {
- @Override
- public void onComplete(Integer o) {
+ public void onComplete(Integer o) {
enableMultipath_result result = new enableMultipath_result();
result.success = o;
result.setSuccessIsSet(true);
fcall.sendResponse(fb,result, org.apache.thrift.protocol.TMessageType.REPLY,seqid);
return;
} catch (Exception e) {
- LOG.error("Exception writing to internal frame buffer", e);
+ LOGGER.error("Exception writing to internal frame buffer", e);
}
fb.close();
}
- @Override
- public void onError(Exception e) {
+ public void onError(Exception e) {
byte msgType = org.apache.thrift.protocol.TMessageType.REPLY;
org.apache.thrift.TBase msg;
enableMultipath_result result = new enableMultipath_result();
fcall.sendResponse(fb,msg,msgType,seqid);
return;
} catch (Exception ex) {
- LOG.error("Exception writing to internal frame buffer", ex);
+ LOGGER.error("Exception writing to internal frame buffer", ex);
}
fb.close();
}
};
}
- @Override
- protected boolean isOneway() {
+ protected boolean isOneway() {
return false;
}
- @Override
- public void start(I iface, enableMultipath_args args, org.apache.thrift.async.AsyncMethodCallback<Integer> resultHandler) throws TException {
+ public void start(I iface, enableMultipath_args args, org.apache.thrift.async.AsyncMethodCallback<Integer> resultHandler) throws TException {
iface.enableMultipath(args.afi, args.safi,resultHandler);
}
}
super("disableMultipath");
}
- @Override
- public disableMultipath_args getEmptyArgsInstance() {
+ public disableMultipath_args getEmptyArgsInstance() {
return new disableMultipath_args();
}
- @Override
- public AsyncMethodCallback<Integer> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
+ public AsyncMethodCallback<Integer> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
final org.apache.thrift.AsyncProcessFunction fcall = this;
return new AsyncMethodCallback<Integer>() {
- @Override
- public void onComplete(Integer o) {
+ public void onComplete(Integer o) {
disableMultipath_result result = new disableMultipath_result();
result.success = o;
result.setSuccessIsSet(true);
fcall.sendResponse(fb,result, org.apache.thrift.protocol.TMessageType.REPLY,seqid);
return;
} catch (Exception e) {
- LOG.error("Exception writing to internal frame buffer", e);
+ LOGGER.error("Exception writing to internal frame buffer", e);
}
fb.close();
}
- @Override
- public void onError(Exception e) {
+ public void onError(Exception e) {
byte msgType = org.apache.thrift.protocol.TMessageType.REPLY;
org.apache.thrift.TBase msg;
disableMultipath_result result = new disableMultipath_result();
fcall.sendResponse(fb,msg,msgType,seqid);
return;
} catch (Exception ex) {
- LOG.error("Exception writing to internal frame buffer", ex);
+ LOGGER.error("Exception writing to internal frame buffer", ex);
}
fb.close();
}
};
}
- @Override
- protected boolean isOneway() {
+ protected boolean isOneway() {
return false;
}
- @Override
- public void start(I iface, disableMultipath_args args, org.apache.thrift.async.AsyncMethodCallback<Integer> resultHandler) throws TException {
+ public void start(I iface, disableMultipath_args args, org.apache.thrift.async.AsyncMethodCallback<Integer> resultHandler) throws TException {
iface.disableMultipath(args.afi, args.safi,resultHandler);
}
}
super("multipaths");
}
- @Override
- public multipaths_args getEmptyArgsInstance() {
+ public multipaths_args getEmptyArgsInstance() {
return new multipaths_args();
}
- @Override
- public AsyncMethodCallback<Integer> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
+ public AsyncMethodCallback<Integer> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
final org.apache.thrift.AsyncProcessFunction fcall = this;
return new AsyncMethodCallback<Integer>() {
- @Override
- public void onComplete(Integer o) {
+ public void onComplete(Integer o) {
multipaths_result result = new multipaths_result();
result.success = o;
result.setSuccessIsSet(true);
fcall.sendResponse(fb,result, org.apache.thrift.protocol.TMessageType.REPLY,seqid);
return;
} catch (Exception e) {
- LOG.error("Exception writing to internal frame buffer", e);
+ LOGGER.error("Exception writing to internal frame buffer", e);
}
fb.close();
}
- @Override
- public void onError(Exception e) {
+ public void onError(Exception e) {
byte msgType = org.apache.thrift.protocol.TMessageType.REPLY;
org.apache.thrift.TBase msg;
multipaths_result result = new multipaths_result();
fcall.sendResponse(fb,msg,msgType,seqid);
return;
} catch (Exception ex) {
- LOG.error("Exception writing to internal frame buffer", ex);
+ LOGGER.error("Exception writing to internal frame buffer", ex);
}
fb.close();
}
};
}
- @Override
- protected boolean isOneway() {
+ protected boolean isOneway() {
return false;
}
- @Override
- public void start(I iface, multipaths_args args, org.apache.thrift.async.AsyncMethodCallback<Integer> resultHandler) throws TException {
+ public void start(I iface, multipaths_args args, org.apache.thrift.async.AsyncMethodCallback<Integer> resultHandler) throws TException {
iface.multipaths(args.rd, args.maxPath,resultHandler);
}
}
public AsyncMethodCallback<Integer> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
final org.apache.thrift.AsyncProcessFunction fcall = this;
return new AsyncMethodCallback<Integer>() {
- @Override
- public void onComplete(Integer o) {
+ public void onComplete(Integer o) {
enableEORDelay_result result = new enableEORDelay_result();
result.success = o;
result.setSuccessIsSet(true);
try {
- fcall.sendResponse(fb, result, org.apache.thrift.protocol.TMessageType.REPLY,seqid);
+ fcall.sendResponse(fb,result, org.apache.thrift.protocol.TMessageType.REPLY,seqid);
return;
} catch (Exception e) {
- LOG.error("Exception writing to internal frame buffer", e);
+ LOGGER.error("Exception writing to internal frame buffer", e);
}
fb.close();
}
- @Override
- public void onError(Exception e) {
+ public void onError(Exception e) {
byte msgType = org.apache.thrift.protocol.TMessageType.REPLY;
org.apache.thrift.TBase msg;
enableEORDelay_result result = new enableEORDelay_result();
fcall.sendResponse(fb,msg,msgType,seqid);
return;
} catch (Exception ex) {
- LOG.error("Exception writing to internal frame buffer", ex);
+ LOGGER.error("Exception writing to internal frame buffer", ex);
}
fb.close();
}
return false;
}
- public void start(I iface, enableEORDelay_args args, org.apache.thrift.async.AsyncMethodCallback<Integer> resultHandler) throws org.apache.thrift.TException {
+ public void start(I iface, enableEORDelay_args args, org.apache.thrift.async.AsyncMethodCallback<Integer> resultHandler) throws TException {
iface.enableEORDelay(args.delay,resultHandler);
}
}
public AsyncMethodCallback<Integer> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
final org.apache.thrift.AsyncProcessFunction fcall = this;
return new AsyncMethodCallback<Integer>() {
- @Override
- public void onComplete(Integer o) {
+ public void onComplete(Integer o) {
sendEOR_result result = new sendEOR_result();
result.success = o;
result.setSuccessIsSet(true);
try {
- fcall.sendResponse(fb, result, org.apache.thrift.protocol.TMessageType.REPLY,seqid);
+ fcall.sendResponse(fb,result, org.apache.thrift.protocol.TMessageType.REPLY,seqid);
return;
} catch (Exception e) {
- LOG.error("Exception writing to internal frame buffer", e);
+ LOGGER.error("Exception writing to internal frame buffer", e);
}
fb.close();
}
- @Override
- public void onError(Exception e) {
+ public void onError(Exception e) {
byte msgType = org.apache.thrift.protocol.TMessageType.REPLY;
org.apache.thrift.TBase msg;
sendEOR_result result = new sendEOR_result();
fcall.sendResponse(fb,msg,msgType,seqid);
return;
} catch (Exception ex) {
- LOG.error("Exception writing to internal frame buffer", ex);
+ LOGGER.error("Exception writing to internal frame buffer", ex);
}
fb.close();
}
return false;
}
- public void start(I iface, sendEOR_args args, org.apache.thrift.async.AsyncMethodCallback<Integer> resultHandler) throws org.apache.thrift.TException {
+ public void start(I iface, sendEOR_args args, org.apache.thrift.async.AsyncMethodCallback<Integer> resultHandler) throws TException {
iface.sendEOR(resultHandler);
}
}
- }
-
- public static class startBgp_args implements org.apache.thrift.TBase<startBgp_args, startBgp_args._Fields>, java.io.Serializable, Cloneable, Comparable<startBgp_args> {
- private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("startBgp_args");
-
- private static final org.apache.thrift.protocol.TField AS_NUMBER_FIELD_DESC = new org.apache.thrift.protocol.TField("asNumber", org.apache.thrift.protocol.TType.I64, (short)1);
- private static final org.apache.thrift.protocol.TField ROUTER_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("routerId", org.apache.thrift.protocol.TType.STRING, (short)2);
- private static final org.apache.thrift.protocol.TField PORT_FIELD_DESC = new org.apache.thrift.protocol.TField("port", org.apache.thrift.protocol.TType.I32, (short)3);
- private static final org.apache.thrift.protocol.TField HOLD_TIME_FIELD_DESC = new org.apache.thrift.protocol.TField("holdTime", org.apache.thrift.protocol.TType.I32, (short)4);
- private static final org.apache.thrift.protocol.TField KEEP_ALIVE_TIME_FIELD_DESC = new org.apache.thrift.protocol.TField("keepAliveTime", org.apache.thrift.protocol.TType.I32, (short)5);
- private static final org.apache.thrift.protocol.TField STALEPATH_TIME_FIELD_DESC = new org.apache.thrift.protocol.TField("stalepathTime", org.apache.thrift.protocol.TType.I32, (short)6);
- private static final org.apache.thrift.protocol.TField ANNOUNCE_FLUSH_FIELD_DESC = new org.apache.thrift.protocol.TField("announceFlush", org.apache.thrift.protocol.TType.BOOL, (short)7);
-
- private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
- static {
- schemes.put(StandardScheme.class, new startBgp_argsStandardSchemeFactory());
- schemes.put(TupleScheme.class, new startBgp_argsTupleSchemeFactory());
- }
+ public static class enableBFDFailover<I extends AsyncIface> extends org.apache.thrift.AsyncProcessFunction<I, enableBFDFailover_args, Integer> {
+ public enableBFDFailover() {
+ super("enableBFDFailover");
+ }
- public long asNumber; // required
- public String routerId; // required
- public int port; // required
- public int holdTime; // required
- public int keepAliveTime; // required
- public int stalepathTime; // required
- public boolean announceFlush; // required
+ public enableBFDFailover_args getEmptyArgsInstance() {
+ return new enableBFDFailover_args();
+ }
- /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
- public enum _Fields implements org.apache.thrift.TFieldIdEnum {
- AS_NUMBER((short)1, "asNumber"),
- ROUTER_ID((short)2, "routerId"),
- PORT((short)3, "port"),
- HOLD_TIME((short)4, "holdTime"),
- KEEP_ALIVE_TIME((short)5, "keepAliveTime"),
- STALEPATH_TIME((short)6, "stalepathTime"),
- ANNOUNCE_FLUSH((short)7, "announceFlush");
+ public AsyncMethodCallback<Integer> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
+ final org.apache.thrift.AsyncProcessFunction fcall = this;
+ return new AsyncMethodCallback<Integer>() {
+ public void onComplete(Integer o) {
+ enableBFDFailover_result result = new enableBFDFailover_result();
+ result.success = o;
+ result.setSuccessIsSet(true);
+ try {
+ fcall.sendResponse(fb,result, org.apache.thrift.protocol.TMessageType.REPLY,seqid);
+ return;
+ } catch (Exception e) {
+ LOGGER.error("Exception writing to internal frame buffer", e);
+ }
+ fb.close();
+ }
+ public void onError(Exception e) {
+ byte msgType = org.apache.thrift.protocol.TMessageType.REPLY;
+ org.apache.thrift.TBase msg;
+ enableBFDFailover_result result = new enableBFDFailover_result();
+ {
+ msgType = org.apache.thrift.protocol.TMessageType.EXCEPTION;
+ msg = (org.apache.thrift.TBase)new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.INTERNAL_ERROR, e.getMessage());
+ }
+ try {
+ fcall.sendResponse(fb,msg,msgType,seqid);
+ return;
+ } catch (Exception ex) {
+ LOGGER.error("Exception writing to internal frame buffer", ex);
+ }
+ fb.close();
+ }
+ };
+ }
+
+ protected boolean isOneway() {
+ return false;
+ }
+
+ public void start(I iface, enableBFDFailover_args args, org.apache.thrift.async.AsyncMethodCallback<Integer> resultHandler) throws TException {
+ iface.enableBFDFailover(args.bfdConfig,resultHandler);
+ }
+ }
+
+ public static class disableBFDFailover<I extends AsyncIface> extends org.apache.thrift.AsyncProcessFunction<I, disableBFDFailover_args, Integer> {
+ public disableBFDFailover() {
+ super("disableBFDFailover");
+ }
+
+ public disableBFDFailover_args getEmptyArgsInstance() {
+ return new disableBFDFailover_args();
+ }
+
+ public AsyncMethodCallback<Integer> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
+ final org.apache.thrift.AsyncProcessFunction fcall = this;
+ return new AsyncMethodCallback<Integer>() {
+ public void onComplete(Integer o) {
+ disableBFDFailover_result result = new disableBFDFailover_result();
+ result.success = o;
+ result.setSuccessIsSet(true);
+ try {
+ fcall.sendResponse(fb,result, org.apache.thrift.protocol.TMessageType.REPLY,seqid);
+ return;
+ } catch (Exception e) {
+ LOGGER.error("Exception writing to internal frame buffer", e);
+ }
+ fb.close();
+ }
+ public void onError(Exception e) {
+ byte msgType = org.apache.thrift.protocol.TMessageType.REPLY;
+ org.apache.thrift.TBase msg;
+ disableBFDFailover_result result = new disableBFDFailover_result();
+ {
+ msgType = org.apache.thrift.protocol.TMessageType.EXCEPTION;
+ msg = (org.apache.thrift.TBase)new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.INTERNAL_ERROR, e.getMessage());
+ }
+ try {
+ fcall.sendResponse(fb,msg,msgType,seqid);
+ return;
+ } catch (Exception ex) {
+ LOGGER.error("Exception writing to internal frame buffer", ex);
+ }
+ fb.close();
+ }
+ };
+ }
+
+ protected boolean isOneway() {
+ return false;
+ }
+
+ public void start(I iface, disableBFDFailover_args args, org.apache.thrift.async.AsyncMethodCallback<Integer> resultHandler) throws TException {
+ iface.disableBFDFailover(resultHandler);
+ }
+ }
+
+ public static class getPeerStatus<I extends AsyncIface> extends org.apache.thrift.AsyncProcessFunction<I, getPeerStatus_args, peer_status_type> {
+ public getPeerStatus() {
+ super("getPeerStatus");
+ }
+
+ public getPeerStatus_args getEmptyArgsInstance() {
+ return new getPeerStatus_args();
+ }
+
+ public AsyncMethodCallback<peer_status_type> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
+ final org.apache.thrift.AsyncProcessFunction fcall = this;
+ return new AsyncMethodCallback<peer_status_type>() {
+ public void onComplete(peer_status_type o) {
+ getPeerStatus_result result = new getPeerStatus_result();
+ result.success = o;
+ try {
+ fcall.sendResponse(fb,result, org.apache.thrift.protocol.TMessageType.REPLY,seqid);
+ return;
+ } catch (Exception e) {
+ LOGGER.error("Exception writing to internal frame buffer", e);
+ }
+ fb.close();
+ }
+ public void onError(Exception e) {
+ byte msgType = org.apache.thrift.protocol.TMessageType.REPLY;
+ org.apache.thrift.TBase msg;
+ getPeerStatus_result result = new getPeerStatus_result();
+ {
+ msgType = org.apache.thrift.protocol.TMessageType.EXCEPTION;
+ msg = (org.apache.thrift.TBase)new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.INTERNAL_ERROR, e.getMessage());
+ }
+ try {
+ fcall.sendResponse(fb,msg,msgType,seqid);
+ return;
+ } catch (Exception ex) {
+ LOGGER.error("Exception writing to internal frame buffer", ex);
+ }
+ fb.close();
+ }
+ };
+ }
+
+ protected boolean isOneway() {
+ return false;
+ }
+
+ public void start(I iface, getPeerStatus_args args, org.apache.thrift.async.AsyncMethodCallback<peer_status_type> resultHandler) throws TException {
+ iface.getPeerStatus(args.ipAddress, args.asNumber,resultHandler);
+ }
+ }
+
+ }
+
+ public static class startBgp_args implements org.apache.thrift.TBase<startBgp_args, startBgp_args._Fields>, java.io.Serializable, Cloneable, Comparable<startBgp_args> {
+ private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("startBgp_args");
+
+ private static final org.apache.thrift.protocol.TField AS_NUMBER_FIELD_DESC = new org.apache.thrift.protocol.TField("asNumber", org.apache.thrift.protocol.TType.I64, (short)1);
+ private static final org.apache.thrift.protocol.TField ROUTER_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("routerId", org.apache.thrift.protocol.TType.STRING, (short)2);
+ private static final org.apache.thrift.protocol.TField PORT_FIELD_DESC = new org.apache.thrift.protocol.TField("port", org.apache.thrift.protocol.TType.I32, (short)3);
+ private static final org.apache.thrift.protocol.TField HOLD_TIME_FIELD_DESC = new org.apache.thrift.protocol.TField("holdTime", org.apache.thrift.protocol.TType.I32, (short)4);
+ private static final org.apache.thrift.protocol.TField KEEP_ALIVE_TIME_FIELD_DESC = new org.apache.thrift.protocol.TField("keepAliveTime", org.apache.thrift.protocol.TType.I32, (short)5);
+ private static final org.apache.thrift.protocol.TField STALEPATH_TIME_FIELD_DESC = new org.apache.thrift.protocol.TField("stalepathTime", org.apache.thrift.protocol.TType.I32, (short)6);
+ private static final org.apache.thrift.protocol.TField ANNOUNCE_FBIT_FIELD_DESC = new org.apache.thrift.protocol.TField("announceFbit", org.apache.thrift.protocol.TType.BOOL, (short)7);
+
+ private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
+ static {
+ schemes.put(StandardScheme.class, new startBgp_argsStandardSchemeFactory());
+ schemes.put(TupleScheme.class, new startBgp_argsTupleSchemeFactory());
+ }
+
+ public long asNumber; // required
+ public String routerId; // required
+ public int port; // required
+ public int holdTime; // required
+ public int keepAliveTime; // required
+ public int stalepathTime; // required
+ public boolean announceFbit; // required
+
+ /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
+ public enum _Fields implements org.apache.thrift.TFieldIdEnum {
+ AS_NUMBER((short)1, "asNumber"),
+ ROUTER_ID((short)2, "routerId"),
+ PORT((short)3, "port"),
+ HOLD_TIME((short)4, "holdTime"),
+ KEEP_ALIVE_TIME((short)5, "keepAliveTime"),
+ STALEPATH_TIME((short)6, "stalepathTime"),
+ ANNOUNCE_FBIT((short)7, "announceFbit");
private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
return KEEP_ALIVE_TIME;
case 6: // STALEPATH_TIME
return STALEPATH_TIME;
- case 7: // ANNOUNCE_FLUSH
- return ANNOUNCE_FLUSH;
+ case 7: // ANNOUNCE_FBIT
+ return ANNOUNCE_FBIT;
default:
return null;
}
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) {
- throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
- }
+ if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
return fields;
}
_fieldName = fieldName;
}
- @Override
- public short getThriftFieldId() {
+ public short getThriftFieldId() {
return _thriftId;
}
- @Override
- public String getFieldName() {
+ public String getFieldName() {
return _fieldName;
}
}
private static final int __HOLDTIME_ISSET_ID = 2;
private static final int __KEEPALIVETIME_ISSET_ID = 3;
private static final int __STALEPATHTIME_ISSET_ID = 4;
- private static final int __ANNOUNCEFLUSH_ISSET_ID = 5;
+ private static final int __ANNOUNCEFBIT_ISSET_ID = 5;
private byte __isset_bitfield = 0;
public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
static {
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I32)));
tmpMap.put(_Fields.STALEPATH_TIME, new org.apache.thrift.meta_data.FieldMetaData("stalepathTime", org.apache.thrift.TFieldRequirementType.DEFAULT,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I32)));
- tmpMap.put(_Fields.ANNOUNCE_FLUSH, new org.apache.thrift.meta_data.FieldMetaData("announceFlush", org.apache.thrift.TFieldRequirementType.DEFAULT,
+ tmpMap.put(_Fields.ANNOUNCE_FBIT, new org.apache.thrift.meta_data.FieldMetaData("announceFbit", org.apache.thrift.TFieldRequirementType.DEFAULT,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.BOOL)));
metaDataMap = Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(startBgp_args.class, metaDataMap);
int holdTime,
int keepAliveTime,
int stalepathTime,
- boolean announceFlush)
+ boolean announceFbit)
{
this();
this.asNumber = asNumber;
setKeepAliveTimeIsSet(true);
this.stalepathTime = stalepathTime;
setStalepathTimeIsSet(true);
- this.announceFlush = announceFlush;
- setAnnounceFlushIsSet(true);
+ this.announceFbit = announceFbit;
+ setAnnounceFbitIsSet(true);
}
/**
this.holdTime = other.holdTime;
this.keepAliveTime = other.keepAliveTime;
this.stalepathTime = other.stalepathTime;
- this.announceFlush = other.announceFlush;
+ this.announceFbit = other.announceFbit;
}
- @Override
- public startBgp_args deepCopy() {
+ public startBgp_args deepCopy() {
return new startBgp_args(this);
}
this.keepAliveTime = 0;
setStalepathTimeIsSet(false);
this.stalepathTime = 0;
- setAnnounceFlushIsSet(false);
- this.announceFlush = false;
+ setAnnounceFbitIsSet(false);
+ this.announceFbit = false;
}
public long getAsNumber() {
__isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __STALEPATHTIME_ISSET_ID, value);
}
- public boolean isAnnounceFlush() {
- return this.announceFlush;
+ public boolean isAnnounceFbit() {
+ return this.announceFbit;
}
- public startBgp_args setAnnounceFlush(boolean announceFlush) {
- this.announceFlush = announceFlush;
- setAnnounceFlushIsSet(true);
+ public startBgp_args setAnnounceFbit(boolean announceFbit) {
+ this.announceFbit = announceFbit;
+ setAnnounceFbitIsSet(true);
return this;
}
- public void unsetAnnounceFlush() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __ANNOUNCEFLUSH_ISSET_ID);
+ public void unsetAnnounceFbit() {
+ __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __ANNOUNCEFBIT_ISSET_ID);
}
- /** Returns true if field announceFlush is set (has been assigned a value) and false otherwise */
- public boolean isSetAnnounceFlush() {
- return EncodingUtils.testBit(__isset_bitfield, __ANNOUNCEFLUSH_ISSET_ID);
+ /** Returns true if field announceFbit is set (has been assigned a value) and false otherwise */
+ public boolean isSetAnnounceFbit() {
+ return EncodingUtils.testBit(__isset_bitfield, __ANNOUNCEFBIT_ISSET_ID);
}
- public void setAnnounceFlushIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __ANNOUNCEFLUSH_ISSET_ID, value);
+ public void setAnnounceFbitIsSet(boolean value) {
+ __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __ANNOUNCEFBIT_ISSET_ID, value);
}
- @Override
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, Object value) {
switch (field) {
case AS_NUMBER:
if (value == null) {
}
break;
- case ANNOUNCE_FLUSH:
+ case ANNOUNCE_FBIT:
if (value == null) {
- unsetAnnounceFlush();
+ unsetAnnounceFbit();
} else {
- setAnnounceFlush((Boolean)value);
+ setAnnounceFbit((Boolean)value);
}
break;
}
}
- @Override
- public Object getFieldValue(_Fields field) {
+ public Object getFieldValue(_Fields field) {
switch (field) {
case AS_NUMBER:
- return Long.valueOf(getAsNumber());
+ return getAsNumber();
case ROUTER_ID:
return getRouterId();
case PORT:
- return Integer.valueOf(getPort());
+ return getPort();
case HOLD_TIME:
- return Integer.valueOf(getHoldTime());
+ return getHoldTime();
case KEEP_ALIVE_TIME:
- return Integer.valueOf(getKeepAliveTime());
+ return getKeepAliveTime();
case STALEPATH_TIME:
- return Integer.valueOf(getStalepathTime());
+ return getStalepathTime();
- case ANNOUNCE_FLUSH:
- return Boolean.valueOf(isAnnounceFlush());
+ case ANNOUNCE_FBIT:
+ return isAnnounceFbit();
}
throw new IllegalStateException();
}
/** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
- @Override
- public boolean isSet(_Fields field) {
+ public boolean isSet(_Fields field) {
if (field == null) {
throw new IllegalArgumentException();
}
return isSetKeepAliveTime();
case STALEPATH_TIME:
return isSetStalepathTime();
- case ANNOUNCE_FLUSH:
- return isSetAnnounceFlush();
+ case ANNOUNCE_FBIT:
+ return isSetAnnounceFbit();
}
throw new IllegalStateException();
}
@Override
public boolean equals(Object that) {
- if (that == null) {
- return false;
- }
- if (that instanceof startBgp_args) {
- return this.equals((startBgp_args)that);
- }
+ if (that == null)
+ return false;
+ if (that instanceof startBgp_args)
+ return this.equals((startBgp_args)that);
return false;
}
public boolean equals(startBgp_args that) {
- if (that == null) {
- return false;
- }
+ if (that == null)
+ return false;
boolean this_present_asNumber = true;
boolean that_present_asNumber = true;
if (this_present_asNumber || that_present_asNumber) {
- if (!(this_present_asNumber && that_present_asNumber)) {
- return false;
- }
- if (this.asNumber != that.asNumber) {
- return false;
- }
+ if (!(this_present_asNumber && that_present_asNumber))
+ return false;
+ if (this.asNumber != that.asNumber)
+ return false;
}
boolean this_present_routerId = true && this.isSetRouterId();
boolean that_present_routerId = true && that.isSetRouterId();
if (this_present_routerId || that_present_routerId) {
- if (!(this_present_routerId && that_present_routerId)) {
- return false;
- }
- if (!this.routerId.equals(that.routerId)) {
- return false;
- }
+ if (!(this_present_routerId && that_present_routerId))
+ return false;
+ if (!this.routerId.equals(that.routerId))
+ return false;
}
boolean this_present_port = true;
boolean that_present_port = true;
if (this_present_port || that_present_port) {
- if (!(this_present_port && that_present_port)) {
- return false;
- }
- if (this.port != that.port) {
- return false;
- }
+ if (!(this_present_port && that_present_port))
+ return false;
+ if (this.port != that.port)
+ return false;
}
boolean this_present_holdTime = true;
boolean that_present_holdTime = true;
if (this_present_holdTime || that_present_holdTime) {
- if (!(this_present_holdTime && that_present_holdTime)) {
- return false;
- }
- if (this.holdTime != that.holdTime) {
- return false;
- }
+ if (!(this_present_holdTime && that_present_holdTime))
+ return false;
+ if (this.holdTime != that.holdTime)
+ return false;
}
boolean this_present_keepAliveTime = true;
boolean that_present_keepAliveTime = true;
if (this_present_keepAliveTime || that_present_keepAliveTime) {
- if (!(this_present_keepAliveTime && that_present_keepAliveTime)) {
- return false;
- }
- if (this.keepAliveTime != that.keepAliveTime) {
- return false;
- }
+ if (!(this_present_keepAliveTime && that_present_keepAliveTime))
+ return false;
+ if (this.keepAliveTime != that.keepAliveTime)
+ return false;
}
boolean this_present_stalepathTime = true;
boolean that_present_stalepathTime = true;
if (this_present_stalepathTime || that_present_stalepathTime) {
- if (!(this_present_stalepathTime && that_present_stalepathTime)) {
- return false;
- }
- if (this.stalepathTime != that.stalepathTime) {
- return false;
- }
+ if (!(this_present_stalepathTime && that_present_stalepathTime))
+ return false;
+ if (this.stalepathTime != that.stalepathTime)
+ return false;
}
- boolean this_present_announceFlush = true;
- boolean that_present_announceFlush = true;
- if (this_present_announceFlush || that_present_announceFlush) {
- if (!(this_present_announceFlush && that_present_announceFlush)) {
- return false;
- }
- if (this.announceFlush != that.announceFlush) {
- return false;
- }
+ boolean this_present_announceFbit = true;
+ boolean that_present_announceFbit = true;
+ if (this_present_announceFbit || that_present_announceFbit) {
+ if (!(this_present_announceFbit && that_present_announceFbit))
+ return false;
+ if (this.announceFbit != that.announceFbit)
+ return false;
}
return true;
list.add(present_asNumber);
if (present_asNumber)
list.add(asNumber);
+
boolean present_routerId = true && (isSetRouterId());
list.add(present_routerId);
if (present_routerId)
list.add(routerId);
+
boolean present_port = true;
list.add(present_port);
if (present_port)
list.add(port);
+
boolean present_holdTime = true;
list.add(present_holdTime);
if (present_holdTime)
list.add(holdTime);
+
boolean present_keepAliveTime = true;
list.add(present_keepAliveTime);
if (present_keepAliveTime)
list.add(keepAliveTime);
+
boolean present_stalepathTime = true;
list.add(present_stalepathTime);
if (present_stalepathTime)
list.add(stalepathTime);
- boolean present_announceFlush = true;
- list.add(present_announceFlush);
- if (present_announceFlush)
- list.add(announceFlush);
+
+ boolean present_announceFbit = true;
+ list.add(present_announceFbit);
+ if (present_announceFbit)
+ list.add(announceFbit);
+
return list.hashCode();
}
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetAnnounceFlush()).compareTo(other.isSetAnnounceFlush());
+ lastComparison = Boolean.valueOf(isSetAnnounceFbit()).compareTo(other.isSetAnnounceFbit());
if (lastComparison != 0) {
return lastComparison;
}
- if (isSetAnnounceFlush()) {
- lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.announceFlush, other.announceFlush);
+ if (isSetAnnounceFbit()) {
+ lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.announceFbit, other.announceFbit);
if (lastComparison != 0) {
return lastComparison;
}
return 0;
}
- @Override
- public _Fields fieldForId(int fieldId) {
+ public _Fields fieldForId(int fieldId) {
return _Fields.findByThriftId(fieldId);
}
- @Override
- public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
+ public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
}
- @Override
- public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
+ public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
schemes.get(oprot.getScheme()).getScheme().write(oprot, this);
}
sb.append("asNumber:");
sb.append(this.asNumber);
first = false;
- if (!first) {
- sb.append(", ");
- }
+ if (!first) sb.append(", ");
sb.append("routerId:");
if (this.routerId == null) {
sb.append("null");
sb.append(this.routerId);
}
first = false;
- if (!first) {
- sb.append(", ");
- }
+ if (!first) sb.append(", ");
sb.append("port:");
sb.append(this.port);
first = false;
- if (!first) {
- sb.append(", ");
- }
+ if (!first) sb.append(", ");
sb.append("holdTime:");
sb.append(this.holdTime);
first = false;
- if (!first) {
- sb.append(", ");
- }
+ if (!first) sb.append(", ");
sb.append("keepAliveTime:");
sb.append(this.keepAliveTime);
first = false;
- if (!first) {
- sb.append(", ");
- }
+ if (!first) sb.append(", ");
sb.append("stalepathTime:");
sb.append(this.stalepathTime);
first = false;
- if (!first) {
- sb.append(", ");
- }
- sb.append("announceFlush:");
- sb.append(this.announceFlush);
+ if (!first) sb.append(", ");
+ sb.append("announceFbit:");
+ sb.append(this.announceFbit);
first = false;
sb.append(")");
return sb.toString();
}
private static class startBgp_argsStandardSchemeFactory implements SchemeFactory {
- @Override
- public startBgp_argsStandardScheme getScheme() {
+ public startBgp_argsStandardScheme getScheme() {
return new startBgp_argsStandardScheme();
}
}
private static class startBgp_argsStandardScheme extends StandardScheme<startBgp_args> {
- @Override
- public void read(org.apache.thrift.protocol.TProtocol iprot, startBgp_args struct) throws org.apache.thrift.TException {
+ public void read(org.apache.thrift.protocol.TProtocol iprot, startBgp_args struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
iprot.readStructBegin();
while (true)
org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
}
break;
- case 7: // ANNOUNCE_FLUSH
+ case 7: // ANNOUNCE_FBIT
if (schemeField.type == org.apache.thrift.protocol.TType.BOOL) {
- struct.announceFlush = iprot.readBool();
- struct.setAnnounceFlushIsSet(true);
+ struct.announceFbit = iprot.readBool();
+ struct.setAnnounceFbitIsSet(true);
} else {
org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
}
struct.validate();
}
- @Override
- public void write(org.apache.thrift.protocol.TProtocol oprot, startBgp_args struct) throws org.apache.thrift.TException {
+ public void write(org.apache.thrift.protocol.TProtocol oprot, startBgp_args struct) throws org.apache.thrift.TException {
struct.validate();
oprot.writeStructBegin(STRUCT_DESC);
oprot.writeFieldBegin(STALEPATH_TIME_FIELD_DESC);
oprot.writeI32(struct.stalepathTime);
oprot.writeFieldEnd();
- oprot.writeFieldBegin(ANNOUNCE_FLUSH_FIELD_DESC);
- oprot.writeBool(struct.announceFlush);
+ oprot.writeFieldBegin(ANNOUNCE_FBIT_FIELD_DESC);
+ oprot.writeBool(struct.announceFbit);
oprot.writeFieldEnd();
oprot.writeFieldStop();
oprot.writeStructEnd();
}
private static class startBgp_argsTupleSchemeFactory implements SchemeFactory {
- @Override
- public startBgp_argsTupleScheme getScheme() {
+ public startBgp_argsTupleScheme getScheme() {
return new startBgp_argsTupleScheme();
}
}
if (struct.isSetStalepathTime()) {
optionals.set(5);
}
- if (struct.isSetAnnounceFlush()) {
+ if (struct.isSetAnnounceFbit()) {
optionals.set(6);
}
oprot.writeBitSet(optionals, 7);
if (struct.isSetStalepathTime()) {
oprot.writeI32(struct.stalepathTime);
}
- if (struct.isSetAnnounceFlush()) {
- oprot.writeBool(struct.announceFlush);
+ if (struct.isSetAnnounceFbit()) {
+ oprot.writeBool(struct.announceFbit);
}
}
struct.setStalepathTimeIsSet(true);
}
if (incoming.get(6)) {
- struct.announceFlush = iprot.readBool();
- struct.setAnnounceFlushIsSet(true);
+ struct.announceFbit = iprot.readBool();
+ struct.setAnnounceFbitIsSet(true);
}
}
}
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) {
- throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
- }
+ if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
return fields;
}
_fieldName = fieldName;
}
- @Override
- public short getThriftFieldId() {
+ public short getThriftFieldId() {
return _thriftId;
}
- @Override
- public String getFieldName() {
+ public String getFieldName() {
return _fieldName;
}
}
this.success = other.success;
}
- @Override
- public startBgp_result deepCopy() {
+ public startBgp_result deepCopy() {
return new startBgp_result(this);
}
__isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __SUCCESS_ISSET_ID, value);
}
- @Override
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, Object value) {
switch (field) {
case SUCCESS:
if (value == null) {
}
}
- @Override
- public Object getFieldValue(_Fields field) {
+ public Object getFieldValue(_Fields field) {
switch (field) {
case SUCCESS:
- return Integer.valueOf(getSuccess());
+ return getSuccess();
}
throw new IllegalStateException();
}
/** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
- @Override
- public boolean isSet(_Fields field) {
+ public boolean isSet(_Fields field) {
if (field == null) {
throw new IllegalArgumentException();
}
@Override
public boolean equals(Object that) {
- if (that == null) {
- return false;
- }
- if (that instanceof startBgp_result) {
- return this.equals((startBgp_result)that);
- }
+ if (that == null)
+ return false;
+ if (that instanceof startBgp_result)
+ return this.equals((startBgp_result)that);
return false;
}
public boolean equals(startBgp_result that) {
- if (that == null) {
- return false;
- }
+ if (that == null)
+ return false;
boolean this_present_success = true;
boolean that_present_success = true;
if (this_present_success || that_present_success) {
- if (!(this_present_success && that_present_success)) {
- return false;
- }
- if (this.success != that.success) {
- return false;
- }
+ if (!(this_present_success && that_present_success))
+ return false;
+ if (this.success != that.success)
+ return false;
}
return true;
list.add(present_success);
if (present_success)
list.add(success);
+
return list.hashCode();
}
return 0;
}
- @Override
- public _Fields fieldForId(int fieldId) {
+ public _Fields fieldForId(int fieldId) {
return _Fields.findByThriftId(fieldId);
}
- @Override
- public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
+ public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
}
- @Override
- public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
+ public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
schemes.get(oprot.getScheme()).getScheme().write(oprot, this);
}
}
private static class startBgp_resultStandardSchemeFactory implements SchemeFactory {
- @Override
- public startBgp_resultStandardScheme getScheme() {
+ public startBgp_resultStandardScheme getScheme() {
return new startBgp_resultStandardScheme();
}
}
private static class startBgp_resultStandardScheme extends StandardScheme<startBgp_result> {
- @Override
- public void read(org.apache.thrift.protocol.TProtocol iprot, startBgp_result struct) throws org.apache.thrift.TException {
+ public void read(org.apache.thrift.protocol.TProtocol iprot, startBgp_result struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
iprot.readStructBegin();
while (true)
struct.validate();
}
- @Override
- public void write(org.apache.thrift.protocol.TProtocol oprot, startBgp_result struct) throws org.apache.thrift.TException {
+ public void write(org.apache.thrift.protocol.TProtocol oprot, startBgp_result struct) throws org.apache.thrift.TException {
struct.validate();
oprot.writeStructBegin(STRUCT_DESC);
}
private static class startBgp_resultTupleSchemeFactory implements SchemeFactory {
- @Override
- public startBgp_resultTupleScheme getScheme() {
+ public startBgp_resultTupleScheme getScheme() {
return new startBgp_resultTupleScheme();
}
}
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) {
- throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
- }
+ if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
return fields;
}
_fieldName = fieldName;
}
- @Override
- public short getThriftFieldId() {
+ public short getThriftFieldId() {
return _thriftId;
}
- @Override
- public String getFieldName() {
+ public String getFieldName() {
return _fieldName;
}
}
this.asNumber = other.asNumber;
}
- @Override
- public stopBgp_args deepCopy() {
+ public stopBgp_args deepCopy() {
return new stopBgp_args(this);
}
__isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __ASNUMBER_ISSET_ID, value);
}
- @Override
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, Object value) {
switch (field) {
case AS_NUMBER:
if (value == null) {
}
}
- @Override
- public Object getFieldValue(_Fields field) {
+ public Object getFieldValue(_Fields field) {
switch (field) {
case AS_NUMBER:
- return Long.valueOf(getAsNumber());
+ return getAsNumber();
}
throw new IllegalStateException();
}
/** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
- @Override
- public boolean isSet(_Fields field) {
+ public boolean isSet(_Fields field) {
if (field == null) {
throw new IllegalArgumentException();
}
@Override
public boolean equals(Object that) {
- if (that == null) {
- return false;
- }
- if (that instanceof stopBgp_args) {
- return this.equals((stopBgp_args)that);
- }
+ if (that == null)
+ return false;
+ if (that instanceof stopBgp_args)
+ return this.equals((stopBgp_args)that);
return false;
}
public boolean equals(stopBgp_args that) {
- if (that == null) {
- return false;
- }
+ if (that == null)
+ return false;
boolean this_present_asNumber = true;
boolean that_present_asNumber = true;
if (this_present_asNumber || that_present_asNumber) {
- if (!(this_present_asNumber && that_present_asNumber)) {
- return false;
- }
- if (this.asNumber != that.asNumber) {
- return false;
- }
+ if (!(this_present_asNumber && that_present_asNumber))
+ return false;
+ if (this.asNumber != that.asNumber)
+ return false;
}
return true;
list.add(present_asNumber);
if (present_asNumber)
list.add(asNumber);
+
return list.hashCode();
}
return 0;
}
- @Override
- public _Fields fieldForId(int fieldId) {
+ public _Fields fieldForId(int fieldId) {
return _Fields.findByThriftId(fieldId);
}
- @Override
- public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
+ public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
}
- @Override
- public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
+ public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
schemes.get(oprot.getScheme()).getScheme().write(oprot, this);
}
}
private static class stopBgp_argsStandardSchemeFactory implements SchemeFactory {
- @Override
- public stopBgp_argsStandardScheme getScheme() {
+ public stopBgp_argsStandardScheme getScheme() {
return new stopBgp_argsStandardScheme();
}
}
private static class stopBgp_argsStandardScheme extends StandardScheme<stopBgp_args> {
- @Override
- public void read(org.apache.thrift.protocol.TProtocol iprot, stopBgp_args struct) throws org.apache.thrift.TException {
+ public void read(org.apache.thrift.protocol.TProtocol iprot, stopBgp_args struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
iprot.readStructBegin();
while (true)
struct.validate();
}
- @Override
- public void write(org.apache.thrift.protocol.TProtocol oprot, stopBgp_args struct) throws org.apache.thrift.TException {
+ public void write(org.apache.thrift.protocol.TProtocol oprot, stopBgp_args struct) throws org.apache.thrift.TException {
struct.validate();
oprot.writeStructBegin(STRUCT_DESC);
}
private static class stopBgp_argsTupleSchemeFactory implements SchemeFactory {
- @Override
- public stopBgp_argsTupleScheme getScheme() {
+ public stopBgp_argsTupleScheme getScheme() {
return new stopBgp_argsTupleScheme();
}
}
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) {
- throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
- }
+ if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
return fields;
}
_fieldName = fieldName;
}
- @Override
- public short getThriftFieldId() {
+ public short getThriftFieldId() {
return _thriftId;
}
- @Override
- public String getFieldName() {
+ public String getFieldName() {
return _fieldName;
}
}
this.success = other.success;
}
- @Override
- public stopBgp_result deepCopy() {
+ public stopBgp_result deepCopy() {
return new stopBgp_result(this);
}
__isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __SUCCESS_ISSET_ID, value);
}
- @Override
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, Object value) {
switch (field) {
case SUCCESS:
if (value == null) {
}
}
- @Override
- public Object getFieldValue(_Fields field) {
+ public Object getFieldValue(_Fields field) {
switch (field) {
case SUCCESS:
- return Integer.valueOf(getSuccess());
+ return getSuccess();
}
throw new IllegalStateException();
}
/** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
- @Override
- public boolean isSet(_Fields field) {
+ public boolean isSet(_Fields field) {
if (field == null) {
throw new IllegalArgumentException();
}
@Override
public boolean equals(Object that) {
- if (that == null) {
- return false;
- }
- if (that instanceof stopBgp_result) {
- return this.equals((stopBgp_result)that);
- }
+ if (that == null)
+ return false;
+ if (that instanceof stopBgp_result)
+ return this.equals((stopBgp_result)that);
return false;
}
public boolean equals(stopBgp_result that) {
- if (that == null) {
- return false;
- }
+ if (that == null)
+ return false;
boolean this_present_success = true;
boolean that_present_success = true;
if (this_present_success || that_present_success) {
- if (!(this_present_success && that_present_success)) {
- return false;
- }
- if (this.success != that.success) {
- return false;
- }
+ if (!(this_present_success && that_present_success))
+ return false;
+ if (this.success != that.success)
+ return false;
}
return true;
list.add(present_success);
if (present_success)
list.add(success);
+
return list.hashCode();
}
return 0;
}
- @Override
- public _Fields fieldForId(int fieldId) {
+ public _Fields fieldForId(int fieldId) {
return _Fields.findByThriftId(fieldId);
}
- @Override
- public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
+ public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
}
- @Override
- public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
+ public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
schemes.get(oprot.getScheme()).getScheme().write(oprot, this);
}
}
private static class stopBgp_resultStandardSchemeFactory implements SchemeFactory {
- @Override
- public stopBgp_resultStandardScheme getScheme() {
+ public stopBgp_resultStandardScheme getScheme() {
return new stopBgp_resultStandardScheme();
}
}
private static class stopBgp_resultStandardScheme extends StandardScheme<stopBgp_result> {
- @Override
- public void read(org.apache.thrift.protocol.TProtocol iprot, stopBgp_result struct) throws org.apache.thrift.TException {
+ public void read(org.apache.thrift.protocol.TProtocol iprot, stopBgp_result struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
iprot.readStructBegin();
while (true)
struct.validate();
}
- @Override
- public void write(org.apache.thrift.protocol.TProtocol oprot, stopBgp_result struct) throws org.apache.thrift.TException {
+ public void write(org.apache.thrift.protocol.TProtocol oprot, stopBgp_result struct) throws org.apache.thrift.TException {
struct.validate();
oprot.writeStructBegin(STRUCT_DESC);
}
private static class stopBgp_resultTupleSchemeFactory implements SchemeFactory {
- @Override
- public stopBgp_resultTupleScheme getScheme() {
+ public stopBgp_resultTupleScheme getScheme() {
return new stopBgp_resultTupleScheme();
}
}
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) {
- throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
- }
+ if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
return fields;
}
_fieldName = fieldName;
}
- @Override
- public short getThriftFieldId() {
+ public short getThriftFieldId() {
return _thriftId;
}
- @Override
- public String getFieldName() {
+ public String getFieldName() {
return _fieldName;
}
}
this.asNumber = other.asNumber;
}
- @Override
- public createPeer_args deepCopy() {
+ public createPeer_args deepCopy() {
return new createPeer_args(this);
}
__isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __ASNUMBER_ISSET_ID, value);
}
- @Override
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, Object value) {
switch (field) {
case IP_ADDRESS:
if (value == null) {
}
}
- @Override
- public Object getFieldValue(_Fields field) {
+ public Object getFieldValue(_Fields field) {
switch (field) {
case IP_ADDRESS:
return getIpAddress();
case AS_NUMBER:
- return Long.valueOf(getAsNumber());
+ return getAsNumber();
}
throw new IllegalStateException();
}
/** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
- @Override
- public boolean isSet(_Fields field) {
+ public boolean isSet(_Fields field) {
if (field == null) {
throw new IllegalArgumentException();
}
@Override
public boolean equals(Object that) {
- if (that == null) {
- return false;
- }
- if (that instanceof createPeer_args) {
- return this.equals((createPeer_args)that);
- }
+ if (that == null)
+ return false;
+ if (that instanceof createPeer_args)
+ return this.equals((createPeer_args)that);
return false;
}
public boolean equals(createPeer_args that) {
- if (that == null) {
- return false;
- }
+ if (that == null)
+ return false;
boolean this_present_ipAddress = true && this.isSetIpAddress();
boolean that_present_ipAddress = true && that.isSetIpAddress();
if (this_present_ipAddress || that_present_ipAddress) {
- if (!(this_present_ipAddress && that_present_ipAddress)) {
- return false;
- }
- if (!this.ipAddress.equals(that.ipAddress)) {
- return false;
- }
+ if (!(this_present_ipAddress && that_present_ipAddress))
+ return false;
+ if (!this.ipAddress.equals(that.ipAddress))
+ return false;
}
boolean this_present_asNumber = true;
boolean that_present_asNumber = true;
if (this_present_asNumber || that_present_asNumber) {
- if (!(this_present_asNumber && that_present_asNumber)) {
- return false;
- }
- if (this.asNumber != that.asNumber) {
- return false;
- }
+ if (!(this_present_asNumber && that_present_asNumber))
+ return false;
+ if (this.asNumber != that.asNumber)
+ return false;
}
return true;
list.add(present_ipAddress);
if (present_ipAddress)
list.add(ipAddress);
+
boolean present_asNumber = true;
list.add(present_asNumber);
if (present_asNumber)
list.add(asNumber);
+
return list.hashCode();
}
return 0;
}
- @Override
- public _Fields fieldForId(int fieldId) {
+ public _Fields fieldForId(int fieldId) {
return _Fields.findByThriftId(fieldId);
}
- @Override
- public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
+ public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
}
- @Override
- public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
+ public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
schemes.get(oprot.getScheme()).getScheme().write(oprot, this);
}
sb.append(this.ipAddress);
}
first = false;
- if (!first) {
- sb.append(", ");
- }
+ if (!first) sb.append(", ");
sb.append("asNumber:");
sb.append(this.asNumber);
first = false;
}
private static class createPeer_argsStandardSchemeFactory implements SchemeFactory {
- @Override
- public createPeer_argsStandardScheme getScheme() {
+ public createPeer_argsStandardScheme getScheme() {
return new createPeer_argsStandardScheme();
}
}
private static class createPeer_argsStandardScheme extends StandardScheme<createPeer_args> {
- @Override
- public void read(org.apache.thrift.protocol.TProtocol iprot, createPeer_args struct) throws org.apache.thrift.TException {
+ public void read(org.apache.thrift.protocol.TProtocol iprot, createPeer_args struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
iprot.readStructBegin();
while (true)
struct.validate();
}
- @Override
- public void write(org.apache.thrift.protocol.TProtocol oprot, createPeer_args struct) throws org.apache.thrift.TException {
+ public void write(org.apache.thrift.protocol.TProtocol oprot, createPeer_args struct) throws org.apache.thrift.TException {
struct.validate();
oprot.writeStructBegin(STRUCT_DESC);
}
private static class createPeer_argsTupleSchemeFactory implements SchemeFactory {
- @Override
- public createPeer_argsTupleScheme getScheme() {
+ public createPeer_argsTupleScheme getScheme() {
return new createPeer_argsTupleScheme();
}
}
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) {
- throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
- }
+ if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
return fields;
}
_fieldName = fieldName;
}
- @Override
- public short getThriftFieldId() {
+ public short getThriftFieldId() {
return _thriftId;
}
- @Override
- public String getFieldName() {
+ public String getFieldName() {
return _fieldName;
}
}
this.success = other.success;
}
- @Override
- public createPeer_result deepCopy() {
+ public createPeer_result deepCopy() {
return new createPeer_result(this);
}
__isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __SUCCESS_ISSET_ID, value);
}
- @Override
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, Object value) {
switch (field) {
case SUCCESS:
if (value == null) {
}
}
- @Override
- public Object getFieldValue(_Fields field) {
+ public Object getFieldValue(_Fields field) {
switch (field) {
case SUCCESS:
- return Integer.valueOf(getSuccess());
+ return getSuccess();
}
throw new IllegalStateException();
}
/** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
- @Override
- public boolean isSet(_Fields field) {
+ public boolean isSet(_Fields field) {
if (field == null) {
throw new IllegalArgumentException();
}
@Override
public boolean equals(Object that) {
- if (that == null) {
- return false;
- }
- if (that instanceof createPeer_result) {
- return this.equals((createPeer_result)that);
- }
+ if (that == null)
+ return false;
+ if (that instanceof createPeer_result)
+ return this.equals((createPeer_result)that);
return false;
}
public boolean equals(createPeer_result that) {
- if (that == null) {
- return false;
- }
+ if (that == null)
+ return false;
boolean this_present_success = true;
boolean that_present_success = true;
if (this_present_success || that_present_success) {
- if (!(this_present_success && that_present_success)) {
- return false;
- }
- if (this.success != that.success) {
- return false;
- }
+ if (!(this_present_success && that_present_success))
+ return false;
+ if (this.success != that.success)
+ return false;
}
return true;
list.add(present_success);
if (present_success)
list.add(success);
+
return list.hashCode();
}
return 0;
}
- @Override
- public _Fields fieldForId(int fieldId) {
+ public _Fields fieldForId(int fieldId) {
return _Fields.findByThriftId(fieldId);
}
- @Override
- public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
+ public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
}
- @Override
- public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
+ public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
schemes.get(oprot.getScheme()).getScheme().write(oprot, this);
}
}
private static class createPeer_resultStandardSchemeFactory implements SchemeFactory {
- @Override
- public createPeer_resultStandardScheme getScheme() {
+ public createPeer_resultStandardScheme getScheme() {
return new createPeer_resultStandardScheme();
}
}
private static class createPeer_resultStandardScheme extends StandardScheme<createPeer_result> {
- @Override
- public void read(org.apache.thrift.protocol.TProtocol iprot, createPeer_result struct) throws org.apache.thrift.TException {
+ public void read(org.apache.thrift.protocol.TProtocol iprot, createPeer_result struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
iprot.readStructBegin();
while (true)
struct.validate();
}
- @Override
- public void write(org.apache.thrift.protocol.TProtocol oprot, createPeer_result struct) throws org.apache.thrift.TException {
+ public void write(org.apache.thrift.protocol.TProtocol oprot, createPeer_result struct) throws org.apache.thrift.TException {
struct.validate();
oprot.writeStructBegin(STRUCT_DESC);
}
private static class createPeer_resultTupleSchemeFactory implements SchemeFactory {
- @Override
- public createPeer_resultTupleScheme getScheme() {
+ public createPeer_resultTupleScheme getScheme() {
return new createPeer_resultTupleScheme();
}
}
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) {
- throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
- }
+ if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
return fields;
}
_fieldName = fieldName;
}
- @Override
- public short getThriftFieldId() {
+ public short getThriftFieldId() {
return _thriftId;
}
- @Override
- public String getFieldName() {
+ public String getFieldName() {
return _fieldName;
}
}
}
}
- @Override
- public setPeerSecret_args deepCopy() {
+ public setPeerSecret_args deepCopy() {
return new setPeerSecret_args(this);
}
}
}
- @Override
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, Object value) {
switch (field) {
case IP_ADDRESS:
if (value == null) {
}
}
- @Override
- public Object getFieldValue(_Fields field) {
+ public Object getFieldValue(_Fields field) {
switch (field) {
case IP_ADDRESS:
return getIpAddress();
}
/** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
- @Override
- public boolean isSet(_Fields field) {
+ public boolean isSet(_Fields field) {
if (field == null) {
throw new IllegalArgumentException();
}
@Override
public boolean equals(Object that) {
- if (that == null) {
- return false;
- }
- if (that instanceof setPeerSecret_args) {
- return this.equals((setPeerSecret_args)that);
- }
+ if (that == null)
+ return false;
+ if (that instanceof setPeerSecret_args)
+ return this.equals((setPeerSecret_args)that);
return false;
}
public boolean equals(setPeerSecret_args that) {
- if (that == null) {
- return false;
- }
+ if (that == null)
+ return false;
boolean this_present_ipAddress = true && this.isSetIpAddress();
boolean that_present_ipAddress = true && that.isSetIpAddress();
if (this_present_ipAddress || that_present_ipAddress) {
- if (!(this_present_ipAddress && that_present_ipAddress)) {
- return false;
- }
- if (!this.ipAddress.equals(that.ipAddress)) {
- return false;
- }
+ if (!(this_present_ipAddress && that_present_ipAddress))
+ return false;
+ if (!this.ipAddress.equals(that.ipAddress))
+ return false;
}
boolean this_present_rfc2385_sharedSecret = true && this.isSetRfc2385_sharedSecret();
boolean that_present_rfc2385_sharedSecret = true && that.isSetRfc2385_sharedSecret();
if (this_present_rfc2385_sharedSecret || that_present_rfc2385_sharedSecret) {
- if (!(this_present_rfc2385_sharedSecret && that_present_rfc2385_sharedSecret)) {
- return false;
- }
- if (!this.rfc2385_sharedSecret.equals(that.rfc2385_sharedSecret)) {
- return false;
- }
+ if (!(this_present_rfc2385_sharedSecret && that_present_rfc2385_sharedSecret))
+ return false;
+ if (!this.rfc2385_sharedSecret.equals(that.rfc2385_sharedSecret))
+ return false;
}
return true;
list.add(present_ipAddress);
if (present_ipAddress)
list.add(ipAddress);
+
boolean present_rfc2385_sharedSecret = true && (isSetRfc2385_sharedSecret());
list.add(present_rfc2385_sharedSecret);
if (present_rfc2385_sharedSecret)
list.add(rfc2385_sharedSecret);
+
return list.hashCode();
}
return 0;
}
- @Override
- public _Fields fieldForId(int fieldId) {
+ public _Fields fieldForId(int fieldId) {
return _Fields.findByThriftId(fieldId);
}
- @Override
- public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
+ public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
}
- @Override
- public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
+ public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
schemes.get(oprot.getScheme()).getScheme().write(oprot, this);
}
sb.append(this.ipAddress);
}
first = false;
- if (!first) {
- sb.append(", ");
- }
+ if (!first) sb.append(", ");
sb.append("rfc2385_sharedSecret:");
if (this.rfc2385_sharedSecret == null) {
sb.append("null");
}
private static class setPeerSecret_argsStandardSchemeFactory implements SchemeFactory {
- @Override
- public setPeerSecret_argsStandardScheme getScheme() {
+ public setPeerSecret_argsStandardScheme getScheme() {
return new setPeerSecret_argsStandardScheme();
}
}
private static class setPeerSecret_argsStandardScheme extends StandardScheme<setPeerSecret_args> {
- @Override
- public void read(org.apache.thrift.protocol.TProtocol iprot, setPeerSecret_args struct) throws org.apache.thrift.TException {
+ public void read(org.apache.thrift.protocol.TProtocol iprot, setPeerSecret_args struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
iprot.readStructBegin();
while (true)
struct.validate();
}
- @Override
- public void write(org.apache.thrift.protocol.TProtocol oprot, setPeerSecret_args struct) throws org.apache.thrift.TException {
+ public void write(org.apache.thrift.protocol.TProtocol oprot, setPeerSecret_args struct) throws org.apache.thrift.TException {
struct.validate();
oprot.writeStructBegin(STRUCT_DESC);
}
private static class setPeerSecret_argsTupleSchemeFactory implements SchemeFactory {
- @Override
- public setPeerSecret_argsTupleScheme getScheme() {
+ public setPeerSecret_argsTupleScheme getScheme() {
return new setPeerSecret_argsTupleScheme();
}
}
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) {
- throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
- }
+ if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
return fields;
}
_fieldName = fieldName;
}
- @Override
- public short getThriftFieldId() {
+ public short getThriftFieldId() {
return _thriftId;
}
- @Override
- public String getFieldName() {
+ public String getFieldName() {
return _fieldName;
}
}
this.success = other.success;
}
- @Override
- public setPeerSecret_result deepCopy() {
+ public setPeerSecret_result deepCopy() {
return new setPeerSecret_result(this);
}
__isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __SUCCESS_ISSET_ID, value);
}
- @Override
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, Object value) {
switch (field) {
case SUCCESS:
if (value == null) {
}
}
- @Override
- public Object getFieldValue(_Fields field) {
+ public Object getFieldValue(_Fields field) {
switch (field) {
case SUCCESS:
- return Integer.valueOf(getSuccess());
+ return getSuccess();
}
throw new IllegalStateException();
}
/** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
- @Override
- public boolean isSet(_Fields field) {
+ public boolean isSet(_Fields field) {
if (field == null) {
throw new IllegalArgumentException();
}
@Override
public boolean equals(Object that) {
- if (that == null) {
- return false;
- }
- if (that instanceof setPeerSecret_result) {
- return this.equals((setPeerSecret_result)that);
- }
+ if (that == null)
+ return false;
+ if (that instanceof setPeerSecret_result)
+ return this.equals((setPeerSecret_result)that);
return false;
}
public boolean equals(setPeerSecret_result that) {
- if (that == null) {
- return false;
- }
+ if (that == null)
+ return false;
boolean this_present_success = true;
boolean that_present_success = true;
if (this_present_success || that_present_success) {
- if (!(this_present_success && that_present_success)) {
- return false;
- }
- if (this.success != that.success) {
- return false;
- }
+ if (!(this_present_success && that_present_success))
+ return false;
+ if (this.success != that.success)
+ return false;
}
return true;
list.add(present_success);
if (present_success)
list.add(success);
+
return list.hashCode();
}
return 0;
}
- @Override
- public _Fields fieldForId(int fieldId) {
+ public _Fields fieldForId(int fieldId) {
return _Fields.findByThriftId(fieldId);
}
- @Override
- public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
+ public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
}
- @Override
- public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
+ public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
schemes.get(oprot.getScheme()).getScheme().write(oprot, this);
}
}
private static class setPeerSecret_resultStandardSchemeFactory implements SchemeFactory {
- @Override
- public setPeerSecret_resultStandardScheme getScheme() {
+ public setPeerSecret_resultStandardScheme getScheme() {
return new setPeerSecret_resultStandardScheme();
}
}
private static class setPeerSecret_resultStandardScheme extends StandardScheme<setPeerSecret_result> {
- @Override
- public void read(org.apache.thrift.protocol.TProtocol iprot, setPeerSecret_result struct) throws org.apache.thrift.TException {
+ public void read(org.apache.thrift.protocol.TProtocol iprot, setPeerSecret_result struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
iprot.readStructBegin();
while (true)
struct.validate();
}
- @Override
- public void write(org.apache.thrift.protocol.TProtocol oprot, setPeerSecret_result struct) throws org.apache.thrift.TException {
+ public void write(org.apache.thrift.protocol.TProtocol oprot, setPeerSecret_result struct) throws org.apache.thrift.TException {
struct.validate();
oprot.writeStructBegin(STRUCT_DESC);
}
private static class setPeerSecret_resultTupleSchemeFactory implements SchemeFactory {
- @Override
- public setPeerSecret_resultTupleScheme getScheme() {
+ public setPeerSecret_resultTupleScheme getScheme() {
return new setPeerSecret_resultTupleScheme();
}
}
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) {
- throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
- }
+ if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
return fields;
}
_fieldName = fieldName;
}
- @Override
- public short getThriftFieldId() {
+ public short getThriftFieldId() {
return _thriftId;
}
- @Override
- public String getFieldName() {
+ public String getFieldName() {
return _fieldName;
}
}
}
}
- @Override
- public deletePeer_args deepCopy() {
+ public deletePeer_args deepCopy() {
return new deletePeer_args(this);
}
}
}
- @Override
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, Object value) {
switch (field) {
case IP_ADDRESS:
if (value == null) {
}
}
- @Override
- public Object getFieldValue(_Fields field) {
+ public Object getFieldValue(_Fields field) {
switch (field) {
case IP_ADDRESS:
return getIpAddress();
}
/** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
- @Override
- public boolean isSet(_Fields field) {
+ public boolean isSet(_Fields field) {
if (field == null) {
throw new IllegalArgumentException();
}
@Override
public boolean equals(Object that) {
- if (that == null) {
- return false;
- }
- if (that instanceof deletePeer_args) {
- return this.equals((deletePeer_args)that);
- }
+ if (that == null)
+ return false;
+ if (that instanceof deletePeer_args)
+ return this.equals((deletePeer_args)that);
return false;
}
public boolean equals(deletePeer_args that) {
- if (that == null) {
- return false;
- }
+ if (that == null)
+ return false;
boolean this_present_ipAddress = true && this.isSetIpAddress();
boolean that_present_ipAddress = true && that.isSetIpAddress();
if (this_present_ipAddress || that_present_ipAddress) {
- if (!(this_present_ipAddress && that_present_ipAddress)) {
- return false;
- }
- if (!this.ipAddress.equals(that.ipAddress)) {
- return false;
- }
+ if (!(this_present_ipAddress && that_present_ipAddress))
+ return false;
+ if (!this.ipAddress.equals(that.ipAddress))
+ return false;
}
return true;
list.add(present_ipAddress);
if (present_ipAddress)
list.add(ipAddress);
+
return list.hashCode();
}
return 0;
}
- @Override
- public _Fields fieldForId(int fieldId) {
+ public _Fields fieldForId(int fieldId) {
return _Fields.findByThriftId(fieldId);
}
- @Override
- public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
+ public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
}
- @Override
- public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
+ public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
schemes.get(oprot.getScheme()).getScheme().write(oprot, this);
}
}
private static class deletePeer_argsStandardSchemeFactory implements SchemeFactory {
- @Override
- public deletePeer_argsStandardScheme getScheme() {
+ public deletePeer_argsStandardScheme getScheme() {
return new deletePeer_argsStandardScheme();
}
}
private static class deletePeer_argsStandardScheme extends StandardScheme<deletePeer_args> {
- @Override
- public void read(org.apache.thrift.protocol.TProtocol iprot, deletePeer_args struct) throws org.apache.thrift.TException {
+ public void read(org.apache.thrift.protocol.TProtocol iprot, deletePeer_args struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
iprot.readStructBegin();
while (true)
struct.validate();
}
- @Override
- public void write(org.apache.thrift.protocol.TProtocol oprot, deletePeer_args struct) throws org.apache.thrift.TException {
+ public void write(org.apache.thrift.protocol.TProtocol oprot, deletePeer_args struct) throws org.apache.thrift.TException {
struct.validate();
oprot.writeStructBegin(STRUCT_DESC);
}
private static class deletePeer_argsTupleSchemeFactory implements SchemeFactory {
- @Override
- public deletePeer_argsTupleScheme getScheme() {
+ public deletePeer_argsTupleScheme getScheme() {
return new deletePeer_argsTupleScheme();
}
}
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) {
- throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
- }
+ if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
return fields;
}
_fieldName = fieldName;
}
- @Override
- public short getThriftFieldId() {
+ public short getThriftFieldId() {
return _thriftId;
}
- @Override
- public String getFieldName() {
+ public String getFieldName() {
return _fieldName;
}
}
this.success = other.success;
}
- @Override
- public deletePeer_result deepCopy() {
+ public deletePeer_result deepCopy() {
return new deletePeer_result(this);
}
__isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __SUCCESS_ISSET_ID, value);
}
- @Override
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, Object value) {
switch (field) {
case SUCCESS:
if (value == null) {
}
}
- @Override
- public Object getFieldValue(_Fields field) {
+ public Object getFieldValue(_Fields field) {
switch (field) {
case SUCCESS:
- return Integer.valueOf(getSuccess());
+ return getSuccess();
}
throw new IllegalStateException();
}
/** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
- @Override
- public boolean isSet(_Fields field) {
+ public boolean isSet(_Fields field) {
if (field == null) {
throw new IllegalArgumentException();
}
@Override
public boolean equals(Object that) {
- if (that == null) {
- return false;
- }
- if (that instanceof deletePeer_result) {
- return this.equals((deletePeer_result)that);
- }
+ if (that == null)
+ return false;
+ if (that instanceof deletePeer_result)
+ return this.equals((deletePeer_result)that);
return false;
}
public boolean equals(deletePeer_result that) {
- if (that == null) {
- return false;
- }
+ if (that == null)
+ return false;
boolean this_present_success = true;
boolean that_present_success = true;
if (this_present_success || that_present_success) {
- if (!(this_present_success && that_present_success)) {
- return false;
- }
- if (this.success != that.success) {
- return false;
- }
+ if (!(this_present_success && that_present_success))
+ return false;
+ if (this.success != that.success)
+ return false;
}
return true;
list.add(present_success);
if (present_success)
list.add(success);
+
return list.hashCode();
}
return 0;
}
- @Override
- public _Fields fieldForId(int fieldId) {
+ public _Fields fieldForId(int fieldId) {
return _Fields.findByThriftId(fieldId);
}
- @Override
- public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
+ public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
}
- @Override
- public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
+ public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
schemes.get(oprot.getScheme()).getScheme().write(oprot, this);
}
}
private static class deletePeer_resultStandardSchemeFactory implements SchemeFactory {
- @Override
- public deletePeer_resultStandardScheme getScheme() {
+ public deletePeer_resultStandardScheme getScheme() {
return new deletePeer_resultStandardScheme();
}
}
private static class deletePeer_resultStandardScheme extends StandardScheme<deletePeer_result> {
- @Override
- public void read(org.apache.thrift.protocol.TProtocol iprot, deletePeer_result struct) throws org.apache.thrift.TException {
+ public void read(org.apache.thrift.protocol.TProtocol iprot, deletePeer_result struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
iprot.readStructBegin();
while (true)
struct.validate();
}
- @Override
- public void write(org.apache.thrift.protocol.TProtocol oprot, deletePeer_result struct) throws org.apache.thrift.TException {
+ public void write(org.apache.thrift.protocol.TProtocol oprot, deletePeer_result struct) throws org.apache.thrift.TException {
struct.validate();
oprot.writeStructBegin(STRUCT_DESC);
}
private static class deletePeer_resultTupleSchemeFactory implements SchemeFactory {
- @Override
- public deletePeer_resultTupleScheme getScheme() {
+ public deletePeer_resultTupleScheme getScheme() {
return new deletePeer_resultTupleScheme();
}
}
public String rd; // required
public List<String> irts; // required
public List<String> erts; // required
+ /**
+ *
+ * @see af_afi
+ */
public af_afi afi; // required
+ /**
+ *
+ * @see af_safi
+ */
public af_safi safi; // required
/** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
RD((short)2, "rd"),
IRTS((short)3, "irts"),
ERTS((short)4, "erts"),
+ /**
+ *
+ * @see af_afi
+ */
AFI((short)5, "afi"),
+ /**
+ *
+ * @see af_safi
+ */
SAFI((short)6, "safi");
private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) {
- throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
- }
+ if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
return fields;
}
_fieldName = fieldName;
}
- @Override
- public short getThriftFieldId() {
+ public short getThriftFieldId() {
return _thriftId;
}
- @Override
- public String getFieldName() {
+ public String getFieldName() {
return _fieldName;
}
}
tmpMap.put(_Fields.ERTS, new org.apache.thrift.meta_data.FieldMetaData("erts", org.apache.thrift.TFieldRequirementType.DEFAULT,
new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING))));
- tmpMap.put(_Fields.AFI, new org.apache.thrift.meta_data.FieldMetaData("afi", org.apache.thrift.TFieldRequirementType.DEFAULT,
+ tmpMap.put(_Fields.AFI, new org.apache.thrift.meta_data.FieldMetaData("afi", org.apache.thrift.TFieldRequirementType.DEFAULT,
new org.apache.thrift.meta_data.EnumMetaData(org.apache.thrift.protocol.TType.ENUM, af_afi.class)));
- tmpMap.put(_Fields.SAFI, new org.apache.thrift.meta_data.FieldMetaData("safi", org.apache.thrift.TFieldRequirementType.DEFAULT,
+ tmpMap.put(_Fields.SAFI, new org.apache.thrift.meta_data.FieldMetaData("safi", org.apache.thrift.TFieldRequirementType.DEFAULT,
new org.apache.thrift.meta_data.EnumMetaData(org.apache.thrift.protocol.TType.ENUM, af_safi.class)));
metaDataMap = Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(addVrf_args.class, metaDataMap);
}
}
- @Override
- public addVrf_args deepCopy() {
+ public addVrf_args deepCopy() {
return new addVrf_args(this);
}
}
}
+ /**
+ *
+ * @see af_afi
+ */
public af_afi getAfi() {
return this.afi;
}
+ /**
+ *
+ * @see af_afi
+ */
public addVrf_args setAfi(af_afi afi) {
this.afi = afi;
return this;
this.afi = null;
}
+ /** Returns true if field afi is set (has been assigned a value) and false otherwise */
public boolean isSetAfi() {
return this.afi != null;
}
}
}
+ /**
+ *
+ * @see af_safi
+ */
public af_safi getSafi() {
return this.safi;
}
+ /**
+ *
+ * @see af_safi
+ */
public addVrf_args setSafi(af_safi safi) {
this.safi = safi;
return this;
this.safi = null;
}
+ /** Returns true if field safi is set (has been assigned a value) and false otherwise */
public boolean isSetSafi() {
return this.safi != null;
}
}
}
- @Override
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, Object value) {
switch (field) {
case L_TYPE:
if (value == null) {
}
}
- @Override
- public Object getFieldValue(_Fields field) {
+ public Object getFieldValue(_Fields field) {
switch (field) {
case L_TYPE:
return getL_type();
}
/** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
- @Override
- public boolean isSet(_Fields field) {
+ public boolean isSet(_Fields field) {
if (field == null) {
throw new IllegalArgumentException();
}
@Override
public boolean equals(Object that) {
- if (that == null) {
- return false;
- }
- if (that instanceof addVrf_args) {
- return this.equals((addVrf_args)that);
- }
+ if (that == null)
+ return false;
+ if (that instanceof addVrf_args)
+ return this.equals((addVrf_args)that);
return false;
}
public boolean equals(addVrf_args that) {
- if (that == null) {
- return false;
- }
+ if (that == null)
+ return false;
boolean this_present_l_type = true && this.isSetL_type();
boolean that_present_l_type = true && that.isSetL_type();
if (this_present_l_type || that_present_l_type) {
- if (!(this_present_l_type && that_present_l_type)) {
- return false;
- }
- if (!this.l_type.equals(that.l_type)) {
- return false;
- }
+ if (!(this_present_l_type && that_present_l_type))
+ return false;
+ if (!this.l_type.equals(that.l_type))
+ return false;
}
boolean this_present_rd = true && this.isSetRd();
boolean that_present_rd = true && that.isSetRd();
if (this_present_rd || that_present_rd) {
- if (!(this_present_rd && that_present_rd)) {
- return false;
- }
- if (!this.rd.equals(that.rd)) {
- return false;
- }
+ if (!(this_present_rd && that_present_rd))
+ return false;
+ if (!this.rd.equals(that.rd))
+ return false;
}
boolean this_present_irts = true && this.isSetIrts();
boolean that_present_irts = true && that.isSetIrts();
if (this_present_irts || that_present_irts) {
- if (!(this_present_irts && that_present_irts)) {
- return false;
- }
- if (!this.irts.equals(that.irts)) {
- return false;
- }
+ if (!(this_present_irts && that_present_irts))
+ return false;
+ if (!this.irts.equals(that.irts))
+ return false;
}
boolean this_present_erts = true && this.isSetErts();
boolean that_present_erts = true && that.isSetErts();
if (this_present_erts || that_present_erts) {
- if (!(this_present_erts && that_present_erts)) {
- return false;
- }
- if (!this.erts.equals(that.erts)) {
- return false;
- }
+ if (!(this_present_erts && that_present_erts))
+ return false;
+ if (!this.erts.equals(that.erts))
+ return false;
}
boolean this_present_afi = true && this.isSetAfi();
@Override
public int hashCode() {
List<Object> list = new ArrayList<Object>();
+
boolean present_l_type = true && (isSetL_type());
list.add(present_l_type);
if (present_l_type)
list.add(l_type.getValue());
+
boolean present_rd = true && (isSetRd());
list.add(present_rd);
if (present_rd)
list.add(rd);
+
boolean present_irts = true && (isSetIrts());
list.add(present_irts);
if (present_irts)
list.add(irts);
+
boolean present_erts = true && (isSetErts());
list.add(present_erts);
if (present_erts)
list.add(erts);
+
+ boolean present_afi = true && (isSetAfi());
+ list.add(present_afi);
+ if (present_afi)
+ list.add(afi.getValue());
+
+ boolean present_safi = true && (isSetSafi());
+ list.add(present_safi);
+ if (present_safi)
+ list.add(safi.getValue());
+
return list.hashCode();
}
return 0;
}
- @Override
- public _Fields fieldForId(int fieldId) {
+ public _Fields fieldForId(int fieldId) {
return _Fields.findByThriftId(fieldId);
}
- @Override
- public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
+ public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
}
- @Override
- public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
+ public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
schemes.get(oprot.getScheme()).getScheme().write(oprot, this);
}
sb.append(this.l_type);
}
first = false;
- if (!first) {
- sb.append(", ");
- }
+ if (!first) sb.append(", ");
sb.append("rd:");
if (this.rd == null) {
sb.append("null");
sb.append(this.rd);
}
first = false;
- if (!first) {
- sb.append(", ");
- }
+ if (!first) sb.append(", ");
sb.append("irts:");
if (this.irts == null) {
sb.append("null");
sb.append(this.irts);
}
first = false;
- if (!first) {
- sb.append(", ");
- }
+ if (!first) sb.append(", ");
sb.append("erts:");
if (this.erts == null) {
sb.append("null");
}
private static class addVrf_argsStandardSchemeFactory implements SchemeFactory {
- @Override
- public addVrf_argsStandardScheme getScheme() {
+ public addVrf_argsStandardScheme getScheme() {
return new addVrf_argsStandardScheme();
}
}
private static class addVrf_argsStandardScheme extends StandardScheme<addVrf_args> {
- @Override
- public void read(org.apache.thrift.protocol.TProtocol iprot, addVrf_args struct) throws org.apache.thrift.TException {
+ public void read(org.apache.thrift.protocol.TProtocol iprot, addVrf_args struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
iprot.readStructBegin();
while (true)
if (schemeField.type == org.apache.thrift.protocol.TType.LIST) {
{
org.apache.thrift.protocol.TList _list8 = iprot.readListBegin();
- struct.irts = new ArrayList<>(_list8.size);
- for (int _i9 = 0; _i9 < _list8.size; ++_i9)
+ struct.irts = new ArrayList<String>(_list8.size);
+ String _elem9;
+ for (int _i10 = 0; _i10 < _list8.size; ++_i10)
{
- String _elem10;
- _elem10 = iprot.readString();
- struct.irts.add(_elem10);
+ _elem9 = iprot.readString();
+ struct.irts.add(_elem9);
}
iprot.readListEnd();
}
if (schemeField.type == org.apache.thrift.protocol.TType.LIST) {
{
org.apache.thrift.protocol.TList _list11 = iprot.readListBegin();
- struct.erts = new ArrayList<>(_list11.size);
- for (int _i12 = 0; _i12 < _list11.size; ++_i12)
+ struct.erts = new ArrayList<String>(_list11.size);
+ String _elem12;
+ for (int _i13 = 0; _i13 < _list11.size; ++_i13)
{
- String _elem13;
- _elem13 = iprot.readString();
- struct.erts.add(_elem13);
+ _elem12 = iprot.readString();
+ struct.erts.add(_elem12);
}
iprot.readListEnd();
}
struct.validate();
}
- @Override
- public void write(org.apache.thrift.protocol.TProtocol oprot, addVrf_args struct) throws org.apache.thrift.TException {
+ public void write(org.apache.thrift.protocol.TProtocol oprot, addVrf_args struct) throws org.apache.thrift.TException {
struct.validate();
oprot.writeStructBegin(STRUCT_DESC);
}
private static class addVrf_argsTupleSchemeFactory implements SchemeFactory {
- @Override
- public addVrf_argsTupleScheme getScheme() {
+ public addVrf_argsTupleScheme getScheme() {
return new addVrf_argsTupleScheme();
}
}
oprot.writeString(_iter17);
}
}
+ }
if (struct.isSetAfi()) {
oprot.writeI32(struct.afi.getValue());
}
if (struct.isSetSafi()) {
oprot.writeI32(struct.safi.getValue());
}
- }
}
@Override
if (incoming.get(2)) {
{
org.apache.thrift.protocol.TList _list18 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32());
- struct.irts = new ArrayList<>(_list18.size);
- for (int _i19 = 0; _i19 < _list18.size; ++_i19)
+ struct.irts = new ArrayList<String>(_list18.size);
+ String _elem19;
+ for (int _i20 = 0; _i20 < _list18.size; ++_i20)
{
- String _elem20;
- _elem20 = iprot.readString();
- struct.irts.add(_elem20);
+ _elem19 = iprot.readString();
+ struct.irts.add(_elem19);
}
}
struct.setIrtsIsSet(true);
if (incoming.get(3)) {
{
org.apache.thrift.protocol.TList _list21 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32());
- struct.erts = new ArrayList<>(_list21.size);
- for (int _i22 = 0; _i22 < _list21.size; ++_i22)
+ struct.erts = new ArrayList<String>(_list21.size);
+ String _elem22;
+ for (int _i23 = 0; _i23 < _list21.size; ++_i23)
{
- String _elem23;
- _elem23 = iprot.readString();
- struct.erts.add(_elem23);
+ _elem22 = iprot.readString();
+ struct.erts.add(_elem22);
}
}
struct.setErtsIsSet(true);
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) {
- throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
- }
+ if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
return fields;
}
_fieldName = fieldName;
}
- @Override
- public short getThriftFieldId() {
+ public short getThriftFieldId() {
return _thriftId;
}
- @Override
- public String getFieldName() {
+ public String getFieldName() {
return _fieldName;
}
}
this.success = other.success;
}
- @Override
- public addVrf_result deepCopy() {
+ public addVrf_result deepCopy() {
return new addVrf_result(this);
}
__isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __SUCCESS_ISSET_ID, value);
}
- @Override
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, Object value) {
switch (field) {
case SUCCESS:
if (value == null) {
}
}
- @Override
- public Object getFieldValue(_Fields field) {
+ public Object getFieldValue(_Fields field) {
switch (field) {
case SUCCESS:
- return Integer.valueOf(getSuccess());
+ return getSuccess();
}
throw new IllegalStateException();
}
/** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
- @Override
- public boolean isSet(_Fields field) {
+ public boolean isSet(_Fields field) {
if (field == null) {
throw new IllegalArgumentException();
}
@Override
public boolean equals(Object that) {
- if (that == null) {
- return false;
- }
- if (that instanceof addVrf_result) {
- return this.equals((addVrf_result)that);
- }
+ if (that == null)
+ return false;
+ if (that instanceof addVrf_result)
+ return this.equals((addVrf_result)that);
return false;
}
public boolean equals(addVrf_result that) {
- if (that == null) {
- return false;
- }
+ if (that == null)
+ return false;
boolean this_present_success = true;
boolean that_present_success = true;
if (this_present_success || that_present_success) {
- if (!(this_present_success && that_present_success)) {
- return false;
- }
- if (this.success != that.success) {
- return false;
- }
+ if (!(this_present_success && that_present_success))
+ return false;
+ if (this.success != that.success)
+ return false;
}
return true;
list.add(present_success);
if (present_success)
list.add(success);
+
return list.hashCode();
}
return 0;
}
- @Override
- public _Fields fieldForId(int fieldId) {
+ public _Fields fieldForId(int fieldId) {
return _Fields.findByThriftId(fieldId);
}
- @Override
- public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
+ public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
}
- @Override
- public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
+ public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
schemes.get(oprot.getScheme()).getScheme().write(oprot, this);
}
}
private static class addVrf_resultStandardSchemeFactory implements SchemeFactory {
- @Override
- public addVrf_resultStandardScheme getScheme() {
+ public addVrf_resultStandardScheme getScheme() {
return new addVrf_resultStandardScheme();
}
}
private static class addVrf_resultStandardScheme extends StandardScheme<addVrf_result> {
- @Override
- public void read(org.apache.thrift.protocol.TProtocol iprot, addVrf_result struct) throws org.apache.thrift.TException {
+ public void read(org.apache.thrift.protocol.TProtocol iprot, addVrf_result struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
iprot.readStructBegin();
while (true)
struct.validate();
}
- @Override
- public void write(org.apache.thrift.protocol.TProtocol oprot, addVrf_result struct) throws org.apache.thrift.TException {
+ public void write(org.apache.thrift.protocol.TProtocol oprot, addVrf_result struct) throws org.apache.thrift.TException {
struct.validate();
oprot.writeStructBegin(STRUCT_DESC);
}
private static class addVrf_resultTupleSchemeFactory implements SchemeFactory {
- @Override
- public addVrf_resultTupleScheme getScheme() {
+ public addVrf_resultTupleScheme getScheme() {
return new addVrf_resultTupleScheme();
}
}
}
public String rd; // required
+ /**
+ *
+ * @see af_afi
+ */
public af_afi afi; // required
+ /**
+ *
+ * @see af_safi
+ */
public af_safi safi; // required
/** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
public enum _Fields implements org.apache.thrift.TFieldIdEnum {
RD((short)1, "rd"),
+ /**
+ *
+ * @see af_afi
+ */
AFI((short)2, "afi"),
+ /**
+ *
+ * @see af_safi
+ */
SAFI((short)3, "safi");
private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) {
- throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
- }
+ if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
return fields;
}
_fieldName = fieldName;
}
- @Override
- public short getThriftFieldId() {
+ public short getThriftFieldId() {
return _thriftId;
}
- @Override
- public String getFieldName() {
+ public String getFieldName() {
return _fieldName;
}
}
Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
tmpMap.put(_Fields.RD, new org.apache.thrift.meta_data.FieldMetaData("rd", org.apache.thrift.TFieldRequirementType.DEFAULT,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
- tmpMap.put(_Fields.AFI, new org.apache.thrift.meta_data.FieldMetaData("afi", org.apache.thrift.TFieldRequirementType.DEFAULT,
+ tmpMap.put(_Fields.AFI, new org.apache.thrift.meta_data.FieldMetaData("afi", org.apache.thrift.TFieldRequirementType.DEFAULT,
new org.apache.thrift.meta_data.EnumMetaData(org.apache.thrift.protocol.TType.ENUM, af_afi.class)));
- tmpMap.put(_Fields.SAFI, new org.apache.thrift.meta_data.FieldMetaData("safi", org.apache.thrift.TFieldRequirementType.DEFAULT,
+ tmpMap.put(_Fields.SAFI, new org.apache.thrift.meta_data.FieldMetaData("safi", org.apache.thrift.TFieldRequirementType.DEFAULT,
new org.apache.thrift.meta_data.EnumMetaData(org.apache.thrift.protocol.TType.ENUM, af_safi.class)));
metaDataMap = Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(delVrf_args.class, metaDataMap);
}
}
- @Override
- public delVrf_args deepCopy() {
+ public delVrf_args deepCopy() {
return new delVrf_args(this);
}
}
}
+ /**
+ *
+ * @see af_afi
+ */
public af_afi getAfi() {
return this.afi;
}
+ /**
+ *
+ * @see af_afi
+ */
public delVrf_args setAfi(af_afi afi) {
this.afi = afi;
return this;
}
}
+ /**
+ *
+ * @see af_safi
+ */
public af_safi getSafi() {
return this.safi;
}
+ /**
+ *
+ * @see af_safi
+ */
public delVrf_args setSafi(af_safi safi) {
this.safi = safi;
return this;
}
}
- @Override
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, Object value) {
switch (field) {
case RD:
if (value == null) {
}
}
- @Override
- public Object getFieldValue(_Fields field) {
+ public Object getFieldValue(_Fields field) {
switch (field) {
case RD:
return getRd();
}
/** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
- @Override
- public boolean isSet(_Fields field) {
+ public boolean isSet(_Fields field) {
if (field == null) {
throw new IllegalArgumentException();
}
@Override
public boolean equals(Object that) {
- if (that == null) {
- return false;
- }
- if (that instanceof delVrf_args) {
- return this.equals((delVrf_args)that);
- }
+ if (that == null)
+ return false;
+ if (that instanceof delVrf_args)
+ return this.equals((delVrf_args)that);
return false;
}
public boolean equals(delVrf_args that) {
- if (that == null) {
- return false;
- }
+ if (that == null)
+ return false;
boolean this_present_rd = true && this.isSetRd();
boolean that_present_rd = true && that.isSetRd();
if (this_present_rd || that_present_rd) {
- if (!(this_present_rd && that_present_rd)) {
- return false;
- }
- if (!this.rd.equals(that.rd)) {
- return false;
- }
+ if (!(this_present_rd && that_present_rd))
+ return false;
+ if (!this.rd.equals(that.rd))
+ return false;
}
boolean this_present_afi = true && this.isSetAfi();
@Override
public int hashCode() {
List<Object> list = new ArrayList<Object>();
+
boolean present_rd = true && (isSetRd());
list.add(present_rd);
if (present_rd)
list.add(rd);
+
+ boolean present_afi = true && (isSetAfi());
+ list.add(present_afi);
+ if (present_afi)
+ list.add(afi.getValue());
+
+ boolean present_safi = true && (isSetSafi());
+ list.add(present_safi);
+ if (present_safi)
+ list.add(safi.getValue());
+
return list.hashCode();
}
return 0;
}
- @Override
- public _Fields fieldForId(int fieldId) {
+ public _Fields fieldForId(int fieldId) {
return _Fields.findByThriftId(fieldId);
}
- @Override
- public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
+ public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
}
- @Override
- public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
+ public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
schemes.get(oprot.getScheme()).getScheme().write(oprot, this);
}
}
private static class delVrf_argsStandardSchemeFactory implements SchemeFactory {
- @Override
- public delVrf_argsStandardScheme getScheme() {
+ public delVrf_argsStandardScheme getScheme() {
return new delVrf_argsStandardScheme();
}
}
private static class delVrf_argsStandardScheme extends StandardScheme<delVrf_args> {
- @Override
- public void read(org.apache.thrift.protocol.TProtocol iprot, delVrf_args struct) throws org.apache.thrift.TException {
+ public void read(org.apache.thrift.protocol.TProtocol iprot, delVrf_args struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
iprot.readStructBegin();
while (true)
struct.validate();
}
- @Override
- public void write(org.apache.thrift.protocol.TProtocol oprot, delVrf_args struct) throws org.apache.thrift.TException {
+ public void write(org.apache.thrift.protocol.TProtocol oprot, delVrf_args struct) throws org.apache.thrift.TException {
struct.validate();
oprot.writeStructBegin(STRUCT_DESC);
}
private static class delVrf_argsTupleSchemeFactory implements SchemeFactory {
- @Override
- public delVrf_argsTupleScheme getScheme() {
+ public delVrf_argsTupleScheme getScheme() {
return new delVrf_argsTupleScheme();
}
}
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) {
- throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
- }
+ if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
return fields;
}
_fieldName = fieldName;
}
- @Override
- public short getThriftFieldId() {
+ public short getThriftFieldId() {
return _thriftId;
}
- @Override
- public String getFieldName() {
+ public String getFieldName() {
return _fieldName;
}
}
this.success = other.success;
}
- @Override
- public delVrf_result deepCopy() {
+ public delVrf_result deepCopy() {
return new delVrf_result(this);
}
__isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __SUCCESS_ISSET_ID, value);
}
- @Override
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, Object value) {
switch (field) {
case SUCCESS:
if (value == null) {
}
}
- @Override
- public Object getFieldValue(_Fields field) {
+ public Object getFieldValue(_Fields field) {
switch (field) {
case SUCCESS:
- return Integer.valueOf(getSuccess());
+ return getSuccess();
}
throw new IllegalStateException();
}
/** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
- @Override
- public boolean isSet(_Fields field) {
+ public boolean isSet(_Fields field) {
if (field == null) {
throw new IllegalArgumentException();
}
@Override
public boolean equals(Object that) {
- if (that == null) {
- return false;
- }
- if (that instanceof delVrf_result) {
- return this.equals((delVrf_result)that);
- }
+ if (that == null)
+ return false;
+ if (that instanceof delVrf_result)
+ return this.equals((delVrf_result)that);
return false;
}
public boolean equals(delVrf_result that) {
- if (that == null) {
- return false;
- }
+ if (that == null)
+ return false;
boolean this_present_success = true;
boolean that_present_success = true;
if (this_present_success || that_present_success) {
- if (!(this_present_success && that_present_success)) {
- return false;
- }
- if (this.success != that.success) {
- return false;
- }
+ if (!(this_present_success && that_present_success))
+ return false;
+ if (this.success != that.success)
+ return false;
}
return true;
list.add(present_success);
if (present_success)
list.add(success);
+
return list.hashCode();
}
return 0;
}
- @Override
- public _Fields fieldForId(int fieldId) {
+ public _Fields fieldForId(int fieldId) {
return _Fields.findByThriftId(fieldId);
}
- @Override
- public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
+ public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
}
- @Override
- public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
+ public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
schemes.get(oprot.getScheme()).getScheme().write(oprot, this);
}
}
private static class delVrf_resultStandardSchemeFactory implements SchemeFactory {
- @Override
- public delVrf_resultStandardScheme getScheme() {
+ public delVrf_resultStandardScheme getScheme() {
return new delVrf_resultStandardScheme();
}
}
private static class delVrf_resultStandardScheme extends StandardScheme<delVrf_result> {
- @Override
- public void read(org.apache.thrift.protocol.TProtocol iprot, delVrf_result struct) throws org.apache.thrift.TException {
+ public void read(org.apache.thrift.protocol.TProtocol iprot, delVrf_result struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
iprot.readStructBegin();
while (true)
struct.validate();
}
- @Override
- public void write(org.apache.thrift.protocol.TProtocol oprot, delVrf_result struct) throws org.apache.thrift.TException {
+ public void write(org.apache.thrift.protocol.TProtocol oprot, delVrf_result struct) throws org.apache.thrift.TException {
struct.validate();
oprot.writeStructBegin(STRUCT_DESC);
}
private static class delVrf_resultTupleSchemeFactory implements SchemeFactory {
- @Override
- public delVrf_resultTupleScheme getScheme() {
+ public delVrf_resultTupleScheme getScheme() {
return new delVrf_resultTupleScheme();
}
}
private static final org.apache.thrift.protocol.TField PREFIX_FIELD_DESC = new org.apache.thrift.protocol.TField("prefix", org.apache.thrift.protocol.TType.STRING, (short)2);
private static final org.apache.thrift.protocol.TField NEXTHOP_FIELD_DESC = new org.apache.thrift.protocol.TField("nexthop", org.apache.thrift.protocol.TType.STRING, (short)3);
private static final org.apache.thrift.protocol.TField RD_FIELD_DESC = new org.apache.thrift.protocol.TField("rd", org.apache.thrift.protocol.TType.STRING, (short)4);
- private static final org.apache.thrift.protocol.TField ETHTAG_FIELD_DESC = new org.apache.thrift.protocol.TField("ethtag", org.apache.thrift.protocol.TType.I32, (short)5);
+ private static final org.apache.thrift.protocol.TField ETHTAG_FIELD_DESC = new org.apache.thrift.protocol.TField("ethtag", org.apache.thrift.protocol.TType.I64, (short)5);
private static final org.apache.thrift.protocol.TField ESI_FIELD_DESC = new org.apache.thrift.protocol.TField("esi", org.apache.thrift.protocol.TType.STRING, (short)6);
private static final org.apache.thrift.protocol.TField MACADDRESS_FIELD_DESC = new org.apache.thrift.protocol.TField("macaddress", org.apache.thrift.protocol.TType.STRING, (short)7);
private static final org.apache.thrift.protocol.TField L3LABEL_FIELD_DESC = new org.apache.thrift.protocol.TField("l3label", org.apache.thrift.protocol.TType.I32, (short)8);
public String prefix; // required
public String nexthop; // required
public String rd; // required
- public int ethtag; // required
+ public long ethtag; // required
public String esi; // required
public String macaddress; // required
public int l3label; // required
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) {
- throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
- }
+ if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
return fields;
}
_fieldName = fieldName;
}
- @Override
- public short getThriftFieldId() {
+ public short getThriftFieldId() {
return _thriftId;
}
- @Override
- public String getFieldName() {
+ public String getFieldName() {
return _fieldName;
}
}
tmpMap.put(_Fields.RD, new org.apache.thrift.meta_data.FieldMetaData("rd", org.apache.thrift.TFieldRequirementType.DEFAULT,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
tmpMap.put(_Fields.ETHTAG, new org.apache.thrift.meta_data.FieldMetaData("ethtag", org.apache.thrift.TFieldRequirementType.DEFAULT,
- new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I32)));
+ new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
tmpMap.put(_Fields.ESI, new org.apache.thrift.meta_data.FieldMetaData("esi", org.apache.thrift.TFieldRequirementType.DEFAULT,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
tmpMap.put(_Fields.MACADDRESS, new org.apache.thrift.meta_data.FieldMetaData("macaddress", org.apache.thrift.TFieldRequirementType.DEFAULT,
String prefix,
String nexthop,
String rd,
- int ethtag,
+ long ethtag,
String esi,
String macaddress,
int l3label,
}
}
- @Override
- public pushRoute_args deepCopy() {
+ public pushRoute_args deepCopy() {
return new pushRoute_args(this);
}
}
}
- public int getEthtag() {
+ public long getEthtag() {
return this.ethtag;
}
- public pushRoute_args setEthtag(int ethtag) {
+ public pushRoute_args setEthtag(long ethtag) {
this.ethtag = ethtag;
setEthtagIsSet(true);
return this;
}
}
- @Override
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, Object value) {
switch (field) {
case P_TYPE:
if (value == null) {
if (value == null) {
unsetEthtag();
} else {
- setEthtag((Integer)value);
+ setEthtag((Long)value);
}
break;
}
}
- @Override
- public Object getFieldValue(_Fields field) {
+ public Object getFieldValue(_Fields field) {
switch (field) {
case P_TYPE:
return getP_type();
return getRd();
case ETHTAG:
- return Integer.valueOf(getEthtag());
+ return getEthtag();
case ESI:
return getEsi();
return getMacaddress();
case L3LABEL:
- return Integer.valueOf(getL3label());
+ return getL3label();
case L2LABEL:
- return Integer.valueOf(getL2label());
+ return getL2label();
case ENC_TYPE:
return getEnc_type();
}
/** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
- @Override
- public boolean isSet(_Fields field) {
+ public boolean isSet(_Fields field) {
if (field == null) {
throw new IllegalArgumentException();
}
@Override
public boolean equals(Object that) {
- if (that == null) {
- return false;
- }
- if (that instanceof pushRoute_args) {
- return this.equals((pushRoute_args)that);
- }
+ if (that == null)
+ return false;
+ if (that instanceof pushRoute_args)
+ return this.equals((pushRoute_args)that);
return false;
}
public boolean equals(pushRoute_args that) {
- if (that == null) {
- return false;
- }
+ if (that == null)
+ return false;
boolean this_present_p_type = true && this.isSetP_type();
boolean that_present_p_type = true && that.isSetP_type();
if (this_present_p_type || that_present_p_type) {
- if (!(this_present_p_type && that_present_p_type)) {
- return false;
- }
- if (!this.p_type.equals(that.p_type)) {
- return false;
- }
+ if (!(this_present_p_type && that_present_p_type))
+ return false;
+ if (!this.p_type.equals(that.p_type))
+ return false;
}
boolean this_present_prefix = true && this.isSetPrefix();
boolean that_present_prefix = true && that.isSetPrefix();
if (this_present_prefix || that_present_prefix) {
- if (!(this_present_prefix && that_present_prefix)) {
- return false;
- }
- if (!this.prefix.equals(that.prefix)) {
- return false;
- }
+ if (!(this_present_prefix && that_present_prefix))
+ return false;
+ if (!this.prefix.equals(that.prefix))
+ return false;
}
boolean this_present_nexthop = true && this.isSetNexthop();
boolean that_present_nexthop = true && that.isSetNexthop();
if (this_present_nexthop || that_present_nexthop) {
- if (!(this_present_nexthop && that_present_nexthop)) {
- return false;
- }
- if (!this.nexthop.equals(that.nexthop)) {
- return false;
- }
+ if (!(this_present_nexthop && that_present_nexthop))
+ return false;
+ if (!this.nexthop.equals(that.nexthop))
+ return false;
}
boolean this_present_rd = true && this.isSetRd();
boolean that_present_rd = true && that.isSetRd();
if (this_present_rd || that_present_rd) {
- if (!(this_present_rd && that_present_rd)) {
- return false;
- }
- if (!this.rd.equals(that.rd)) {
- return false;
- }
+ if (!(this_present_rd && that_present_rd))
+ return false;
+ if (!this.rd.equals(that.rd))
+ return false;
}
boolean this_present_ethtag = true;
boolean that_present_ethtag = true;
if (this_present_ethtag || that_present_ethtag) {
- if (!(this_present_ethtag && that_present_ethtag)) {
- return false;
- }
- if (this.ethtag != that.ethtag) {
- return false;
- }
+ if (!(this_present_ethtag && that_present_ethtag))
+ return false;
+ if (this.ethtag != that.ethtag)
+ return false;
}
boolean this_present_esi = true && this.isSetEsi();
boolean that_present_esi = true && that.isSetEsi();
if (this_present_esi || that_present_esi) {
- if (!(this_present_esi && that_present_esi)) {
- return false;
- }
- if (!this.esi.equals(that.esi)) {
- return false;
- }
+ if (!(this_present_esi && that_present_esi))
+ return false;
+ if (!this.esi.equals(that.esi))
+ return false;
}
boolean this_present_macaddress = true && this.isSetMacaddress();
boolean that_present_macaddress = true && that.isSetMacaddress();
if (this_present_macaddress || that_present_macaddress) {
- if (!(this_present_macaddress && that_present_macaddress)) {
- return false;
- }
- if (!this.macaddress.equals(that.macaddress)) {
- return false;
- }
+ if (!(this_present_macaddress && that_present_macaddress))
+ return false;
+ if (!this.macaddress.equals(that.macaddress))
+ return false;
}
boolean this_present_l3label = true;
boolean that_present_l3label = true;
if (this_present_l3label || that_present_l3label) {
- if (!(this_present_l3label && that_present_l3label)) {
- return false;
- }
- if (this.l3label != that.l3label) {
- return false;
- }
+ if (!(this_present_l3label && that_present_l3label))
+ return false;
+ if (this.l3label != that.l3label)
+ return false;
}
boolean this_present_l2label = true;
boolean that_present_l2label = true;
if (this_present_l2label || that_present_l2label) {
- if (!(this_present_l2label && that_present_l2label)) {
- return false;
- }
- if (this.l2label != that.l2label) {
- return false;
- }
+ if (!(this_present_l2label && that_present_l2label))
+ return false;
+ if (this.l2label != that.l2label)
+ return false;
}
boolean this_present_enc_type = true && this.isSetEnc_type();
boolean that_present_enc_type = true && that.isSetEnc_type();
if (this_present_enc_type || that_present_enc_type) {
- if (!(this_present_enc_type && that_present_enc_type)) {
- return false;
- }
- if (!this.enc_type.equals(that.enc_type)) {
- return false;
- }
+ if (!(this_present_enc_type && that_present_enc_type))
+ return false;
+ if (!this.enc_type.equals(that.enc_type))
+ return false;
}
boolean this_present_routermac = true && this.isSetRoutermac();
boolean that_present_routermac = true && that.isSetRoutermac();
if (this_present_routermac || that_present_routermac) {
- if (!(this_present_routermac && that_present_routermac)) {
- return false;
- }
- if (!this.routermac.equals(that.routermac)) {
- return false;
- }
+ if (!(this_present_routermac && that_present_routermac))
+ return false;
+ if (!this.routermac.equals(that.routermac))
+ return false;
}
boolean this_present_afi = true && this.isSetAfi();
boolean that_present_afi = true && that.isSetAfi();
if (this_present_afi || that_present_afi) {
- if (!(this_present_afi && that_present_afi)) {
- return false;
- }
- if (!this.afi.equals(that.afi)) {
- return false;
- }
+ if (!(this_present_afi && that_present_afi))
+ return false;
+ if (!this.afi.equals(that.afi))
+ return false;
}
return true;
@Override
public int hashCode() {
List<Object> list = new ArrayList<Object>();
+
boolean present_p_type = true && (isSetP_type());
list.add(present_p_type);
if (present_p_type)
list.add(p_type.getValue());
+
boolean present_prefix = true && (isSetPrefix());
list.add(present_prefix);
if (present_prefix)
list.add(prefix);
+
boolean present_nexthop = true && (isSetNexthop());
list.add(present_nexthop);
if (present_nexthop)
list.add(nexthop);
+
boolean present_rd = true && (isSetRd());
list.add(present_rd);
if (present_rd)
list.add(rd);
+
boolean present_ethtag = true;
list.add(present_ethtag);
if (present_ethtag)
list.add(ethtag);
+
boolean present_esi = true && (isSetEsi());
list.add(present_esi);
if (present_esi)
list.add(esi);
+
boolean present_macaddress = true && (isSetMacaddress());
list.add(present_macaddress);
if (present_macaddress)
list.add(macaddress);
+
boolean present_l3label = true;
list.add(present_l3label);
if (present_l3label)
list.add(l3label);
+
boolean present_l2label = true;
list.add(present_l2label);
if (present_l2label)
list.add(l2label);
+
boolean present_enc_type = true && (isSetEnc_type());
list.add(present_enc_type);
if (present_enc_type)
list.add(enc_type.getValue());
+
boolean present_routermac = true && (isSetRoutermac());
list.add(present_routermac);
if (present_routermac)
list.add(routermac);
+
boolean present_afi = true && (isSetAfi());
list.add(present_afi);
if (present_afi)
list.add(afi.getValue());
+
return list.hashCode();
}
return 0;
}
- @Override
- public _Fields fieldForId(int fieldId) {
+ public _Fields fieldForId(int fieldId) {
return _Fields.findByThriftId(fieldId);
}
- @Override
- public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
+ public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
}
- @Override
- public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
+ public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
schemes.get(oprot.getScheme()).getScheme().write(oprot, this);
}
sb.append(this.p_type);
}
first = false;
- if (!first) {
- sb.append(", ");
- }
+ if (!first) sb.append(", ");
sb.append("prefix:");
if (this.prefix == null) {
sb.append("null");
sb.append(this.prefix);
}
first = false;
- if (!first) {
- sb.append(", ");
- }
+ if (!first) sb.append(", ");
sb.append("nexthop:");
if (this.nexthop == null) {
sb.append("null");
sb.append(this.nexthop);
}
first = false;
- if (!first) {
- sb.append(", ");
- }
+ if (!first) sb.append(", ");
sb.append("rd:");
if (this.rd == null) {
sb.append("null");
sb.append(this.rd);
}
first = false;
- if (!first) {
- sb.append(", ");
- }
+ if (!first) sb.append(", ");
sb.append("ethtag:");
sb.append(this.ethtag);
first = false;
- if (!first) {
- sb.append(", ");
- }
+ if (!first) sb.append(", ");
sb.append("esi:");
if (this.esi == null) {
sb.append("null");
sb.append(this.esi);
}
first = false;
- if (!first) {
- sb.append(", ");
- }
+ if (!first) sb.append(", ");
sb.append("macaddress:");
if (this.macaddress == null) {
sb.append("null");
sb.append(this.macaddress);
}
first = false;
- if (!first) {
- sb.append(", ");
- }
+ if (!first) sb.append(", ");
sb.append("l3label:");
sb.append(this.l3label);
first = false;
- if (!first) {
- sb.append(", ");
- }
+ if (!first) sb.append(", ");
sb.append("l2label:");
sb.append(this.l2label);
first = false;
- if (!first) {
- sb.append(", ");
- }
+ if (!first) sb.append(", ");
sb.append("enc_type:");
if (this.enc_type == null) {
sb.append("null");
sb.append(this.enc_type);
}
first = false;
- if (!first) {
- sb.append(", ");
- }
+ if (!first) sb.append(", ");
sb.append("routermac:");
if (this.routermac == null) {
sb.append("null");
sb.append(this.routermac);
}
first = false;
- if (!first) {
- sb.append(", ");
- }
+ if (!first) sb.append(", ");
sb.append("afi:");
if (this.afi == null) {
sb.append("null");
}
private static class pushRoute_argsStandardSchemeFactory implements SchemeFactory {
- @Override
- public pushRoute_argsStandardScheme getScheme() {
+ public pushRoute_argsStandardScheme getScheme() {
return new pushRoute_argsStandardScheme();
}
}
private static class pushRoute_argsStandardScheme extends StandardScheme<pushRoute_args> {
- @Override
- public void read(org.apache.thrift.protocol.TProtocol iprot, pushRoute_args struct) throws org.apache.thrift.TException {
+ public void read(org.apache.thrift.protocol.TProtocol iprot, pushRoute_args struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
iprot.readStructBegin();
while (true)
}
break;
case 5: // ETHTAG
- if (schemeField.type == org.apache.thrift.protocol.TType.I32) {
- struct.ethtag = iprot.readI32();
+ if (schemeField.type == org.apache.thrift.protocol.TType.I64) {
+ struct.ethtag = iprot.readI64();
struct.setEthtagIsSet(true);
} else {
org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
struct.validate();
}
- @Override
- public void write(org.apache.thrift.protocol.TProtocol oprot, pushRoute_args struct) throws org.apache.thrift.TException {
+ public void write(org.apache.thrift.protocol.TProtocol oprot, pushRoute_args struct) throws org.apache.thrift.TException {
struct.validate();
oprot.writeStructBegin(STRUCT_DESC);
oprot.writeFieldEnd();
}
oprot.writeFieldBegin(ETHTAG_FIELD_DESC);
- oprot.writeI32(struct.ethtag);
+ oprot.writeI64(struct.ethtag);
oprot.writeFieldEnd();
if (struct.esi != null) {
oprot.writeFieldBegin(ESI_FIELD_DESC);
}
private static class pushRoute_argsTupleSchemeFactory implements SchemeFactory {
- @Override
- public pushRoute_argsTupleScheme getScheme() {
+ public pushRoute_argsTupleScheme getScheme() {
return new pushRoute_argsTupleScheme();
}
}
oprot.writeString(struct.rd);
}
if (struct.isSetEthtag()) {
- oprot.writeI32(struct.ethtag);
+ oprot.writeI64(struct.ethtag);
}
if (struct.isSetEsi()) {
oprot.writeString(struct.esi);
struct.setRdIsSet(true);
}
if (incoming.get(4)) {
- struct.ethtag = iprot.readI32();
+ struct.ethtag = iprot.readI64();
struct.setEthtagIsSet(true);
}
if (incoming.get(5)) {
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) {
- throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
- }
+ if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
return fields;
}
_fieldName = fieldName;
}
- @Override
- public short getThriftFieldId() {
+ public short getThriftFieldId() {
return _thriftId;
}
- @Override
- public String getFieldName() {
+ public String getFieldName() {
return _fieldName;
}
}
this.success = other.success;
}
- @Override
- public pushRoute_result deepCopy() {
+ public pushRoute_result deepCopy() {
return new pushRoute_result(this);
}
__isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __SUCCESS_ISSET_ID, value);
}
- @Override
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, Object value) {
switch (field) {
case SUCCESS:
if (value == null) {
}
}
- @Override
- public Object getFieldValue(_Fields field) {
+ public Object getFieldValue(_Fields field) {
switch (field) {
case SUCCESS:
- return Integer.valueOf(getSuccess());
+ return getSuccess();
}
throw new IllegalStateException();
}
/** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
- @Override
- public boolean isSet(_Fields field) {
+ public boolean isSet(_Fields field) {
if (field == null) {
throw new IllegalArgumentException();
}
@Override
public boolean equals(Object that) {
- if (that == null) {
- return false;
- }
- if (that instanceof pushRoute_result) {
- return this.equals((pushRoute_result)that);
- }
+ if (that == null)
+ return false;
+ if (that instanceof pushRoute_result)
+ return this.equals((pushRoute_result)that);
return false;
}
public boolean equals(pushRoute_result that) {
- if (that == null) {
- return false;
- }
+ if (that == null)
+ return false;
boolean this_present_success = true;
boolean that_present_success = true;
if (this_present_success || that_present_success) {
- if (!(this_present_success && that_present_success)) {
- return false;
- }
- if (this.success != that.success) {
- return false;
- }
+ if (!(this_present_success && that_present_success))
+ return false;
+ if (this.success != that.success)
+ return false;
}
return true;
list.add(present_success);
if (present_success)
list.add(success);
+
return list.hashCode();
}
return 0;
}
- @Override
- public _Fields fieldForId(int fieldId) {
+ public _Fields fieldForId(int fieldId) {
return _Fields.findByThriftId(fieldId);
}
- @Override
- public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
+ public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
}
- @Override
- public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
+ public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
schemes.get(oprot.getScheme()).getScheme().write(oprot, this);
}
}
private static class pushRoute_resultStandardSchemeFactory implements SchemeFactory {
- @Override
- public pushRoute_resultStandardScheme getScheme() {
+ public pushRoute_resultStandardScheme getScheme() {
return new pushRoute_resultStandardScheme();
}
}
private static class pushRoute_resultStandardScheme extends StandardScheme<pushRoute_result> {
- @Override
- public void read(org.apache.thrift.protocol.TProtocol iprot, pushRoute_result struct) throws org.apache.thrift.TException {
+ public void read(org.apache.thrift.protocol.TProtocol iprot, pushRoute_result struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
iprot.readStructBegin();
while (true)
struct.validate();
}
- @Override
- public void write(org.apache.thrift.protocol.TProtocol oprot, pushRoute_result struct) throws org.apache.thrift.TException {
+ public void write(org.apache.thrift.protocol.TProtocol oprot, pushRoute_result struct) throws org.apache.thrift.TException {
struct.validate();
oprot.writeStructBegin(STRUCT_DESC);
}
private static class pushRoute_resultTupleSchemeFactory implements SchemeFactory {
- @Override
- public pushRoute_resultTupleScheme getScheme() {
+ public pushRoute_resultTupleScheme getScheme() {
return new pushRoute_resultTupleScheme();
}
}
private static final org.apache.thrift.protocol.TField P_TYPE_FIELD_DESC = new org.apache.thrift.protocol.TField("p_type", org.apache.thrift.protocol.TType.I32, (short)1);
private static final org.apache.thrift.protocol.TField PREFIX_FIELD_DESC = new org.apache.thrift.protocol.TField("prefix", org.apache.thrift.protocol.TType.STRING, (short)2);
private static final org.apache.thrift.protocol.TField RD_FIELD_DESC = new org.apache.thrift.protocol.TField("rd", org.apache.thrift.protocol.TType.STRING, (short)3);
- private static final org.apache.thrift.protocol.TField ETHTAG_FIELD_DESC = new org.apache.thrift.protocol.TField("ethtag", org.apache.thrift.protocol.TType.I32, (short)4);
+ private static final org.apache.thrift.protocol.TField ETHTAG_FIELD_DESC = new org.apache.thrift.protocol.TField("ethtag", org.apache.thrift.protocol.TType.I64, (short)4);
private static final org.apache.thrift.protocol.TField ESI_FIELD_DESC = new org.apache.thrift.protocol.TField("esi", org.apache.thrift.protocol.TType.STRING, (short)5);
private static final org.apache.thrift.protocol.TField MACADDRESS_FIELD_DESC = new org.apache.thrift.protocol.TField("macaddress", org.apache.thrift.protocol.TType.STRING, (short)6);
private static final org.apache.thrift.protocol.TField AFI_FIELD_DESC = new org.apache.thrift.protocol.TField("afi", org.apache.thrift.protocol.TType.I32, (short)7);
public protocol_type p_type; // required
public String prefix; // required
public String rd; // required
- public int ethtag; // required
+ public long ethtag; // required
public String esi; // required
public String macaddress; // required
/**
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) {
- throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
- }
+ if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
return fields;
}
_fieldName = fieldName;
}
- @Override
- public short getThriftFieldId() {
+ public short getThriftFieldId() {
return _thriftId;
}
- @Override
- public String getFieldName() {
+ public String getFieldName() {
return _fieldName;
}
}
tmpMap.put(_Fields.RD, new org.apache.thrift.meta_data.FieldMetaData("rd", org.apache.thrift.TFieldRequirementType.DEFAULT,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
tmpMap.put(_Fields.ETHTAG, new org.apache.thrift.meta_data.FieldMetaData("ethtag", org.apache.thrift.TFieldRequirementType.DEFAULT,
- new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I32)));
+ new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
tmpMap.put(_Fields.ESI, new org.apache.thrift.meta_data.FieldMetaData("esi", org.apache.thrift.TFieldRequirementType.DEFAULT,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
tmpMap.put(_Fields.MACADDRESS, new org.apache.thrift.meta_data.FieldMetaData("macaddress", org.apache.thrift.TFieldRequirementType.DEFAULT,
protocol_type p_type,
String prefix,
String rd,
- int ethtag,
+ long ethtag,
String esi,
String macaddress,
af_afi afi)
}
}
- @Override
- public withdrawRoute_args deepCopy() {
+ public withdrawRoute_args deepCopy() {
return new withdrawRoute_args(this);
}
}
}
- public int getEthtag() {
+ public long getEthtag() {
return this.ethtag;
}
- public withdrawRoute_args setEthtag(int ethtag) {
+ public withdrawRoute_args setEthtag(long ethtag) {
this.ethtag = ethtag;
setEthtagIsSet(true);
return this;
}
}
- @Override
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, Object value) {
switch (field) {
case P_TYPE:
if (value == null) {
if (value == null) {
unsetEthtag();
} else {
- setEthtag((Integer)value);
+ setEthtag((Long)value);
}
break;
}
}
- @Override
- public Object getFieldValue(_Fields field) {
+ public Object getFieldValue(_Fields field) {
switch (field) {
case P_TYPE:
return getP_type();
return getRd();
case ETHTAG:
- return Integer.valueOf(getEthtag());
+ return getEthtag();
case ESI:
return getEsi();
}
/** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
- @Override
- public boolean isSet(_Fields field) {
+ public boolean isSet(_Fields field) {
if (field == null) {
throw new IllegalArgumentException();
}
@Override
public boolean equals(Object that) {
- if (that == null) {
- return false;
- }
- if (that instanceof withdrawRoute_args) {
- return this.equals((withdrawRoute_args)that);
- }
+ if (that == null)
+ return false;
+ if (that instanceof withdrawRoute_args)
+ return this.equals((withdrawRoute_args)that);
return false;
}
public boolean equals(withdrawRoute_args that) {
- if (that == null) {
- return false;
- }
+ if (that == null)
+ return false;
boolean this_present_p_type = true && this.isSetP_type();
boolean that_present_p_type = true && that.isSetP_type();
if (this_present_p_type || that_present_p_type) {
- if (!(this_present_p_type && that_present_p_type)) {
- return false;
- }
- if (!this.p_type.equals(that.p_type)) {
- return false;
- }
+ if (!(this_present_p_type && that_present_p_type))
+ return false;
+ if (!this.p_type.equals(that.p_type))
+ return false;
}
boolean this_present_prefix = true && this.isSetPrefix();
boolean that_present_prefix = true && that.isSetPrefix();
if (this_present_prefix || that_present_prefix) {
- if (!(this_present_prefix && that_present_prefix)) {
- return false;
- }
- if (!this.prefix.equals(that.prefix)) {
- return false;
- }
+ if (!(this_present_prefix && that_present_prefix))
+ return false;
+ if (!this.prefix.equals(that.prefix))
+ return false;
}
boolean this_present_rd = true && this.isSetRd();
boolean that_present_rd = true && that.isSetRd();
if (this_present_rd || that_present_rd) {
- if (!(this_present_rd && that_present_rd)) {
- return false;
- }
- if (!this.rd.equals(that.rd)) {
- return false;
- }
+ if (!(this_present_rd && that_present_rd))
+ return false;
+ if (!this.rd.equals(that.rd))
+ return false;
}
boolean this_present_ethtag = true;
boolean that_present_ethtag = true;
if (this_present_ethtag || that_present_ethtag) {
- if (!(this_present_ethtag && that_present_ethtag)) {
- return false;
- }
- if (this.ethtag != that.ethtag) {
- return false;
- }
+ if (!(this_present_ethtag && that_present_ethtag))
+ return false;
+ if (this.ethtag != that.ethtag)
+ return false;
}
boolean this_present_esi = true && this.isSetEsi();
boolean that_present_esi = true && that.isSetEsi();
if (this_present_esi || that_present_esi) {
- if (!(this_present_esi && that_present_esi)) {
- return false;
- }
- if (!this.esi.equals(that.esi)) {
- return false;
- }
+ if (!(this_present_esi && that_present_esi))
+ return false;
+ if (!this.esi.equals(that.esi))
+ return false;
}
boolean this_present_macaddress = true && this.isSetMacaddress();
boolean that_present_macaddress = true && that.isSetMacaddress();
if (this_present_macaddress || that_present_macaddress) {
- if (!(this_present_macaddress && that_present_macaddress)) {
- return false;
- }
- if (!this.macaddress.equals(that.macaddress)) {
- return false;
- }
+ if (!(this_present_macaddress && that_present_macaddress))
+ return false;
+ if (!this.macaddress.equals(that.macaddress))
+ return false;
}
boolean this_present_afi = true && this.isSetAfi();
boolean that_present_afi = true && that.isSetAfi();
if (this_present_afi || that_present_afi) {
- if (!(this_present_afi && that_present_afi)) {
- return false;
- }
- if (!this.afi.equals(that.afi)) {
- return false;
- }
+ if (!(this_present_afi && that_present_afi))
+ return false;
+ if (!this.afi.equals(that.afi))
+ return false;
}
return true;
@Override
public int hashCode() {
List<Object> list = new ArrayList<Object>();
+
boolean present_p_type = true && (isSetP_type());
list.add(present_p_type);
if (present_p_type)
list.add(p_type.getValue());
+
boolean present_prefix = true && (isSetPrefix());
list.add(present_prefix);
if (present_prefix)
list.add(prefix);
+
boolean present_rd = true && (isSetRd());
list.add(present_rd);
if (present_rd)
list.add(rd);
+
boolean present_ethtag = true;
list.add(present_ethtag);
if (present_ethtag)
list.add(ethtag);
+
boolean present_esi = true && (isSetEsi());
list.add(present_esi);
if (present_esi)
list.add(esi);
+
boolean present_macaddress = true && (isSetMacaddress());
list.add(present_macaddress);
if (present_macaddress)
list.add(macaddress);
+
boolean present_afi = true && (isSetAfi());
list.add(present_afi);
if (present_afi)
list.add(afi.getValue());
+
return list.hashCode();
}
return 0;
}
- @Override
- public _Fields fieldForId(int fieldId) {
+ public _Fields fieldForId(int fieldId) {
return _Fields.findByThriftId(fieldId);
}
- @Override
- public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
+ public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
}
- @Override
- public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
+ public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
schemes.get(oprot.getScheme()).getScheme().write(oprot, this);
}
sb.append(this.p_type);
}
first = false;
- if (!first) {
- sb.append(", ");
- }
+ if (!first) sb.append(", ");
sb.append("prefix:");
if (this.prefix == null) {
sb.append("null");
sb.append(this.prefix);
}
first = false;
- if (!first) {
- sb.append(", ");
- }
+ if (!first) sb.append(", ");
sb.append("rd:");
if (this.rd == null) {
sb.append("null");
sb.append(this.rd);
}
first = false;
- if (!first) {
- sb.append(", ");
- }
+ if (!first) sb.append(", ");
sb.append("ethtag:");
sb.append(this.ethtag);
first = false;
- if (!first) {
- sb.append(", ");
- }
+ if (!first) sb.append(", ");
sb.append("esi:");
if (this.esi == null) {
sb.append("null");
sb.append(this.esi);
}
first = false;
- if (!first) {
- sb.append(", ");
- }
+ if (!first) sb.append(", ");
sb.append("macaddress:");
if (this.macaddress == null) {
sb.append("null");
sb.append(this.macaddress);
}
first = false;
- if (!first) {
- sb.append(", ");
- }
+ if (!first) sb.append(", ");
sb.append("afi:");
if (this.afi == null) {
sb.append("null");
}
private static class withdrawRoute_argsStandardSchemeFactory implements SchemeFactory {
- @Override
- public withdrawRoute_argsStandardScheme getScheme() {
+ public withdrawRoute_argsStandardScheme getScheme() {
return new withdrawRoute_argsStandardScheme();
}
}
private static class withdrawRoute_argsStandardScheme extends StandardScheme<withdrawRoute_args> {
- @Override
- public void read(org.apache.thrift.protocol.TProtocol iprot, withdrawRoute_args struct) throws org.apache.thrift.TException {
+ public void read(org.apache.thrift.protocol.TProtocol iprot, withdrawRoute_args struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
iprot.readStructBegin();
while (true)
}
break;
case 4: // ETHTAG
- if (schemeField.type == org.apache.thrift.protocol.TType.I32) {
- struct.ethtag = iprot.readI32();
+ if (schemeField.type == org.apache.thrift.protocol.TType.I64) {
+ struct.ethtag = iprot.readI64();
struct.setEthtagIsSet(true);
} else {
org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
struct.validate();
}
- @Override
- public void write(org.apache.thrift.protocol.TProtocol oprot, withdrawRoute_args struct) throws org.apache.thrift.TException {
+ public void write(org.apache.thrift.protocol.TProtocol oprot, withdrawRoute_args struct) throws org.apache.thrift.TException {
struct.validate();
oprot.writeStructBegin(STRUCT_DESC);
oprot.writeFieldEnd();
}
oprot.writeFieldBegin(ETHTAG_FIELD_DESC);
- oprot.writeI32(struct.ethtag);
+ oprot.writeI64(struct.ethtag);
oprot.writeFieldEnd();
if (struct.esi != null) {
oprot.writeFieldBegin(ESI_FIELD_DESC);
}
private static class withdrawRoute_argsTupleSchemeFactory implements SchemeFactory {
- @Override
- public withdrawRoute_argsTupleScheme getScheme() {
+ public withdrawRoute_argsTupleScheme getScheme() {
return new withdrawRoute_argsTupleScheme();
}
}
oprot.writeString(struct.rd);
}
if (struct.isSetEthtag()) {
- oprot.writeI32(struct.ethtag);
+ oprot.writeI64(struct.ethtag);
}
if (struct.isSetEsi()) {
oprot.writeString(struct.esi);
struct.setRdIsSet(true);
}
if (incoming.get(3)) {
- struct.ethtag = iprot.readI32();
+ struct.ethtag = iprot.readI64();
struct.setEthtagIsSet(true);
}
if (incoming.get(4)) {
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) {
- throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
- }
+ if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
return fields;
}
_fieldName = fieldName;
}
- @Override
- public short getThriftFieldId() {
+ public short getThriftFieldId() {
return _thriftId;
}
- @Override
- public String getFieldName() {
+ public String getFieldName() {
return _fieldName;
}
}
this.success = other.success;
}
- @Override
- public withdrawRoute_result deepCopy() {
+ public withdrawRoute_result deepCopy() {
return new withdrawRoute_result(this);
}
__isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __SUCCESS_ISSET_ID, value);
}
- @Override
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, Object value) {
switch (field) {
case SUCCESS:
if (value == null) {
}
}
- @Override
- public Object getFieldValue(_Fields field) {
+ public Object getFieldValue(_Fields field) {
switch (field) {
case SUCCESS:
- return Integer.valueOf(getSuccess());
+ return getSuccess();
}
throw new IllegalStateException();
}
/** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
- @Override
- public boolean isSet(_Fields field) {
+ public boolean isSet(_Fields field) {
if (field == null) {
throw new IllegalArgumentException();
}
@Override
public boolean equals(Object that) {
- if (that == null) {
- return false;
- }
- if (that instanceof withdrawRoute_result) {
- return this.equals((withdrawRoute_result)that);
- }
+ if (that == null)
+ return false;
+ if (that instanceof withdrawRoute_result)
+ return this.equals((withdrawRoute_result)that);
return false;
}
public boolean equals(withdrawRoute_result that) {
- if (that == null) {
- return false;
- }
+ if (that == null)
+ return false;
boolean this_present_success = true;
boolean that_present_success = true;
if (this_present_success || that_present_success) {
- if (!(this_present_success && that_present_success)) {
- return false;
- }
- if (this.success != that.success) {
- return false;
- }
+ if (!(this_present_success && that_present_success))
+ return false;
+ if (this.success != that.success)
+ return false;
}
return true;
list.add(present_success);
if (present_success)
list.add(success);
+
return list.hashCode();
}
return 0;
}
- @Override
- public _Fields fieldForId(int fieldId) {
+ public _Fields fieldForId(int fieldId) {
return _Fields.findByThriftId(fieldId);
}
- @Override
- public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
+ public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
}
- @Override
- public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
+ public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
schemes.get(oprot.getScheme()).getScheme().write(oprot, this);
}
}
private static class withdrawRoute_resultStandardSchemeFactory implements SchemeFactory {
- @Override
- public withdrawRoute_resultStandardScheme getScheme() {
+ public withdrawRoute_resultStandardScheme getScheme() {
return new withdrawRoute_resultStandardScheme();
}
}
private static class withdrawRoute_resultStandardScheme extends StandardScheme<withdrawRoute_result> {
- @Override
- public void read(org.apache.thrift.protocol.TProtocol iprot, withdrawRoute_result struct) throws org.apache.thrift.TException {
+ public void read(org.apache.thrift.protocol.TProtocol iprot, withdrawRoute_result struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
iprot.readStructBegin();
while (true)
struct.validate();
}
- @Override
- public void write(org.apache.thrift.protocol.TProtocol oprot, withdrawRoute_result struct) throws org.apache.thrift.TException {
+ public void write(org.apache.thrift.protocol.TProtocol oprot, withdrawRoute_result struct) throws org.apache.thrift.TException {
struct.validate();
oprot.writeStructBegin(STRUCT_DESC);
}
private static class withdrawRoute_resultTupleSchemeFactory implements SchemeFactory {
- @Override
- public withdrawRoute_resultTupleScheme getScheme() {
+ public withdrawRoute_resultTupleScheme getScheme() {
return new withdrawRoute_resultTupleScheme();
}
}
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) {
- throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
- }
+ if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
return fields;
}
_fieldName = fieldName;
}
- @Override
- public short getThriftFieldId() {
+ public short getThriftFieldId() {
return _thriftId;
}
- @Override
- public String getFieldName() {
+ public String getFieldName() {
return _fieldName;
}
}
this.nHops = other.nHops;
}
- @Override
- public setEbgpMultihop_args deepCopy() {
+ public setEbgpMultihop_args deepCopy() {
return new setEbgpMultihop_args(this);
}
__isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __NHOPS_ISSET_ID, value);
}
- @Override
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, Object value) {
switch (field) {
case PEER_IP:
if (value == null) {
}
}
- @Override
- public Object getFieldValue(_Fields field) {
+ public Object getFieldValue(_Fields field) {
switch (field) {
case PEER_IP:
return getPeerIp();
case N_HOPS:
- return Integer.valueOf(getNHops());
+ return getNHops();
}
throw new IllegalStateException();
}
/** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
- @Override
- public boolean isSet(_Fields field) {
+ public boolean isSet(_Fields field) {
if (field == null) {
throw new IllegalArgumentException();
}
@Override
public boolean equals(Object that) {
- if (that == null) {
- return false;
- }
- if (that instanceof setEbgpMultihop_args) {
- return this.equals((setEbgpMultihop_args)that);
- }
+ if (that == null)
+ return false;
+ if (that instanceof setEbgpMultihop_args)
+ return this.equals((setEbgpMultihop_args)that);
return false;
}
public boolean equals(setEbgpMultihop_args that) {
- if (that == null) {
- return false;
- }
+ if (that == null)
+ return false;
boolean this_present_peerIp = true && this.isSetPeerIp();
boolean that_present_peerIp = true && that.isSetPeerIp();
if (this_present_peerIp || that_present_peerIp) {
- if (!(this_present_peerIp && that_present_peerIp)) {
- return false;
- }
- if (!this.peerIp.equals(that.peerIp)) {
- return false;
- }
+ if (!(this_present_peerIp && that_present_peerIp))
+ return false;
+ if (!this.peerIp.equals(that.peerIp))
+ return false;
}
boolean this_present_nHops = true;
boolean that_present_nHops = true;
if (this_present_nHops || that_present_nHops) {
- if (!(this_present_nHops && that_present_nHops)) {
- return false;
- }
- if (this.nHops != that.nHops) {
- return false;
- }
+ if (!(this_present_nHops && that_present_nHops))
+ return false;
+ if (this.nHops != that.nHops)
+ return false;
}
return true;
list.add(present_peerIp);
if (present_peerIp)
list.add(peerIp);
+
boolean present_nHops = true;
list.add(present_nHops);
if (present_nHops)
list.add(nHops);
+
return list.hashCode();
}
return 0;
}
- @Override
- public _Fields fieldForId(int fieldId) {
+ public _Fields fieldForId(int fieldId) {
return _Fields.findByThriftId(fieldId);
}
- @Override
- public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
+ public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
}
- @Override
- public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
+ public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
schemes.get(oprot.getScheme()).getScheme().write(oprot, this);
}
sb.append(this.peerIp);
}
first = false;
- if (!first) {
- sb.append(", ");
- }
+ if (!first) sb.append(", ");
sb.append("nHops:");
sb.append(this.nHops);
first = false;
}
private static class setEbgpMultihop_argsStandardSchemeFactory implements SchemeFactory {
- @Override
- public setEbgpMultihop_argsStandardScheme getScheme() {
+ public setEbgpMultihop_argsStandardScheme getScheme() {
return new setEbgpMultihop_argsStandardScheme();
}
}
private static class setEbgpMultihop_argsStandardScheme extends StandardScheme<setEbgpMultihop_args> {
- @Override
- public void read(org.apache.thrift.protocol.TProtocol iprot, setEbgpMultihop_args struct) throws org.apache.thrift.TException {
+ public void read(org.apache.thrift.protocol.TProtocol iprot, setEbgpMultihop_args struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
iprot.readStructBegin();
while (true)
struct.validate();
}
- @Override
- public void write(org.apache.thrift.protocol.TProtocol oprot, setEbgpMultihop_args struct) throws org.apache.thrift.TException {
+ public void write(org.apache.thrift.protocol.TProtocol oprot, setEbgpMultihop_args struct) throws org.apache.thrift.TException {
struct.validate();
oprot.writeStructBegin(STRUCT_DESC);
}
private static class setEbgpMultihop_argsTupleSchemeFactory implements SchemeFactory {
- @Override
- public setEbgpMultihop_argsTupleScheme getScheme() {
+ public setEbgpMultihop_argsTupleScheme getScheme() {
return new setEbgpMultihop_argsTupleScheme();
}
}
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) {
- throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
- }
+ if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
return fields;
}
_fieldName = fieldName;
}
- @Override
- public short getThriftFieldId() {
+ public short getThriftFieldId() {
return _thriftId;
}
- @Override
- public String getFieldName() {
+ public String getFieldName() {
return _fieldName;
}
}
this.success = other.success;
}
- @Override
- public setEbgpMultihop_result deepCopy() {
+ public setEbgpMultihop_result deepCopy() {
return new setEbgpMultihop_result(this);
}
__isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __SUCCESS_ISSET_ID, value);
}
- @Override
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, Object value) {
switch (field) {
case SUCCESS:
if (value == null) {
}
}
- @Override
- public Object getFieldValue(_Fields field) {
+ public Object getFieldValue(_Fields field) {
switch (field) {
case SUCCESS:
- return Integer.valueOf(getSuccess());
+ return getSuccess();
}
throw new IllegalStateException();
}
/** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
- @Override
- public boolean isSet(_Fields field) {
+ public boolean isSet(_Fields field) {
if (field == null) {
throw new IllegalArgumentException();
}
@Override
public boolean equals(Object that) {
- if (that == null) {
- return false;
- }
- if (that instanceof setEbgpMultihop_result) {
- return this.equals((setEbgpMultihop_result)that);
- }
+ if (that == null)
+ return false;
+ if (that instanceof setEbgpMultihop_result)
+ return this.equals((setEbgpMultihop_result)that);
return false;
}
public boolean equals(setEbgpMultihop_result that) {
- if (that == null) {
- return false;
- }
+ if (that == null)
+ return false;
boolean this_present_success = true;
boolean that_present_success = true;
if (this_present_success || that_present_success) {
- if (!(this_present_success && that_present_success)) {
- return false;
- }
- if (this.success != that.success) {
- return false;
- }
+ if (!(this_present_success && that_present_success))
+ return false;
+ if (this.success != that.success)
+ return false;
}
return true;
list.add(present_success);
if (present_success)
list.add(success);
+
return list.hashCode();
}
return 0;
}
- @Override
- public _Fields fieldForId(int fieldId) {
+ public _Fields fieldForId(int fieldId) {
return _Fields.findByThriftId(fieldId);
}
- @Override
- public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
+ public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
}
- @Override
- public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
+ public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
schemes.get(oprot.getScheme()).getScheme().write(oprot, this);
}
}
private static class setEbgpMultihop_resultStandardSchemeFactory implements SchemeFactory {
- @Override
- public setEbgpMultihop_resultStandardScheme getScheme() {
+ public setEbgpMultihop_resultStandardScheme getScheme() {
return new setEbgpMultihop_resultStandardScheme();
}
}
private static class setEbgpMultihop_resultStandardScheme extends StandardScheme<setEbgpMultihop_result> {
- @Override
- public void read(org.apache.thrift.protocol.TProtocol iprot, setEbgpMultihop_result struct) throws org.apache.thrift.TException {
+ public void read(org.apache.thrift.protocol.TProtocol iprot, setEbgpMultihop_result struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
iprot.readStructBegin();
while (true)
struct.validate();
}
- @Override
- public void write(org.apache.thrift.protocol.TProtocol oprot, setEbgpMultihop_result struct) throws org.apache.thrift.TException {
+ public void write(org.apache.thrift.protocol.TProtocol oprot, setEbgpMultihop_result struct) throws org.apache.thrift.TException {
struct.validate();
oprot.writeStructBegin(STRUCT_DESC);
}
private static class setEbgpMultihop_resultTupleSchemeFactory implements SchemeFactory {
- @Override
- public setEbgpMultihop_resultTupleScheme getScheme() {
+ public setEbgpMultihop_resultTupleScheme getScheme() {
return new setEbgpMultihop_resultTupleScheme();
}
}
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) {
- throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
- }
+ if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
return fields;
}
_fieldName = fieldName;
}
- @Override
- public short getThriftFieldId() {
+ public short getThriftFieldId() {
return _thriftId;
}
- @Override
- public String getFieldName() {
+ public String getFieldName() {
return _fieldName;
}
}
}
}
- @Override
- public unsetEbgpMultihop_args deepCopy() {
+ public unsetEbgpMultihop_args deepCopy() {
return new unsetEbgpMultihop_args(this);
}
}
}
- @Override
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, Object value) {
switch (field) {
case PEER_IP:
if (value == null) {
}
}
- @Override
- public Object getFieldValue(_Fields field) {
+ public Object getFieldValue(_Fields field) {
switch (field) {
case PEER_IP:
return getPeerIp();
}
/** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
- @Override
- public boolean isSet(_Fields field) {
+ public boolean isSet(_Fields field) {
if (field == null) {
throw new IllegalArgumentException();
}
@Override
public boolean equals(Object that) {
- if (that == null) {
- return false;
- }
- if (that instanceof unsetEbgpMultihop_args) {
- return this.equals((unsetEbgpMultihop_args)that);
- }
+ if (that == null)
+ return false;
+ if (that instanceof unsetEbgpMultihop_args)
+ return this.equals((unsetEbgpMultihop_args)that);
return false;
}
public boolean equals(unsetEbgpMultihop_args that) {
- if (that == null) {
- return false;
- }
+ if (that == null)
+ return false;
boolean this_present_peerIp = true && this.isSetPeerIp();
boolean that_present_peerIp = true && that.isSetPeerIp();
if (this_present_peerIp || that_present_peerIp) {
- if (!(this_present_peerIp && that_present_peerIp)) {
- return false;
- }
- if (!this.peerIp.equals(that.peerIp)) {
- return false;
- }
+ if (!(this_present_peerIp && that_present_peerIp))
+ return false;
+ if (!this.peerIp.equals(that.peerIp))
+ return false;
}
return true;
list.add(present_peerIp);
if (present_peerIp)
list.add(peerIp);
+
return list.hashCode();
}
return 0;
}
- @Override
- public _Fields fieldForId(int fieldId) {
+ public _Fields fieldForId(int fieldId) {
return _Fields.findByThriftId(fieldId);
}
- @Override
- public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
+ public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
}
- @Override
- public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
+ public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
schemes.get(oprot.getScheme()).getScheme().write(oprot, this);
}
}
private static class unsetEbgpMultihop_argsStandardSchemeFactory implements SchemeFactory {
- @Override
- public unsetEbgpMultihop_argsStandardScheme getScheme() {
+ public unsetEbgpMultihop_argsStandardScheme getScheme() {
return new unsetEbgpMultihop_argsStandardScheme();
}
}
private static class unsetEbgpMultihop_argsStandardScheme extends StandardScheme<unsetEbgpMultihop_args> {
- @Override
- public void read(org.apache.thrift.protocol.TProtocol iprot, unsetEbgpMultihop_args struct) throws org.apache.thrift.TException {
+ public void read(org.apache.thrift.protocol.TProtocol iprot, unsetEbgpMultihop_args struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
iprot.readStructBegin();
while (true)
struct.validate();
}
- @Override
- public void write(org.apache.thrift.protocol.TProtocol oprot, unsetEbgpMultihop_args struct) throws org.apache.thrift.TException {
+ public void write(org.apache.thrift.protocol.TProtocol oprot, unsetEbgpMultihop_args struct) throws org.apache.thrift.TException {
struct.validate();
oprot.writeStructBegin(STRUCT_DESC);
}
private static class unsetEbgpMultihop_argsTupleSchemeFactory implements SchemeFactory {
- @Override
- public unsetEbgpMultihop_argsTupleScheme getScheme() {
+ public unsetEbgpMultihop_argsTupleScheme getScheme() {
return new unsetEbgpMultihop_argsTupleScheme();
}
}
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) {
- throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
- }
+ if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
return fields;
}
_fieldName = fieldName;
}
- @Override
- public short getThriftFieldId() {
+ public short getThriftFieldId() {
return _thriftId;
}
- @Override
- public String getFieldName() {
+ public String getFieldName() {
return _fieldName;
}
}
this.success = other.success;
}
- @Override
- public unsetEbgpMultihop_result deepCopy() {
+ public unsetEbgpMultihop_result deepCopy() {
return new unsetEbgpMultihop_result(this);
}
__isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __SUCCESS_ISSET_ID, value);
}
- @Override
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, Object value) {
switch (field) {
case SUCCESS:
if (value == null) {
}
}
- @Override
- public Object getFieldValue(_Fields field) {
+ public Object getFieldValue(_Fields field) {
switch (field) {
case SUCCESS:
- return Integer.valueOf(getSuccess());
+ return getSuccess();
}
throw new IllegalStateException();
}
/** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
- @Override
- public boolean isSet(_Fields field) {
+ public boolean isSet(_Fields field) {
if (field == null) {
throw new IllegalArgumentException();
}
@Override
public boolean equals(Object that) {
- if (that == null) {
- return false;
- }
- if (that instanceof unsetEbgpMultihop_result) {
- return this.equals((unsetEbgpMultihop_result)that);
- }
+ if (that == null)
+ return false;
+ if (that instanceof unsetEbgpMultihop_result)
+ return this.equals((unsetEbgpMultihop_result)that);
return false;
}
public boolean equals(unsetEbgpMultihop_result that) {
- if (that == null) {
- return false;
- }
+ if (that == null)
+ return false;
boolean this_present_success = true;
boolean that_present_success = true;
if (this_present_success || that_present_success) {
- if (!(this_present_success && that_present_success)) {
- return false;
- }
- if (this.success != that.success) {
- return false;
- }
- }
+ if (!(this_present_success && that_present_success))
+ return false;
+ if (this.success != that.success)
+ return false;
+ }
return true;
}
list.add(present_success);
if (present_success)
list.add(success);
+
return list.hashCode();
}
return 0;
}
- @Override
- public _Fields fieldForId(int fieldId) {
+ public _Fields fieldForId(int fieldId) {
return _Fields.findByThriftId(fieldId);
}
- @Override
- public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
+ public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
}
- @Override
- public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
+ public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
schemes.get(oprot.getScheme()).getScheme().write(oprot, this);
}
}
private static class unsetEbgpMultihop_resultStandardSchemeFactory implements SchemeFactory {
- @Override
- public unsetEbgpMultihop_resultStandardScheme getScheme() {
+ public unsetEbgpMultihop_resultStandardScheme getScheme() {
return new unsetEbgpMultihop_resultStandardScheme();
}
}
private static class unsetEbgpMultihop_resultStandardScheme extends StandardScheme<unsetEbgpMultihop_result> {
- @Override
- public void read(org.apache.thrift.protocol.TProtocol iprot, unsetEbgpMultihop_result struct) throws org.apache.thrift.TException {
+ public void read(org.apache.thrift.protocol.TProtocol iprot, unsetEbgpMultihop_result struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
iprot.readStructBegin();
while (true)
struct.validate();
}
- @Override
- public void write(org.apache.thrift.protocol.TProtocol oprot, unsetEbgpMultihop_result struct) throws org.apache.thrift.TException {
+ public void write(org.apache.thrift.protocol.TProtocol oprot, unsetEbgpMultihop_result struct) throws org.apache.thrift.TException {
struct.validate();
oprot.writeStructBegin(STRUCT_DESC);
}
private static class unsetEbgpMultihop_resultTupleSchemeFactory implements SchemeFactory {
- @Override
- public unsetEbgpMultihop_resultTupleScheme getScheme() {
+ public unsetEbgpMultihop_resultTupleScheme getScheme() {
return new unsetEbgpMultihop_resultTupleScheme();
}
}
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) {
- throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
- }
+ if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
return fields;
}
_fieldName = fieldName;
}
- @Override
- public short getThriftFieldId() {
+ public short getThriftFieldId() {
return _thriftId;
}
- @Override
- public String getFieldName() {
+ public String getFieldName() {
return _fieldName;
}
}
}
}
- @Override
- public setUpdateSource_args deepCopy() {
+ public setUpdateSource_args deepCopy() {
return new setUpdateSource_args(this);
}
}
}
- @Override
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, Object value) {
switch (field) {
case PEER_IP:
if (value == null) {
}
}
- @Override
- public Object getFieldValue(_Fields field) {
+ public Object getFieldValue(_Fields field) {
switch (field) {
case PEER_IP:
return getPeerIp();
}
/** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
- @Override
- public boolean isSet(_Fields field) {
+ public boolean isSet(_Fields field) {
if (field == null) {
throw new IllegalArgumentException();
}
@Override
public boolean equals(Object that) {
- if (that == null) {
- return false;
- }
- if (that instanceof setUpdateSource_args) {
- return this.equals((setUpdateSource_args)that);
- }
+ if (that == null)
+ return false;
+ if (that instanceof setUpdateSource_args)
+ return this.equals((setUpdateSource_args)that);
return false;
}
public boolean equals(setUpdateSource_args that) {
- if (that == null) {
- return false;
- }
+ if (that == null)
+ return false;
boolean this_present_peerIp = true && this.isSetPeerIp();
boolean that_present_peerIp = true && that.isSetPeerIp();
if (this_present_peerIp || that_present_peerIp) {
- if (!(this_present_peerIp && that_present_peerIp)) {
- return false;
- }
- if (!this.peerIp.equals(that.peerIp)) {
- return false;
- }
+ if (!(this_present_peerIp && that_present_peerIp))
+ return false;
+ if (!this.peerIp.equals(that.peerIp))
+ return false;
}
boolean this_present_srcIp = true && this.isSetSrcIp();
boolean that_present_srcIp = true && that.isSetSrcIp();
if (this_present_srcIp || that_present_srcIp) {
- if (!(this_present_srcIp && that_present_srcIp)) {
- return false;
- }
- if (!this.srcIp.equals(that.srcIp)) {
- return false;
- }
+ if (!(this_present_srcIp && that_present_srcIp))
+ return false;
+ if (!this.srcIp.equals(that.srcIp))
+ return false;
}
return true;
list.add(present_peerIp);
if (present_peerIp)
list.add(peerIp);
+
boolean present_srcIp = true && (isSetSrcIp());
list.add(present_srcIp);
if (present_srcIp)
list.add(srcIp);
+
return list.hashCode();
}
return 0;
}
- @Override
- public _Fields fieldForId(int fieldId) {
+ public _Fields fieldForId(int fieldId) {
return _Fields.findByThriftId(fieldId);
}
- @Override
- public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
+ public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
}
- @Override
- public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
+ public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
schemes.get(oprot.getScheme()).getScheme().write(oprot, this);
}
sb.append(this.peerIp);
}
first = false;
- if (!first) {
- sb.append(", ");
- }
+ if (!first) sb.append(", ");
sb.append("srcIp:");
if (this.srcIp == null) {
sb.append("null");
}
private static class setUpdateSource_argsStandardSchemeFactory implements SchemeFactory {
- @Override
- public setUpdateSource_argsStandardScheme getScheme() {
+ public setUpdateSource_argsStandardScheme getScheme() {
return new setUpdateSource_argsStandardScheme();
}
}
private static class setUpdateSource_argsStandardScheme extends StandardScheme<setUpdateSource_args> {
- @Override
- public void read(org.apache.thrift.protocol.TProtocol iprot, setUpdateSource_args struct) throws org.apache.thrift.TException {
+ public void read(org.apache.thrift.protocol.TProtocol iprot, setUpdateSource_args struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
iprot.readStructBegin();
while (true)
struct.validate();
}
- @Override
- public void write(org.apache.thrift.protocol.TProtocol oprot, setUpdateSource_args struct) throws org.apache.thrift.TException {
+ public void write(org.apache.thrift.protocol.TProtocol oprot, setUpdateSource_args struct) throws org.apache.thrift.TException {
struct.validate();
oprot.writeStructBegin(STRUCT_DESC);
}
private static class setUpdateSource_argsTupleSchemeFactory implements SchemeFactory {
- @Override
- public setUpdateSource_argsTupleScheme getScheme() {
+ public setUpdateSource_argsTupleScheme getScheme() {
return new setUpdateSource_argsTupleScheme();
}
}
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) {
- throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
- }
+ if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
return fields;
}
_fieldName = fieldName;
}
- @Override
- public short getThriftFieldId() {
+ public short getThriftFieldId() {
return _thriftId;
}
- @Override
- public String getFieldName() {
+ public String getFieldName() {
return _fieldName;
}
}
this.success = other.success;
}
- @Override
- public setUpdateSource_result deepCopy() {
+ public setUpdateSource_result deepCopy() {
return new setUpdateSource_result(this);
}
__isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __SUCCESS_ISSET_ID, value);
}
- @Override
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, Object value) {
switch (field) {
case SUCCESS:
if (value == null) {
}
}
- @Override
- public Object getFieldValue(_Fields field) {
+ public Object getFieldValue(_Fields field) {
switch (field) {
case SUCCESS:
- return Integer.valueOf(getSuccess());
+ return getSuccess();
}
throw new IllegalStateException();
}
/** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
- @Override
- public boolean isSet(_Fields field) {
+ public boolean isSet(_Fields field) {
if (field == null) {
throw new IllegalArgumentException();
}
@Override
public boolean equals(Object that) {
- if (that == null) {
- return false;
- }
- if (that instanceof setUpdateSource_result) {
- return this.equals((setUpdateSource_result)that);
- }
+ if (that == null)
+ return false;
+ if (that instanceof setUpdateSource_result)
+ return this.equals((setUpdateSource_result)that);
return false;
}
public boolean equals(setUpdateSource_result that) {
- if (that == null) {
- return false;
- }
+ if (that == null)
+ return false;
boolean this_present_success = true;
boolean that_present_success = true;
if (this_present_success || that_present_success) {
- if (!(this_present_success && that_present_success)) {
- return false;
- }
- if (this.success != that.success) {
- return false;
- }
+ if (!(this_present_success && that_present_success))
+ return false;
+ if (this.success != that.success)
+ return false;
}
return true;
list.add(present_success);
if (present_success)
list.add(success);
+
return list.hashCode();
}
return 0;
}
- @Override
- public _Fields fieldForId(int fieldId) {
+ public _Fields fieldForId(int fieldId) {
return _Fields.findByThriftId(fieldId);
}
- @Override
- public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
+ public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
}
- @Override
- public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
+ public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
schemes.get(oprot.getScheme()).getScheme().write(oprot, this);
}
}
private static class setUpdateSource_resultStandardSchemeFactory implements SchemeFactory {
- @Override
- public setUpdateSource_resultStandardScheme getScheme() {
+ public setUpdateSource_resultStandardScheme getScheme() {
return new setUpdateSource_resultStandardScheme();
}
}
private static class setUpdateSource_resultStandardScheme extends StandardScheme<setUpdateSource_result> {
- @Override
- public void read(org.apache.thrift.protocol.TProtocol iprot, setUpdateSource_result struct) throws org.apache.thrift.TException {
+ public void read(org.apache.thrift.protocol.TProtocol iprot, setUpdateSource_result struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
iprot.readStructBegin();
while (true)
struct.validate();
}
- @Override
- public void write(org.apache.thrift.protocol.TProtocol oprot, setUpdateSource_result struct) throws org.apache.thrift.TException {
+ public void write(org.apache.thrift.protocol.TProtocol oprot, setUpdateSource_result struct) throws org.apache.thrift.TException {
struct.validate();
oprot.writeStructBegin(STRUCT_DESC);
}
private static class setUpdateSource_resultTupleSchemeFactory implements SchemeFactory {
- @Override
- public setUpdateSource_resultTupleScheme getScheme() {
+ public setUpdateSource_resultTupleScheme getScheme() {
return new setUpdateSource_resultTupleScheme();
}
}
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) {
- throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
- }
+ if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
return fields;
}
_fieldName = fieldName;
}
- @Override
- public short getThriftFieldId() {
+ public short getThriftFieldId() {
return _thriftId;
}
- @Override
- public String getFieldName() {
+ public String getFieldName() {
return _fieldName;
}
}
}
}
- @Override
- public unsetUpdateSource_args deepCopy() {
+ public unsetUpdateSource_args deepCopy() {
return new unsetUpdateSource_args(this);
}
}
}
- @Override
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, Object value) {
switch (field) {
case PEER_IP:
if (value == null) {
}
}
- @Override
- public Object getFieldValue(_Fields field) {
+ public Object getFieldValue(_Fields field) {
switch (field) {
case PEER_IP:
return getPeerIp();
}
/** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
- @Override
- public boolean isSet(_Fields field) {
+ public boolean isSet(_Fields field) {
if (field == null) {
throw new IllegalArgumentException();
}
@Override
public boolean equals(Object that) {
- if (that == null) {
- return false;
- }
- if (that instanceof unsetUpdateSource_args) {
- return this.equals((unsetUpdateSource_args)that);
- }
+ if (that == null)
+ return false;
+ if (that instanceof unsetUpdateSource_args)
+ return this.equals((unsetUpdateSource_args)that);
return false;
}
public boolean equals(unsetUpdateSource_args that) {
- if (that == null) {
- return false;
- }
+ if (that == null)
+ return false;
boolean this_present_peerIp = true && this.isSetPeerIp();
boolean that_present_peerIp = true && that.isSetPeerIp();
if (this_present_peerIp || that_present_peerIp) {
- if (!(this_present_peerIp && that_present_peerIp)) {
- return false;
- }
- if (!this.peerIp.equals(that.peerIp)) {
- return false;
- }
+ if (!(this_present_peerIp && that_present_peerIp))
+ return false;
+ if (!this.peerIp.equals(that.peerIp))
+ return false;
}
return true;
list.add(present_peerIp);
if (present_peerIp)
list.add(peerIp);
+
return list.hashCode();
}
return 0;
}
- @Override
- public _Fields fieldForId(int fieldId) {
+ public _Fields fieldForId(int fieldId) {
return _Fields.findByThriftId(fieldId);
}
- @Override
- public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
+ public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
}
- @Override
- public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
+ public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
schemes.get(oprot.getScheme()).getScheme().write(oprot, this);
}
}
private static class unsetUpdateSource_argsStandardSchemeFactory implements SchemeFactory {
- @Override
- public unsetUpdateSource_argsStandardScheme getScheme() {
+ public unsetUpdateSource_argsStandardScheme getScheme() {
return new unsetUpdateSource_argsStandardScheme();
}
}
private static class unsetUpdateSource_argsStandardScheme extends StandardScheme<unsetUpdateSource_args> {
- @Override
- public void read(org.apache.thrift.protocol.TProtocol iprot, unsetUpdateSource_args struct) throws org.apache.thrift.TException {
+ public void read(org.apache.thrift.protocol.TProtocol iprot, unsetUpdateSource_args struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
iprot.readStructBegin();
while (true)
struct.validate();
}
- @Override
- public void write(org.apache.thrift.protocol.TProtocol oprot, unsetUpdateSource_args struct) throws org.apache.thrift.TException {
+ public void write(org.apache.thrift.protocol.TProtocol oprot, unsetUpdateSource_args struct) throws org.apache.thrift.TException {
struct.validate();
oprot.writeStructBegin(STRUCT_DESC);
}
private static class unsetUpdateSource_argsTupleSchemeFactory implements SchemeFactory {
- @Override
- public unsetUpdateSource_argsTupleScheme getScheme() {
+ public unsetUpdateSource_argsTupleScheme getScheme() {
return new unsetUpdateSource_argsTupleScheme();
}
}
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) {
- throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
- }
+ if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
return fields;
}
_fieldName = fieldName;
}
- @Override
- public short getThriftFieldId() {
+ public short getThriftFieldId() {
return _thriftId;
}
- @Override
- public String getFieldName() {
+ public String getFieldName() {
return _fieldName;
}
}
this.success = other.success;
}
- @Override
- public unsetUpdateSource_result deepCopy() {
+ public unsetUpdateSource_result deepCopy() {
return new unsetUpdateSource_result(this);
}
__isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __SUCCESS_ISSET_ID, value);
}
- @Override
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, Object value) {
switch (field) {
case SUCCESS:
if (value == null) {
}
}
- @Override
- public Object getFieldValue(_Fields field) {
+ public Object getFieldValue(_Fields field) {
switch (field) {
case SUCCESS:
- return Integer.valueOf(getSuccess());
+ return getSuccess();
}
throw new IllegalStateException();
}
/** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
- @Override
- public boolean isSet(_Fields field) {
+ public boolean isSet(_Fields field) {
if (field == null) {
throw new IllegalArgumentException();
}
@Override
public boolean equals(Object that) {
- if (that == null) {
- return false;
- }
- if (that instanceof unsetUpdateSource_result) {
- return this.equals((unsetUpdateSource_result)that);
- }
+ if (that == null)
+ return false;
+ if (that instanceof unsetUpdateSource_result)
+ return this.equals((unsetUpdateSource_result)that);
return false;
}
public boolean equals(unsetUpdateSource_result that) {
- if (that == null) {
- return false;
- }
+ if (that == null)
+ return false;
boolean this_present_success = true;
boolean that_present_success = true;
if (this_present_success || that_present_success) {
- if (!(this_present_success && that_present_success)) {
- return false;
- }
- if (this.success != that.success) {
- return false;
- }
+ if (!(this_present_success && that_present_success))
+ return false;
+ if (this.success != that.success)
+ return false;
}
return true;
list.add(present_success);
if (present_success)
list.add(success);
+
return list.hashCode();
}
return 0;
}
- @Override
- public _Fields fieldForId(int fieldId) {
+ public _Fields fieldForId(int fieldId) {
return _Fields.findByThriftId(fieldId);
}
- @Override
- public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
+ public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
}
- @Override
- public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
+ public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
schemes.get(oprot.getScheme()).getScheme().write(oprot, this);
}
}
private static class unsetUpdateSource_resultStandardSchemeFactory implements SchemeFactory {
- @Override
- public unsetUpdateSource_resultStandardScheme getScheme() {
+ public unsetUpdateSource_resultStandardScheme getScheme() {
return new unsetUpdateSource_resultStandardScheme();
}
}
private static class unsetUpdateSource_resultStandardScheme extends StandardScheme<unsetUpdateSource_result> {
- @Override
- public void read(org.apache.thrift.protocol.TProtocol iprot, unsetUpdateSource_result struct) throws org.apache.thrift.TException {
+ public void read(org.apache.thrift.protocol.TProtocol iprot, unsetUpdateSource_result struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
iprot.readStructBegin();
while (true)
struct.validate();
}
- @Override
- public void write(org.apache.thrift.protocol.TProtocol oprot, unsetUpdateSource_result struct) throws org.apache.thrift.TException {
+ public void write(org.apache.thrift.protocol.TProtocol oprot, unsetUpdateSource_result struct) throws org.apache.thrift.TException {
struct.validate();
oprot.writeStructBegin(STRUCT_DESC);
}
private static class unsetUpdateSource_resultTupleSchemeFactory implements SchemeFactory {
- @Override
- public unsetUpdateSource_resultTupleScheme getScheme() {
+ public unsetUpdateSource_resultTupleScheme getScheme() {
return new unsetUpdateSource_resultTupleScheme();
}
}
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) {
- throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
- }
+ if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
return fields;
}
_fieldName = fieldName;
}
- @Override
- public short getThriftFieldId() {
+ public short getThriftFieldId() {
return _thriftId;
}
- @Override
- public String getFieldName() {
+ public String getFieldName() {
return _fieldName;
}
}
}
}
- @Override
- public enableAddressFamily_args deepCopy() {
+ public enableAddressFamily_args deepCopy() {
return new enableAddressFamily_args(this);
}
}
}
- @Override
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, Object value) {
switch (field) {
case PEER_IP:
if (value == null) {
}
}
- @Override
- public Object getFieldValue(_Fields field) {
+ public Object getFieldValue(_Fields field) {
switch (field) {
case PEER_IP:
return getPeerIp();
}
/** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
- @Override
- public boolean isSet(_Fields field) {
+ public boolean isSet(_Fields field) {
if (field == null) {
throw new IllegalArgumentException();
}
@Override
public boolean equals(Object that) {
- if (that == null) {
- return false;
- }
- if (that instanceof enableAddressFamily_args) {
- return this.equals((enableAddressFamily_args)that);
- }
+ if (that == null)
+ return false;
+ if (that instanceof enableAddressFamily_args)
+ return this.equals((enableAddressFamily_args)that);
return false;
}
public boolean equals(enableAddressFamily_args that) {
- if (that == null) {
- return false;
- }
+ if (that == null)
+ return false;
boolean this_present_peerIp = true && this.isSetPeerIp();
boolean that_present_peerIp = true && that.isSetPeerIp();
if (this_present_peerIp || that_present_peerIp) {
- if (!(this_present_peerIp && that_present_peerIp)) {
- return false;
- }
- if (!this.peerIp.equals(that.peerIp)) {
- return false;
- }
+ if (!(this_present_peerIp && that_present_peerIp))
+ return false;
+ if (!this.peerIp.equals(that.peerIp))
+ return false;
}
boolean this_present_afi = true && this.isSetAfi();
boolean that_present_afi = true && that.isSetAfi();
if (this_present_afi || that_present_afi) {
- if (!(this_present_afi && that_present_afi)) {
- return false;
- }
- if (!this.afi.equals(that.afi)) {
- return false;
- }
+ if (!(this_present_afi && that_present_afi))
+ return false;
+ if (!this.afi.equals(that.afi))
+ return false;
}
boolean this_present_safi = true && this.isSetSafi();
boolean that_present_safi = true && that.isSetSafi();
if (this_present_safi || that_present_safi) {
- if (!(this_present_safi && that_present_safi)) {
- return false;
- }
- if (!this.safi.equals(that.safi)) {
- return false;
- }
+ if (!(this_present_safi && that_present_safi))
+ return false;
+ if (!this.safi.equals(that.safi))
+ return false;
}
return true;
list.add(present_peerIp);
if (present_peerIp)
list.add(peerIp);
+
boolean present_afi = true && (isSetAfi());
list.add(present_afi);
if (present_afi)
list.add(afi.getValue());
+
boolean present_safi = true && (isSetSafi());
list.add(present_safi);
if (present_safi)
list.add(safi.getValue());
+
return list.hashCode();
}
return 0;
}
- @Override
- public _Fields fieldForId(int fieldId) {
+ public _Fields fieldForId(int fieldId) {
return _Fields.findByThriftId(fieldId);
}
- @Override
- public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
+ public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
}
- @Override
- public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
+ public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
schemes.get(oprot.getScheme()).getScheme().write(oprot, this);
}
sb.append(this.peerIp);
}
first = false;
- if (!first) {
- sb.append(", ");
- }
+ if (!first) sb.append(", ");
sb.append("afi:");
if (this.afi == null) {
sb.append("null");
sb.append(this.afi);
}
first = false;
- if (!first) {
- sb.append(", ");
- }
+ if (!first) sb.append(", ");
sb.append("safi:");
if (this.safi == null) {
sb.append("null");
}
private static class enableAddressFamily_argsStandardSchemeFactory implements SchemeFactory {
- @Override
- public enableAddressFamily_argsStandardScheme getScheme() {
+ public enableAddressFamily_argsStandardScheme getScheme() {
return new enableAddressFamily_argsStandardScheme();
}
}
private static class enableAddressFamily_argsStandardScheme extends StandardScheme<enableAddressFamily_args> {
- @Override
- public void read(org.apache.thrift.protocol.TProtocol iprot, enableAddressFamily_args struct) throws org.apache.thrift.TException {
+ public void read(org.apache.thrift.protocol.TProtocol iprot, enableAddressFamily_args struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
iprot.readStructBegin();
while (true)
struct.validate();
}
- @Override
- public void write(org.apache.thrift.protocol.TProtocol oprot, enableAddressFamily_args struct) throws org.apache.thrift.TException {
+ public void write(org.apache.thrift.protocol.TProtocol oprot, enableAddressFamily_args struct) throws org.apache.thrift.TException {
struct.validate();
oprot.writeStructBegin(STRUCT_DESC);
}
private static class enableAddressFamily_argsTupleSchemeFactory implements SchemeFactory {
- @Override
- public enableAddressFamily_argsTupleScheme getScheme() {
+ public enableAddressFamily_argsTupleScheme getScheme() {
return new enableAddressFamily_argsTupleScheme();
}
}
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) {
- throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
- }
+ if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
return fields;
}
_fieldName = fieldName;
}
- @Override
- public short getThriftFieldId() {
+ public short getThriftFieldId() {
return _thriftId;
}
- @Override
- public String getFieldName() {
+ public String getFieldName() {
return _fieldName;
}
}
this.success = other.success;
}
- @Override
- public enableAddressFamily_result deepCopy() {
+ public enableAddressFamily_result deepCopy() {
return new enableAddressFamily_result(this);
}
__isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __SUCCESS_ISSET_ID, value);
}
- @Override
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, Object value) {
switch (field) {
case SUCCESS:
if (value == null) {
}
}
- @Override
- public Object getFieldValue(_Fields field) {
+ public Object getFieldValue(_Fields field) {
switch (field) {
case SUCCESS:
- return Integer.valueOf(getSuccess());
+ return getSuccess();
}
throw new IllegalStateException();
}
/** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
- @Override
- public boolean isSet(_Fields field) {
+ public boolean isSet(_Fields field) {
if (field == null) {
throw new IllegalArgumentException();
}
@Override
public boolean equals(Object that) {
- if (that == null) {
- return false;
- }
- if (that instanceof enableAddressFamily_result) {
- return this.equals((enableAddressFamily_result)that);
- }
+ if (that == null)
+ return false;
+ if (that instanceof enableAddressFamily_result)
+ return this.equals((enableAddressFamily_result)that);
return false;
}
public boolean equals(enableAddressFamily_result that) {
- if (that == null) {
- return false;
- }
+ if (that == null)
+ return false;
boolean this_present_success = true;
boolean that_present_success = true;
if (this_present_success || that_present_success) {
- if (!(this_present_success && that_present_success)) {
- return false;
- }
- if (this.success != that.success) {
- return false;
- }
+ if (!(this_present_success && that_present_success))
+ return false;
+ if (this.success != that.success)
+ return false;
}
return true;
list.add(present_success);
if (present_success)
list.add(success);
+
return list.hashCode();
}
return 0;
}
- @Override
- public _Fields fieldForId(int fieldId) {
+ public _Fields fieldForId(int fieldId) {
return _Fields.findByThriftId(fieldId);
}
- @Override
- public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
+ public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
}
- @Override
- public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
+ public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
schemes.get(oprot.getScheme()).getScheme().write(oprot, this);
}
}
private static class enableAddressFamily_resultStandardSchemeFactory implements SchemeFactory {
- @Override
- public enableAddressFamily_resultStandardScheme getScheme() {
+ public enableAddressFamily_resultStandardScheme getScheme() {
return new enableAddressFamily_resultStandardScheme();
}
}
private static class enableAddressFamily_resultStandardScheme extends StandardScheme<enableAddressFamily_result> {
- @Override
- public void read(org.apache.thrift.protocol.TProtocol iprot, enableAddressFamily_result struct) throws org.apache.thrift.TException {
+ public void read(org.apache.thrift.protocol.TProtocol iprot, enableAddressFamily_result struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
iprot.readStructBegin();
while (true)
struct.validate();
}
- @Override
- public void write(org.apache.thrift.protocol.TProtocol oprot, enableAddressFamily_result struct) throws org.apache.thrift.TException {
+ public void write(org.apache.thrift.protocol.TProtocol oprot, enableAddressFamily_result struct) throws org.apache.thrift.TException {
struct.validate();
oprot.writeStructBegin(STRUCT_DESC);
}
private static class enableAddressFamily_resultTupleSchemeFactory implements SchemeFactory {
- @Override
- public enableAddressFamily_resultTupleScheme getScheme() {
+ public enableAddressFamily_resultTupleScheme getScheme() {
return new enableAddressFamily_resultTupleScheme();
}
}
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) {
- throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
- }
+ if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
return fields;
}
_fieldName = fieldName;
}
- @Override
- public short getThriftFieldId() {
+ public short getThriftFieldId() {
return _thriftId;
}
- @Override
- public String getFieldName() {
+ public String getFieldName() {
return _fieldName;
}
}
}
}
- @Override
- public disableAddressFamily_args deepCopy() {
+ public disableAddressFamily_args deepCopy() {
return new disableAddressFamily_args(this);
}
}
}
- @Override
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, Object value) {
switch (field) {
case PEER_IP:
if (value == null) {
}
}
- @Override
- public Object getFieldValue(_Fields field) {
+ public Object getFieldValue(_Fields field) {
switch (field) {
case PEER_IP:
return getPeerIp();
}
/** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
- @Override
- public boolean isSet(_Fields field) {
+ public boolean isSet(_Fields field) {
if (field == null) {
throw new IllegalArgumentException();
}
@Override
public boolean equals(Object that) {
- if (that == null) {
- return false;
- }
- if (that instanceof disableAddressFamily_args) {
- return this.equals((disableAddressFamily_args)that);
- }
+ if (that == null)
+ return false;
+ if (that instanceof disableAddressFamily_args)
+ return this.equals((disableAddressFamily_args)that);
return false;
}
public boolean equals(disableAddressFamily_args that) {
- if (that == null) {
- return false;
- }
+ if (that == null)
+ return false;
boolean this_present_peerIp = true && this.isSetPeerIp();
boolean that_present_peerIp = true && that.isSetPeerIp();
if (this_present_peerIp || that_present_peerIp) {
- if (!(this_present_peerIp && that_present_peerIp)) {
- return false;
- }
- if (!this.peerIp.equals(that.peerIp)) {
- return false;
- }
+ if (!(this_present_peerIp && that_present_peerIp))
+ return false;
+ if (!this.peerIp.equals(that.peerIp))
+ return false;
}
boolean this_present_afi = true && this.isSetAfi();
boolean that_present_afi = true && that.isSetAfi();
if (this_present_afi || that_present_afi) {
- if (!(this_present_afi && that_present_afi)) {
- return false;
- }
- if (!this.afi.equals(that.afi)) {
- return false;
- }
+ if (!(this_present_afi && that_present_afi))
+ return false;
+ if (!this.afi.equals(that.afi))
+ return false;
}
boolean this_present_safi = true && this.isSetSafi();
boolean that_present_safi = true && that.isSetSafi();
if (this_present_safi || that_present_safi) {
- if (!(this_present_safi && that_present_safi)) {
- return false;
- }
- if (!this.safi.equals(that.safi)) {
- return false;
- }
+ if (!(this_present_safi && that_present_safi))
+ return false;
+ if (!this.safi.equals(that.safi))
+ return false;
}
return true;
list.add(present_peerIp);
if (present_peerIp)
list.add(peerIp);
+
boolean present_afi = true && (isSetAfi());
list.add(present_afi);
if (present_afi)
list.add(afi.getValue());
+
boolean present_safi = true && (isSetSafi());
list.add(present_safi);
if (present_safi)
list.add(safi.getValue());
+
return list.hashCode();
}
return 0;
}
- @Override
- public _Fields fieldForId(int fieldId) {
+ public _Fields fieldForId(int fieldId) {
return _Fields.findByThriftId(fieldId);
}
- @Override
- public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
+ public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
}
- @Override
- public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
+ public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
schemes.get(oprot.getScheme()).getScheme().write(oprot, this);
}
sb.append(this.peerIp);
}
first = false;
- if (!first) {
- sb.append(", ");
- }
+ if (!first) sb.append(", ");
sb.append("afi:");
if (this.afi == null) {
sb.append("null");
sb.append(this.afi);
}
first = false;
- if (!first) {
- sb.append(", ");
- }
+ if (!first) sb.append(", ");
sb.append("safi:");
if (this.safi == null) {
sb.append("null");
}
private static class disableAddressFamily_argsStandardSchemeFactory implements SchemeFactory {
- @Override
- public disableAddressFamily_argsStandardScheme getScheme() {
+ public disableAddressFamily_argsStandardScheme getScheme() {
return new disableAddressFamily_argsStandardScheme();
}
}
private static class disableAddressFamily_argsStandardScheme extends StandardScheme<disableAddressFamily_args> {
- @Override
- public void read(org.apache.thrift.protocol.TProtocol iprot, disableAddressFamily_args struct) throws org.apache.thrift.TException {
+ public void read(org.apache.thrift.protocol.TProtocol iprot, disableAddressFamily_args struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
iprot.readStructBegin();
while (true)
struct.validate();
}
- @Override
- public void write(org.apache.thrift.protocol.TProtocol oprot, disableAddressFamily_args struct) throws org.apache.thrift.TException {
+ public void write(org.apache.thrift.protocol.TProtocol oprot, disableAddressFamily_args struct) throws org.apache.thrift.TException {
struct.validate();
oprot.writeStructBegin(STRUCT_DESC);
}
private static class disableAddressFamily_argsTupleSchemeFactory implements SchemeFactory {
- @Override
- public disableAddressFamily_argsTupleScheme getScheme() {
+ public disableAddressFamily_argsTupleScheme getScheme() {
return new disableAddressFamily_argsTupleScheme();
}
}
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) {
- throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
- }
+ if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
return fields;
}
_fieldName = fieldName;
}
- @Override
- public short getThriftFieldId() {
+ public short getThriftFieldId() {
return _thriftId;
}
- @Override
- public String getFieldName() {
+ public String getFieldName() {
return _fieldName;
}
}
this.success = other.success;
}
- @Override
- public disableAddressFamily_result deepCopy() {
+ public disableAddressFamily_result deepCopy() {
return new disableAddressFamily_result(this);
}
__isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __SUCCESS_ISSET_ID, value);
}
- @Override
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, Object value) {
switch (field) {
case SUCCESS:
if (value == null) {
}
}
- @Override
- public Object getFieldValue(_Fields field) {
+ public Object getFieldValue(_Fields field) {
switch (field) {
case SUCCESS:
- return Integer.valueOf(getSuccess());
+ return getSuccess();
}
throw new IllegalStateException();
}
/** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
- @Override
- public boolean isSet(_Fields field) {
+ public boolean isSet(_Fields field) {
if (field == null) {
throw new IllegalArgumentException();
}
@Override
public boolean equals(Object that) {
- if (that == null) {
- return false;
- }
- if (that instanceof disableAddressFamily_result) {
- return this.equals((disableAddressFamily_result)that);
- }
+ if (that == null)
+ return false;
+ if (that instanceof disableAddressFamily_result)
+ return this.equals((disableAddressFamily_result)that);
return false;
}
public boolean equals(disableAddressFamily_result that) {
- if (that == null) {
- return false;
- }
+ if (that == null)
+ return false;
boolean this_present_success = true;
boolean that_present_success = true;
if (this_present_success || that_present_success) {
- if (!(this_present_success && that_present_success)) {
- return false;
- }
- if (this.success != that.success) {
- return false;
- }
+ if (!(this_present_success && that_present_success))
+ return false;
+ if (this.success != that.success)
+ return false;
}
return true;
list.add(present_success);
if (present_success)
list.add(success);
+
return list.hashCode();
}
return 0;
}
- @Override
- public _Fields fieldForId(int fieldId) {
+ public _Fields fieldForId(int fieldId) {
return _Fields.findByThriftId(fieldId);
}
- @Override
- public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
+ public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
}
- @Override
- public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
+ public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
schemes.get(oprot.getScheme()).getScheme().write(oprot, this);
}
}
private static class disableAddressFamily_resultStandardSchemeFactory implements SchemeFactory {
- @Override
- public disableAddressFamily_resultStandardScheme getScheme() {
+ public disableAddressFamily_resultStandardScheme getScheme() {
return new disableAddressFamily_resultStandardScheme();
}
}
private static class disableAddressFamily_resultStandardScheme extends StandardScheme<disableAddressFamily_result> {
- @Override
- public void read(org.apache.thrift.protocol.TProtocol iprot, disableAddressFamily_result struct) throws org.apache.thrift.TException {
+ public void read(org.apache.thrift.protocol.TProtocol iprot, disableAddressFamily_result struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
iprot.readStructBegin();
while (true)
struct.validate();
}
- @Override
- public void write(org.apache.thrift.protocol.TProtocol oprot, disableAddressFamily_result struct) throws org.apache.thrift.TException {
+ public void write(org.apache.thrift.protocol.TProtocol oprot, disableAddressFamily_result struct) throws org.apache.thrift.TException {
struct.validate();
oprot.writeStructBegin(STRUCT_DESC);
}
private static class disableAddressFamily_resultTupleSchemeFactory implements SchemeFactory {
- @Override
- public disableAddressFamily_resultTupleScheme getScheme() {
+ public disableAddressFamily_resultTupleScheme getScheme() {
return new disableAddressFamily_resultTupleScheme();
}
}
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) {
- throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
- }
+ if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
return fields;
}
_fieldName = fieldName;
}
- @Override
- public short getThriftFieldId() {
+ public short getThriftFieldId() {
return _thriftId;
}
- @Override
- public String getFieldName() {
+ public String getFieldName() {
return _fieldName;
}
}
}
}
- @Override
- public setLogConfig_args deepCopy() {
+ public setLogConfig_args deepCopy() {
return new setLogConfig_args(this);
}
}
}
- @Override
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, Object value) {
switch (field) {
case LOG_FILE_NAME:
if (value == null) {
}
}
- @Override
- public Object getFieldValue(_Fields field) {
+ public Object getFieldValue(_Fields field) {
switch (field) {
case LOG_FILE_NAME:
return getLogFileName();
}
/** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
- @Override
- public boolean isSet(_Fields field) {
+ public boolean isSet(_Fields field) {
if (field == null) {
throw new IllegalArgumentException();
}
@Override
public boolean equals(Object that) {
- if (that == null) {
- return false;
- }
- if (that instanceof setLogConfig_args) {
- return this.equals((setLogConfig_args)that);
- }
+ if (that == null)
+ return false;
+ if (that instanceof setLogConfig_args)
+ return this.equals((setLogConfig_args)that);
return false;
}
public boolean equals(setLogConfig_args that) {
- if (that == null) {
- return false;
- }
+ if (that == null)
+ return false;
boolean this_present_logFileName = true && this.isSetLogFileName();
boolean that_present_logFileName = true && that.isSetLogFileName();
if (this_present_logFileName || that_present_logFileName) {
- if (!(this_present_logFileName && that_present_logFileName)) {
- return false;
- }
- if (!this.logFileName.equals(that.logFileName)) {
- return false;
- }
+ if (!(this_present_logFileName && that_present_logFileName))
+ return false;
+ if (!this.logFileName.equals(that.logFileName))
+ return false;
}
boolean this_present_logLevel = true && this.isSetLogLevel();
boolean that_present_logLevel = true && that.isSetLogLevel();
if (this_present_logLevel || that_present_logLevel) {
- if (!(this_present_logLevel && that_present_logLevel)) {
- return false;
- }
- if (!this.logLevel.equals(that.logLevel)) {
- return false;
- }
+ if (!(this_present_logLevel && that_present_logLevel))
+ return false;
+ if (!this.logLevel.equals(that.logLevel))
+ return false;
}
return true;
list.add(present_logFileName);
if (present_logFileName)
list.add(logFileName);
+
boolean present_logLevel = true && (isSetLogLevel());
list.add(present_logLevel);
if (present_logLevel)
list.add(logLevel);
+
return list.hashCode();
}
return 0;
}
- @Override
- public _Fields fieldForId(int fieldId) {
+ public _Fields fieldForId(int fieldId) {
return _Fields.findByThriftId(fieldId);
}
- @Override
- public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
+ public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
}
- @Override
- public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
+ public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
schemes.get(oprot.getScheme()).getScheme().write(oprot, this);
}
sb.append(this.logFileName);
}
first = false;
- if (!first) {
- sb.append(", ");
- }
+ if (!first) sb.append(", ");
sb.append("logLevel:");
if (this.logLevel == null) {
sb.append("null");
}
private static class setLogConfig_argsStandardSchemeFactory implements SchemeFactory {
- @Override
- public setLogConfig_argsStandardScheme getScheme() {
+ public setLogConfig_argsStandardScheme getScheme() {
return new setLogConfig_argsStandardScheme();
}
}
private static class setLogConfig_argsStandardScheme extends StandardScheme<setLogConfig_args> {
- @Override
- public void read(org.apache.thrift.protocol.TProtocol iprot, setLogConfig_args struct) throws org.apache.thrift.TException {
+ public void read(org.apache.thrift.protocol.TProtocol iprot, setLogConfig_args struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
iprot.readStructBegin();
while (true)
struct.validate();
}
- @Override
- public void write(org.apache.thrift.protocol.TProtocol oprot, setLogConfig_args struct) throws org.apache.thrift.TException {
+ public void write(org.apache.thrift.protocol.TProtocol oprot, setLogConfig_args struct) throws org.apache.thrift.TException {
struct.validate();
oprot.writeStructBegin(STRUCT_DESC);
}
private static class setLogConfig_argsTupleSchemeFactory implements SchemeFactory {
- @Override
- public setLogConfig_argsTupleScheme getScheme() {
+ public setLogConfig_argsTupleScheme getScheme() {
return new setLogConfig_argsTupleScheme();
}
}
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) {
- throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
- }
+ if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
return fields;
}
_fieldName = fieldName;
}
- @Override
- public short getThriftFieldId() {
+ public short getThriftFieldId() {
return _thriftId;
}
- @Override
- public String getFieldName() {
+ public String getFieldName() {
return _fieldName;
}
}
this.success = other.success;
}
- @Override
- public setLogConfig_result deepCopy() {
+ public setLogConfig_result deepCopy() {
return new setLogConfig_result(this);
}
__isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __SUCCESS_ISSET_ID, value);
}
- @Override
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, Object value) {
switch (field) {
case SUCCESS:
if (value == null) {
}
}
- @Override
- public Object getFieldValue(_Fields field) {
+ public Object getFieldValue(_Fields field) {
switch (field) {
case SUCCESS:
- return Integer.valueOf(getSuccess());
+ return getSuccess();
}
throw new IllegalStateException();
}
/** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
- @Override
- public boolean isSet(_Fields field) {
+ public boolean isSet(_Fields field) {
if (field == null) {
throw new IllegalArgumentException();
}
@Override
public boolean equals(Object that) {
- if (that == null) {
- return false;
- }
- if (that instanceof setLogConfig_result) {
- return this.equals((setLogConfig_result)that);
- }
+ if (that == null)
+ return false;
+ if (that instanceof setLogConfig_result)
+ return this.equals((setLogConfig_result)that);
return false;
}
public boolean equals(setLogConfig_result that) {
- if (that == null) {
- return false;
- }
+ if (that == null)
+ return false;
boolean this_present_success = true;
boolean that_present_success = true;
if (this_present_success || that_present_success) {
- if (!(this_present_success && that_present_success)) {
- return false;
- }
- if (this.success != that.success) {
- return false;
- }
+ if (!(this_present_success && that_present_success))
+ return false;
+ if (this.success != that.success)
+ return false;
}
return true;
list.add(present_success);
if (present_success)
list.add(success);
+
return list.hashCode();
}
return 0;
}
- @Override
- public _Fields fieldForId(int fieldId) {
+ public _Fields fieldForId(int fieldId) {
return _Fields.findByThriftId(fieldId);
}
- @Override
- public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
+ public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
}
- @Override
- public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
+ public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
schemes.get(oprot.getScheme()).getScheme().write(oprot, this);
}
}
private static class setLogConfig_resultStandardSchemeFactory implements SchemeFactory {
- @Override
- public setLogConfig_resultStandardScheme getScheme() {
+ public setLogConfig_resultStandardScheme getScheme() {
return new setLogConfig_resultStandardScheme();
}
}
private static class setLogConfig_resultStandardScheme extends StandardScheme<setLogConfig_result> {
- @Override
- public void read(org.apache.thrift.protocol.TProtocol iprot, setLogConfig_result struct) throws org.apache.thrift.TException {
+ public void read(org.apache.thrift.protocol.TProtocol iprot, setLogConfig_result struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
iprot.readStructBegin();
while (true)
struct.validate();
}
- @Override
- public void write(org.apache.thrift.protocol.TProtocol oprot, setLogConfig_result struct) throws org.apache.thrift.TException {
+ public void write(org.apache.thrift.protocol.TProtocol oprot, setLogConfig_result struct) throws org.apache.thrift.TException {
struct.validate();
oprot.writeStructBegin(STRUCT_DESC);
}
private static class setLogConfig_resultTupleSchemeFactory implements SchemeFactory {
- @Override
- public setLogConfig_resultTupleScheme getScheme() {
+ public setLogConfig_resultTupleScheme getScheme() {
return new setLogConfig_resultTupleScheme();
}
}
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) {
- throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
- }
+ if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
return fields;
}
_fieldName = fieldName;
}
- @Override
- public short getThriftFieldId() {
+ public short getThriftFieldId() {
return _thriftId;
}
- @Override
- public String getFieldName() {
+ public String getFieldName() {
return _fieldName;
}
}
this.stalepathTime = other.stalepathTime;
}
- @Override
- public enableGracefulRestart_args deepCopy() {
+ public enableGracefulRestart_args deepCopy() {
return new enableGracefulRestart_args(this);
}
__isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __STALEPATHTIME_ISSET_ID, value);
}
- @Override
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, Object value) {
switch (field) {
case STALEPATH_TIME:
if (value == null) {
}
}
- @Override
- public Object getFieldValue(_Fields field) {
+ public Object getFieldValue(_Fields field) {
switch (field) {
case STALEPATH_TIME:
- return Integer.valueOf(getStalepathTime());
+ return getStalepathTime();
}
throw new IllegalStateException();
}
/** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
- @Override
- public boolean isSet(_Fields field) {
+ public boolean isSet(_Fields field) {
if (field == null) {
throw new IllegalArgumentException();
}
@Override
public boolean equals(Object that) {
- if (that == null) {
- return false;
- }
- if (that instanceof enableGracefulRestart_args) {
- return this.equals((enableGracefulRestart_args)that);
- }
+ if (that == null)
+ return false;
+ if (that instanceof enableGracefulRestart_args)
+ return this.equals((enableGracefulRestart_args)that);
return false;
}
public boolean equals(enableGracefulRestart_args that) {
- if (that == null) {
- return false;
- }
+ if (that == null)
+ return false;
boolean this_present_stalepathTime = true;
boolean that_present_stalepathTime = true;
if (this_present_stalepathTime || that_present_stalepathTime) {
- if (!(this_present_stalepathTime && that_present_stalepathTime)) {
- return false;
- }
- if (this.stalepathTime != that.stalepathTime) {
- return false;
- }
+ if (!(this_present_stalepathTime && that_present_stalepathTime))
+ return false;
+ if (this.stalepathTime != that.stalepathTime)
+ return false;
}
return true;
list.add(present_stalepathTime);
if (present_stalepathTime)
list.add(stalepathTime);
+
return list.hashCode();
}
return 0;
}
- @Override
- public _Fields fieldForId(int fieldId) {
+ public _Fields fieldForId(int fieldId) {
return _Fields.findByThriftId(fieldId);
}
- @Override
- public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
+ public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
}
- @Override
- public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
+ public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
schemes.get(oprot.getScheme()).getScheme().write(oprot, this);
}
}
private static class enableGracefulRestart_argsStandardSchemeFactory implements SchemeFactory {
- @Override
- public enableGracefulRestart_argsStandardScheme getScheme() {
+ public enableGracefulRestart_argsStandardScheme getScheme() {
return new enableGracefulRestart_argsStandardScheme();
}
}
private static class enableGracefulRestart_argsStandardScheme extends StandardScheme<enableGracefulRestart_args> {
- @Override
- public void read(org.apache.thrift.protocol.TProtocol iprot, enableGracefulRestart_args struct) throws org.apache.thrift.TException {
+ public void read(org.apache.thrift.protocol.TProtocol iprot, enableGracefulRestart_args struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
iprot.readStructBegin();
while (true)
struct.validate();
}
- @Override
- public void write(org.apache.thrift.protocol.TProtocol oprot, enableGracefulRestart_args struct) throws org.apache.thrift.TException {
+ public void write(org.apache.thrift.protocol.TProtocol oprot, enableGracefulRestart_args struct) throws org.apache.thrift.TException {
struct.validate();
oprot.writeStructBegin(STRUCT_DESC);
}
private static class enableGracefulRestart_argsTupleSchemeFactory implements SchemeFactory {
- @Override
- public enableGracefulRestart_argsTupleScheme getScheme() {
+ public enableGracefulRestart_argsTupleScheme getScheme() {
return new enableGracefulRestart_argsTupleScheme();
}
}
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) {
- throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
- }
+ if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
return fields;
}
_fieldName = fieldName;
}
- @Override
- public short getThriftFieldId() {
+ public short getThriftFieldId() {
return _thriftId;
}
- @Override
- public String getFieldName() {
+ public String getFieldName() {
return _fieldName;
}
}
this.success = other.success;
}
- @Override
- public enableGracefulRestart_result deepCopy() {
+ public enableGracefulRestart_result deepCopy() {
return new enableGracefulRestart_result(this);
}
__isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __SUCCESS_ISSET_ID, value);
}
- @Override
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, Object value) {
switch (field) {
case SUCCESS:
if (value == null) {
}
}
- @Override
- public Object getFieldValue(_Fields field) {
+ public Object getFieldValue(_Fields field) {
switch (field) {
case SUCCESS:
- return Integer.valueOf(getSuccess());
+ return getSuccess();
}
throw new IllegalStateException();
}
/** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
- @Override
- public boolean isSet(_Fields field) {
+ public boolean isSet(_Fields field) {
if (field == null) {
throw new IllegalArgumentException();
}
@Override
public boolean equals(Object that) {
- if (that == null) {
- return false;
- }
- if (that instanceof enableGracefulRestart_result) {
- return this.equals((enableGracefulRestart_result)that);
- }
+ if (that == null)
+ return false;
+ if (that instanceof enableGracefulRestart_result)
+ return this.equals((enableGracefulRestart_result)that);
return false;
}
public boolean equals(enableGracefulRestart_result that) {
- if (that == null) {
- return false;
- }
+ if (that == null)
+ return false;
boolean this_present_success = true;
boolean that_present_success = true;
if (this_present_success || that_present_success) {
- if (!(this_present_success && that_present_success)) {
- return false;
- }
- if (this.success != that.success) {
- return false;
- }
+ if (!(this_present_success && that_present_success))
+ return false;
+ if (this.success != that.success)
+ return false;
}
return true;
list.add(present_success);
if (present_success)
list.add(success);
+
return list.hashCode();
}
return 0;
}
- @Override
- public _Fields fieldForId(int fieldId) {
+ public _Fields fieldForId(int fieldId) {
return _Fields.findByThriftId(fieldId);
}
- @Override
- public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
+ public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
}
- @Override
- public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
+ public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
schemes.get(oprot.getScheme()).getScheme().write(oprot, this);
}
}
private static class enableGracefulRestart_resultStandardSchemeFactory implements SchemeFactory {
- @Override
- public enableGracefulRestart_resultStandardScheme getScheme() {
+ public enableGracefulRestart_resultStandardScheme getScheme() {
return new enableGracefulRestart_resultStandardScheme();
}
}
private static class enableGracefulRestart_resultStandardScheme extends StandardScheme<enableGracefulRestart_result> {
- @Override
- public void read(org.apache.thrift.protocol.TProtocol iprot, enableGracefulRestart_result struct) throws org.apache.thrift.TException {
+ public void read(org.apache.thrift.protocol.TProtocol iprot, enableGracefulRestart_result struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
iprot.readStructBegin();
while (true)
struct.validate();
}
- @Override
- public void write(org.apache.thrift.protocol.TProtocol oprot, enableGracefulRestart_result struct) throws org.apache.thrift.TException {
+ public void write(org.apache.thrift.protocol.TProtocol oprot, enableGracefulRestart_result struct) throws org.apache.thrift.TException {
struct.validate();
oprot.writeStructBegin(STRUCT_DESC);
}
private static class enableGracefulRestart_resultTupleSchemeFactory implements SchemeFactory {
- @Override
- public enableGracefulRestart_resultTupleScheme getScheme() {
+ public enableGracefulRestart_resultTupleScheme getScheme() {
return new enableGracefulRestart_resultTupleScheme();
}
}
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) {
- throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
- }
+ if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
return fields;
}
_fieldName = fieldName;
}
- @Override
- public short getThriftFieldId() {
+ public short getThriftFieldId() {
return _thriftId;
}
- @Override
- public String getFieldName() {
+ public String getFieldName() {
return _fieldName;
}
}
public disableGracefulRestart_args(disableGracefulRestart_args other) {
}
- @Override
- public disableGracefulRestart_args deepCopy() {
+ public disableGracefulRestart_args deepCopy() {
return new disableGracefulRestart_args(this);
}
public void clear() {
}
- @Override
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, Object value) {
switch (field) {
}
}
- @Override
- public Object getFieldValue(_Fields field) {
+ public Object getFieldValue(_Fields field) {
switch (field) {
}
throw new IllegalStateException();
}
/** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
- @Override
- public boolean isSet(_Fields field) {
+ public boolean isSet(_Fields field) {
if (field == null) {
throw new IllegalArgumentException();
}
@Override
public boolean equals(Object that) {
- if (that == null) {
- return false;
- }
- if (that instanceof disableGracefulRestart_args) {
- return this.equals((disableGracefulRestart_args)that);
- }
+ if (that == null)
+ return false;
+ if (that instanceof disableGracefulRestart_args)
+ return this.equals((disableGracefulRestart_args)that);
return false;
}
public boolean equals(disableGracefulRestart_args that) {
- if (that == null) {
- return false;
- }
+ if (that == null)
+ return false;
return true;
}
return 0;
}
- @Override
- public _Fields fieldForId(int fieldId) {
+ public _Fields fieldForId(int fieldId) {
return _Fields.findByThriftId(fieldId);
}
- @Override
- public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
+ public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
}
- @Override
- public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
+ public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
schemes.get(oprot.getScheme()).getScheme().write(oprot, this);
}
}
private static class disableGracefulRestart_argsStandardSchemeFactory implements SchemeFactory {
- @Override
- public disableGracefulRestart_argsStandardScheme getScheme() {
+ public disableGracefulRestart_argsStandardScheme getScheme() {
return new disableGracefulRestart_argsStandardScheme();
}
}
private static class disableGracefulRestart_argsStandardScheme extends StandardScheme<disableGracefulRestart_args> {
- @Override
- public void read(org.apache.thrift.protocol.TProtocol iprot, disableGracefulRestart_args struct) throws org.apache.thrift.TException {
+ public void read(org.apache.thrift.protocol.TProtocol iprot, disableGracefulRestart_args struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
iprot.readStructBegin();
while (true)
struct.validate();
}
- @Override
- public void write(org.apache.thrift.protocol.TProtocol oprot, disableGracefulRestart_args struct) throws org.apache.thrift.TException {
+ public void write(org.apache.thrift.protocol.TProtocol oprot, disableGracefulRestart_args struct) throws org.apache.thrift.TException {
struct.validate();
oprot.writeStructBegin(STRUCT_DESC);
}
private static class disableGracefulRestart_argsTupleSchemeFactory implements SchemeFactory {
- @Override
- public disableGracefulRestart_argsTupleScheme getScheme() {
+ public disableGracefulRestart_argsTupleScheme getScheme() {
return new disableGracefulRestart_argsTupleScheme();
}
}
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) {
- throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
- }
+ if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
return fields;
}
_fieldName = fieldName;
}
- @Override
- public short getThriftFieldId() {
+ public short getThriftFieldId() {
return _thriftId;
}
- @Override
- public String getFieldName() {
+ public String getFieldName() {
return _fieldName;
}
}
this.success = other.success;
}
- @Override
- public disableGracefulRestart_result deepCopy() {
+ public disableGracefulRestart_result deepCopy() {
return new disableGracefulRestart_result(this);
}
__isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __SUCCESS_ISSET_ID, value);
}
- @Override
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, Object value) {
switch (field) {
case SUCCESS:
if (value == null) {
}
}
- @Override
- public Object getFieldValue(_Fields field) {
+ public Object getFieldValue(_Fields field) {
switch (field) {
case SUCCESS:
- return Integer.valueOf(getSuccess());
+ return getSuccess();
}
throw new IllegalStateException();
}
/** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
- @Override
- public boolean isSet(_Fields field) {
+ public boolean isSet(_Fields field) {
if (field == null) {
throw new IllegalArgumentException();
}
@Override
public boolean equals(Object that) {
- if (that == null) {
- return false;
- }
- if (that instanceof disableGracefulRestart_result) {
- return this.equals((disableGracefulRestart_result)that);
- }
+ if (that == null)
+ return false;
+ if (that instanceof disableGracefulRestart_result)
+ return this.equals((disableGracefulRestart_result)that);
return false;
}
public boolean equals(disableGracefulRestart_result that) {
- if (that == null) {
- return false;
- }
+ if (that == null)
+ return false;
boolean this_present_success = true;
boolean that_present_success = true;
if (this_present_success || that_present_success) {
- if (!(this_present_success && that_present_success)) {
- return false;
- }
- if (this.success != that.success) {
- return false;
- }
+ if (!(this_present_success && that_present_success))
+ return false;
+ if (this.success != that.success)
+ return false;
}
return true;
list.add(present_success);
if (present_success)
list.add(success);
+
return list.hashCode();
}
return 0;
}
- @Override
- public _Fields fieldForId(int fieldId) {
+ public _Fields fieldForId(int fieldId) {
return _Fields.findByThriftId(fieldId);
}
- @Override
- public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
+ public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
}
- @Override
- public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
+ public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
schemes.get(oprot.getScheme()).getScheme().write(oprot, this);
}
}
private static class disableGracefulRestart_resultStandardSchemeFactory implements SchemeFactory {
- @Override
- public disableGracefulRestart_resultStandardScheme getScheme() {
+ public disableGracefulRestart_resultStandardScheme getScheme() {
return new disableGracefulRestart_resultStandardScheme();
}
}
private static class disableGracefulRestart_resultStandardScheme extends StandardScheme<disableGracefulRestart_result> {
- @Override
- public void read(org.apache.thrift.protocol.TProtocol iprot, disableGracefulRestart_result struct) throws org.apache.thrift.TException {
+ public void read(org.apache.thrift.protocol.TProtocol iprot, disableGracefulRestart_result struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
iprot.readStructBegin();
while (true)
struct.validate();
}
- @Override
- public void write(org.apache.thrift.protocol.TProtocol oprot, disableGracefulRestart_result struct) throws org.apache.thrift.TException {
+ public void write(org.apache.thrift.protocol.TProtocol oprot, disableGracefulRestart_result struct) throws org.apache.thrift.TException {
struct.validate();
oprot.writeStructBegin(STRUCT_DESC);
}
private static class disableGracefulRestart_resultTupleSchemeFactory implements SchemeFactory {
- @Override
- public disableGracefulRestart_resultTupleScheme getScheme() {
+ public disableGracefulRestart_resultTupleScheme getScheme() {
return new disableGracefulRestart_resultTupleScheme();
}
}
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) {
- throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
- }
+ if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
return fields;
}
_fieldName = fieldName;
}
- @Override
- public short getThriftFieldId() {
+ public short getThriftFieldId() {
return _thriftId;
}
- @Override
- public String getFieldName() {
+ public String getFieldName() {
return _fieldName;
}
}
}
}
- @Override
- public getRoutes_args deepCopy() {
+ public getRoutes_args deepCopy() {
return new getRoutes_args(this);
}
}
}
- @Override
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, Object value) {
switch (field) {
case P_TYPE:
if (value == null) {
}
}
- @Override
- public Object getFieldValue(_Fields field) {
+ public Object getFieldValue(_Fields field) {
switch (field) {
case P_TYPE:
return getP_type();
case OPTYPE:
- return Integer.valueOf(getOptype());
+ return getOptype();
case WIN_SIZE:
- return Integer.valueOf(getWinSize());
+ return getWinSize();
case AFI:
return getAfi();
}
/** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
- @Override
- public boolean isSet(_Fields field) {
+ public boolean isSet(_Fields field) {
if (field == null) {
throw new IllegalArgumentException();
}
@Override
public boolean equals(Object that) {
- if (that == null) {
- return false;
- }
- if (that instanceof getRoutes_args) {
- return this.equals((getRoutes_args)that);
- }
+ if (that == null)
+ return false;
+ if (that instanceof getRoutes_args)
+ return this.equals((getRoutes_args)that);
return false;
}
public boolean equals(getRoutes_args that) {
- if (that == null) {
- return false;
- }
+ if (that == null)
+ return false;
boolean this_present_p_type = true && this.isSetP_type();
boolean that_present_p_type = true && that.isSetP_type();
if (this_present_p_type || that_present_p_type) {
- if (!(this_present_p_type && that_present_p_type)) {
- return false;
- }
- if (!this.p_type.equals(that.p_type)) {
- return false;
- }
+ if (!(this_present_p_type && that_present_p_type))
+ return false;
+ if (!this.p_type.equals(that.p_type))
+ return false;
}
boolean this_present_optype = true;
boolean that_present_optype = true;
if (this_present_optype || that_present_optype) {
- if (!(this_present_optype && that_present_optype)) {
- return false;
- }
- if (this.optype != that.optype) {
- return false;
- }
+ if (!(this_present_optype && that_present_optype))
+ return false;
+ if (this.optype != that.optype)
+ return false;
}
boolean this_present_winSize = true;
boolean that_present_winSize = true;
if (this_present_winSize || that_present_winSize) {
- if (!(this_present_winSize && that_present_winSize)) {
- return false;
- }
- if (this.winSize != that.winSize) {
- return false;
- }
+ if (!(this_present_winSize && that_present_winSize))
+ return false;
+ if (this.winSize != that.winSize)
+ return false;
}
boolean this_present_afi = true && this.isSetAfi();
boolean that_present_afi = true && that.isSetAfi();
if (this_present_afi || that_present_afi) {
- if (!(this_present_afi && that_present_afi)) {
- return false;
- }
- if (!this.afi.equals(that.afi)) {
- return false;
- }
+ if (!(this_present_afi && that_present_afi))
+ return false;
+ if (!this.afi.equals(that.afi))
+ return false;
}
return true;
list.add(present_p_type);
if (present_p_type)
list.add(p_type.getValue());
+
boolean present_optype = true;
list.add(present_optype);
if (present_optype)
list.add(optype);
+
boolean present_winSize = true;
list.add(present_winSize);
if (present_winSize)
list.add(winSize);
+
boolean present_afi = true && (isSetAfi());
list.add(present_afi);
if (present_afi)
list.add(afi.getValue());
+
return list.hashCode();
}
return 0;
}
- @Override
- public _Fields fieldForId(int fieldId) {
+ public _Fields fieldForId(int fieldId) {
return _Fields.findByThriftId(fieldId);
}
- @Override
- public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
+ public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
}
- @Override
- public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
+ public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
schemes.get(oprot.getScheme()).getScheme().write(oprot, this);
}
sb.append(this.p_type);
}
first = false;
- if (!first) {
- sb.append(", ");
- }
+ if (!first) sb.append(", ");
sb.append("optype:");
sb.append(this.optype);
first = false;
- if (!first) {
- sb.append(", ");
- }
+ if (!first) sb.append(", ");
sb.append("winSize:");
sb.append(this.winSize);
first = false;
- if (!first) {
- sb.append(", ");
- }
+ if (!first) sb.append(", ");
sb.append("afi:");
if (this.afi == null) {
sb.append("null");
}
private static class getRoutes_argsStandardSchemeFactory implements SchemeFactory {
- @Override
- public getRoutes_argsStandardScheme getScheme() {
+ public getRoutes_argsStandardScheme getScheme() {
return new getRoutes_argsStandardScheme();
}
}
private static class getRoutes_argsStandardScheme extends StandardScheme<getRoutes_args> {
- @Override
- public void read(org.apache.thrift.protocol.TProtocol iprot, getRoutes_args struct) throws org.apache.thrift.TException {
+ public void read(org.apache.thrift.protocol.TProtocol iprot, getRoutes_args struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
iprot.readStructBegin();
while (true)
struct.validate();
}
- @Override
- public void write(org.apache.thrift.protocol.TProtocol oprot, getRoutes_args struct) throws org.apache.thrift.TException {
+ public void write(org.apache.thrift.protocol.TProtocol oprot, getRoutes_args struct) throws org.apache.thrift.TException {
struct.validate();
oprot.writeStructBegin(STRUCT_DESC);
}
private static class getRoutes_argsTupleSchemeFactory implements SchemeFactory {
- @Override
- public getRoutes_argsTupleScheme getScheme() {
+ public getRoutes_argsTupleScheme getScheme() {
return new getRoutes_argsTupleScheme();
}
}
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) {
- throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
- }
+ if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
return fields;
}
_fieldName = fieldName;
}
- @Override
- public short getThriftFieldId() {
+ public short getThriftFieldId() {
return _thriftId;
}
- @Override
- public String getFieldName() {
+ public String getFieldName() {
return _fieldName;
}
}
}
}
- @Override
- public getRoutes_result deepCopy() {
+ public getRoutes_result deepCopy() {
return new getRoutes_result(this);
}
}
}
- @Override
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, Object value) {
switch (field) {
case SUCCESS:
if (value == null) {
}
}
- @Override
- public Object getFieldValue(_Fields field) {
+ public Object getFieldValue(_Fields field) {
switch (field) {
case SUCCESS:
return getSuccess();
}
/** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
- @Override
- public boolean isSet(_Fields field) {
+ public boolean isSet(_Fields field) {
if (field == null) {
throw new IllegalArgumentException();
}
@Override
public boolean equals(Object that) {
- if (that == null) {
- return false;
- }
- if (that instanceof getRoutes_result) {
- return this.equals((getRoutes_result)that);
- }
+ if (that == null)
+ return false;
+ if (that instanceof getRoutes_result)
+ return this.equals((getRoutes_result)that);
return false;
}
public boolean equals(getRoutes_result that) {
- if (that == null) {
- return false;
- }
+ if (that == null)
+ return false;
boolean this_present_success = true && this.isSetSuccess();
boolean that_present_success = true && that.isSetSuccess();
if (this_present_success || that_present_success) {
- if (!(this_present_success && that_present_success)) {
- return false;
- }
- if (!this.success.equals(that.success)) {
- return false;
- }
+ if (!(this_present_success && that_present_success))
+ return false;
+ if (!this.success.equals(that.success))
+ return false;
}
return true;
list.add(present_success);
if (present_success)
list.add(success);
+
return list.hashCode();
}
return 0;
}
- @Override
- public _Fields fieldForId(int fieldId) {
+ public _Fields fieldForId(int fieldId) {
return _Fields.findByThriftId(fieldId);
}
- @Override
- public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
+ public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
}
- @Override
- public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
+ public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
schemes.get(oprot.getScheme()).getScheme().write(oprot, this);
}
}
private static class getRoutes_resultStandardSchemeFactory implements SchemeFactory {
- @Override
- public getRoutes_resultStandardScheme getScheme() {
+ public getRoutes_resultStandardScheme getScheme() {
return new getRoutes_resultStandardScheme();
}
}
private static class getRoutes_resultStandardScheme extends StandardScheme<getRoutes_result> {
- @Override
- public void read(org.apache.thrift.protocol.TProtocol iprot, getRoutes_result struct) throws org.apache.thrift.TException {
+ public void read(org.apache.thrift.protocol.TProtocol iprot, getRoutes_result struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
iprot.readStructBegin();
while (true)
struct.validate();
}
- @Override
- public void write(org.apache.thrift.protocol.TProtocol oprot, getRoutes_result struct) throws org.apache.thrift.TException {
+ public void write(org.apache.thrift.protocol.TProtocol oprot, getRoutes_result struct) throws org.apache.thrift.TException {
struct.validate();
oprot.writeStructBegin(STRUCT_DESC);
}
private static class getRoutes_resultTupleSchemeFactory implements SchemeFactory {
- @Override
- public getRoutes_resultTupleScheme getScheme() {
+ public getRoutes_resultTupleScheme getScheme() {
return new getRoutes_resultTupleScheme();
}
}
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) {
- throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
- }
+ if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
return fields;
}
_fieldName = fieldName;
}
- @Override
- public short getThriftFieldId() {
+ public short getThriftFieldId() {
return _thriftId;
}
- @Override
- public String getFieldName() {
+ public String getFieldName() {
return _fieldName;
}
}
}
}
- @Override
- public enableMultipath_args deepCopy() {
+ public enableMultipath_args deepCopy() {
return new enableMultipath_args(this);
}
}
}
- @Override
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, Object value) {
switch (field) {
case AFI:
if (value == null) {
}
}
- @Override
- public Object getFieldValue(_Fields field) {
+ public Object getFieldValue(_Fields field) {
switch (field) {
case AFI:
return getAfi();
}
/** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
- @Override
- public boolean isSet(_Fields field) {
+ public boolean isSet(_Fields field) {
if (field == null) {
throw new IllegalArgumentException();
}
@Override
public boolean equals(Object that) {
- if (that == null) {
- return false;
- }
- if (that instanceof enableMultipath_args) {
- return this.equals((enableMultipath_args)that);
- }
+ if (that == null)
+ return false;
+ if (that instanceof enableMultipath_args)
+ return this.equals((enableMultipath_args)that);
return false;
}
public boolean equals(enableMultipath_args that) {
- if (that == null) {
- return false;
- }
+ if (that == null)
+ return false;
boolean this_present_afi = true && this.isSetAfi();
boolean that_present_afi = true && that.isSetAfi();
if (this_present_afi || that_present_afi) {
- if (!(this_present_afi && that_present_afi)) {
- return false;
- }
- if (!this.afi.equals(that.afi)) {
- return false;
- }
+ if (!(this_present_afi && that_present_afi))
+ return false;
+ if (!this.afi.equals(that.afi))
+ return false;
}
boolean this_present_safi = true && this.isSetSafi();
boolean that_present_safi = true && that.isSetSafi();
if (this_present_safi || that_present_safi) {
- if (!(this_present_safi && that_present_safi)) {
- return false;
- }
- if (!this.safi.equals(that.safi)) {
- return false;
- }
+ if (!(this_present_safi && that_present_safi))
+ return false;
+ if (!this.safi.equals(that.safi))
+ return false;
}
return true;
list.add(present_afi);
if (present_afi)
list.add(afi.getValue());
+
boolean present_safi = true && (isSetSafi());
list.add(present_safi);
if (present_safi)
list.add(safi.getValue());
+
return list.hashCode();
}
return 0;
}
- @Override
- public _Fields fieldForId(int fieldId) {
+ public _Fields fieldForId(int fieldId) {
return _Fields.findByThriftId(fieldId);
}
- @Override
- public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
+ public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
}
- @Override
- public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
+ public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
schemes.get(oprot.getScheme()).getScheme().write(oprot, this);
}
sb.append(this.afi);
}
first = false;
- if (!first) {
- sb.append(", ");
- }
+ if (!first) sb.append(", ");
sb.append("safi:");
if (this.safi == null) {
sb.append("null");
}
private static class enableMultipath_argsStandardSchemeFactory implements SchemeFactory {
- @Override
- public enableMultipath_argsStandardScheme getScheme() {
+ public enableMultipath_argsStandardScheme getScheme() {
return new enableMultipath_argsStandardScheme();
}
}
private static class enableMultipath_argsStandardScheme extends StandardScheme<enableMultipath_args> {
- @Override
- public void read(org.apache.thrift.protocol.TProtocol iprot, enableMultipath_args struct) throws org.apache.thrift.TException {
+ public void read(org.apache.thrift.protocol.TProtocol iprot, enableMultipath_args struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
iprot.readStructBegin();
while (true)
struct.validate();
}
- @Override
- public void write(org.apache.thrift.protocol.TProtocol oprot, enableMultipath_args struct) throws org.apache.thrift.TException {
+ public void write(org.apache.thrift.protocol.TProtocol oprot, enableMultipath_args struct) throws org.apache.thrift.TException {
struct.validate();
oprot.writeStructBegin(STRUCT_DESC);
}
private static class enableMultipath_argsTupleSchemeFactory implements SchemeFactory {
- @Override
- public enableMultipath_argsTupleScheme getScheme() {
+ public enableMultipath_argsTupleScheme getScheme() {
return new enableMultipath_argsTupleScheme();
}
}
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) {
- throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
- }
+ if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
return fields;
}
_fieldName = fieldName;
}
- @Override
- public short getThriftFieldId() {
+ public short getThriftFieldId() {
return _thriftId;
}
- @Override
- public String getFieldName() {
+ public String getFieldName() {
return _fieldName;
}
}
this.success = other.success;
}
- @Override
- public enableMultipath_result deepCopy() {
+ public enableMultipath_result deepCopy() {
return new enableMultipath_result(this);
}
__isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __SUCCESS_ISSET_ID, value);
}
- @Override
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, Object value) {
switch (field) {
case SUCCESS:
if (value == null) {
}
}
- @Override
- public Object getFieldValue(_Fields field) {
+ public Object getFieldValue(_Fields field) {
switch (field) {
case SUCCESS:
- return Integer.valueOf(getSuccess());
+ return getSuccess();
}
throw new IllegalStateException();
}
/** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
- @Override
- public boolean isSet(_Fields field) {
+ public boolean isSet(_Fields field) {
if (field == null) {
throw new IllegalArgumentException();
}
@Override
public boolean equals(Object that) {
- if (that == null) {
- return false;
- }
- if (that instanceof enableMultipath_result) {
- return this.equals((enableMultipath_result)that);
- }
+ if (that == null)
+ return false;
+ if (that instanceof enableMultipath_result)
+ return this.equals((enableMultipath_result)that);
return false;
}
public boolean equals(enableMultipath_result that) {
- if (that == null) {
- return false;
- }
+ if (that == null)
+ return false;
boolean this_present_success = true;
boolean that_present_success = true;
if (this_present_success || that_present_success) {
- if (!(this_present_success && that_present_success)) {
- return false;
- }
- if (this.success != that.success) {
- return false;
- }
+ if (!(this_present_success && that_present_success))
+ return false;
+ if (this.success != that.success)
+ return false;
}
return true;
list.add(present_success);
if (present_success)
list.add(success);
+
return list.hashCode();
}
return 0;
}
- @Override
- public _Fields fieldForId(int fieldId) {
+ public _Fields fieldForId(int fieldId) {
return _Fields.findByThriftId(fieldId);
}
- @Override
- public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
+ public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
}
- @Override
- public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
+ public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
schemes.get(oprot.getScheme()).getScheme().write(oprot, this);
}
}
private static class enableMultipath_resultStandardSchemeFactory implements SchemeFactory {
- @Override
- public enableMultipath_resultStandardScheme getScheme() {
+ public enableMultipath_resultStandardScheme getScheme() {
return new enableMultipath_resultStandardScheme();
}
}
private static class enableMultipath_resultStandardScheme extends StandardScheme<enableMultipath_result> {
- @Override
- public void read(org.apache.thrift.protocol.TProtocol iprot, enableMultipath_result struct) throws org.apache.thrift.TException {
+ public void read(org.apache.thrift.protocol.TProtocol iprot, enableMultipath_result struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
iprot.readStructBegin();
while (true)
struct.validate();
}
- @Override
- public void write(org.apache.thrift.protocol.TProtocol oprot, enableMultipath_result struct) throws org.apache.thrift.TException {
+ public void write(org.apache.thrift.protocol.TProtocol oprot, enableMultipath_result struct) throws org.apache.thrift.TException {
struct.validate();
oprot.writeStructBegin(STRUCT_DESC);
}
private static class enableMultipath_resultTupleSchemeFactory implements SchemeFactory {
- @Override
- public enableMultipath_resultTupleScheme getScheme() {
+ public enableMultipath_resultTupleScheme getScheme() {
return new enableMultipath_resultTupleScheme();
}
}
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) {
- throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
- }
+ if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
return fields;
}
_fieldName = fieldName;
}
- @Override
- public short getThriftFieldId() {
+ public short getThriftFieldId() {
return _thriftId;
}
- @Override
- public String getFieldName() {
+ public String getFieldName() {
return _fieldName;
}
}
}
}
- @Override
- public disableMultipath_args deepCopy() {
+ public disableMultipath_args deepCopy() {
return new disableMultipath_args(this);
}
}
}
- @Override
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, Object value) {
switch (field) {
case AFI:
if (value == null) {
}
}
- @Override
- public Object getFieldValue(_Fields field) {
+ public Object getFieldValue(_Fields field) {
switch (field) {
case AFI:
return getAfi();
}
/** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
- @Override
- public boolean isSet(_Fields field) {
+ public boolean isSet(_Fields field) {
if (field == null) {
throw new IllegalArgumentException();
}
@Override
public boolean equals(Object that) {
- if (that == null) {
- return false;
- }
- if (that instanceof disableMultipath_args) {
- return this.equals((disableMultipath_args)that);
- }
+ if (that == null)
+ return false;
+ if (that instanceof disableMultipath_args)
+ return this.equals((disableMultipath_args)that);
return false;
}
public boolean equals(disableMultipath_args that) {
- if (that == null) {
- return false;
- }
+ if (that == null)
+ return false;
boolean this_present_afi = true && this.isSetAfi();
boolean that_present_afi = true && that.isSetAfi();
if (this_present_afi || that_present_afi) {
- if (!(this_present_afi && that_present_afi)) {
- return false;
- }
- if (!this.afi.equals(that.afi)) {
- return false;
- }
+ if (!(this_present_afi && that_present_afi))
+ return false;
+ if (!this.afi.equals(that.afi))
+ return false;
}
boolean this_present_safi = true && this.isSetSafi();
boolean that_present_safi = true && that.isSetSafi();
if (this_present_safi || that_present_safi) {
- if (!(this_present_safi && that_present_safi)) {
- return false;
- }
- if (!this.safi.equals(that.safi)) {
- return false;
- }
+ if (!(this_present_safi && that_present_safi))
+ return false;
+ if (!this.safi.equals(that.safi))
+ return false;
}
return true;
list.add(present_afi);
if (present_afi)
list.add(afi.getValue());
+
boolean present_safi = true && (isSetSafi());
list.add(present_safi);
if (present_safi)
list.add(safi.getValue());
+
return list.hashCode();
}
return 0;
}
- @Override
- public _Fields fieldForId(int fieldId) {
+ public _Fields fieldForId(int fieldId) {
return _Fields.findByThriftId(fieldId);
}
- @Override
- public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
+ public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
}
- @Override
- public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
+ public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
schemes.get(oprot.getScheme()).getScheme().write(oprot, this);
}
sb.append(this.afi);
}
first = false;
- if (!first) {
- sb.append(", ");
- }
+ if (!first) sb.append(", ");
sb.append("safi:");
if (this.safi == null) {
sb.append("null");
}
private static class disableMultipath_argsStandardSchemeFactory implements SchemeFactory {
- @Override
- public disableMultipath_argsStandardScheme getScheme() {
+ public disableMultipath_argsStandardScheme getScheme() {
return new disableMultipath_argsStandardScheme();
}
}
private static class disableMultipath_argsStandardScheme extends StandardScheme<disableMultipath_args> {
- @Override
- public void read(org.apache.thrift.protocol.TProtocol iprot, disableMultipath_args struct) throws org.apache.thrift.TException {
+ public void read(org.apache.thrift.protocol.TProtocol iprot, disableMultipath_args struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
iprot.readStructBegin();
while (true)
struct.validate();
}
- @Override
- public void write(org.apache.thrift.protocol.TProtocol oprot, disableMultipath_args struct) throws org.apache.thrift.TException {
+ public void write(org.apache.thrift.protocol.TProtocol oprot, disableMultipath_args struct) throws org.apache.thrift.TException {
struct.validate();
oprot.writeStructBegin(STRUCT_DESC);
}
private static class disableMultipath_argsTupleSchemeFactory implements SchemeFactory {
- @Override
- public disableMultipath_argsTupleScheme getScheme() {
+ public disableMultipath_argsTupleScheme getScheme() {
return new disableMultipath_argsTupleScheme();
}
}
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) {
- throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
- }
+ if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
return fields;
}
_fieldName = fieldName;
}
- @Override
- public short getThriftFieldId() {
+ public short getThriftFieldId() {
return _thriftId;
}
- @Override
- public String getFieldName() {
+ public String getFieldName() {
return _fieldName;
}
}
this.success = other.success;
}
- @Override
- public disableMultipath_result deepCopy() {
+ public disableMultipath_result deepCopy() {
return new disableMultipath_result(this);
}
__isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __SUCCESS_ISSET_ID, value);
}
- @Override
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, Object value) {
switch (field) {
case SUCCESS:
if (value == null) {
}
}
- @Override
- public Object getFieldValue(_Fields field) {
+ public Object getFieldValue(_Fields field) {
switch (field) {
case SUCCESS:
- return Integer.valueOf(getSuccess());
+ return getSuccess();
}
throw new IllegalStateException();
}
/** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
- @Override
- public boolean isSet(_Fields field) {
+ public boolean isSet(_Fields field) {
if (field == null) {
throw new IllegalArgumentException();
}
@Override
public boolean equals(Object that) {
- if (that == null) {
- return false;
- }
- if (that instanceof disableMultipath_result) {
- return this.equals((disableMultipath_result)that);
- }
+ if (that == null)
+ return false;
+ if (that instanceof disableMultipath_result)
+ return this.equals((disableMultipath_result)that);
return false;
}
public boolean equals(disableMultipath_result that) {
- if (that == null) {
- return false;
- }
+ if (that == null)
+ return false;
boolean this_present_success = true;
boolean that_present_success = true;
if (this_present_success || that_present_success) {
- if (!(this_present_success && that_present_success)) {
- return false;
- }
- if (this.success != that.success) {
- return false;
- }
+ if (!(this_present_success && that_present_success))
+ return false;
+ if (this.success != that.success)
+ return false;
}
return true;
list.add(present_success);
if (present_success)
list.add(success);
+
return list.hashCode();
}
return 0;
}
- @Override
- public _Fields fieldForId(int fieldId) {
+ public _Fields fieldForId(int fieldId) {
return _Fields.findByThriftId(fieldId);
}
- @Override
- public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
+ public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
}
- @Override
- public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
+ public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
schemes.get(oprot.getScheme()).getScheme().write(oprot, this);
}
}
private static class disableMultipath_resultStandardSchemeFactory implements SchemeFactory {
- @Override
- public disableMultipath_resultStandardScheme getScheme() {
+ public disableMultipath_resultStandardScheme getScheme() {
return new disableMultipath_resultStandardScheme();
}
}
private static class disableMultipath_resultStandardScheme extends StandardScheme<disableMultipath_result> {
- @Override
- public void read(org.apache.thrift.protocol.TProtocol iprot, disableMultipath_result struct) throws org.apache.thrift.TException {
+ public void read(org.apache.thrift.protocol.TProtocol iprot, disableMultipath_result struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
iprot.readStructBegin();
while (true)
struct.validate();
}
- @Override
- public void write(org.apache.thrift.protocol.TProtocol oprot, disableMultipath_result struct) throws org.apache.thrift.TException {
+ public void write(org.apache.thrift.protocol.TProtocol oprot, disableMultipath_result struct) throws org.apache.thrift.TException {
struct.validate();
oprot.writeStructBegin(STRUCT_DESC);
}
private static class disableMultipath_resultTupleSchemeFactory implements SchemeFactory {
- @Override
- public disableMultipath_resultTupleScheme getScheme() {
+ public disableMultipath_resultTupleScheme getScheme() {
return new disableMultipath_resultTupleScheme();
}
}
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) {
- throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
- }
+ if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
return fields;
}
_fieldName = fieldName;
}
- @Override
- public short getThriftFieldId() {
+ public short getThriftFieldId() {
return _thriftId;
}
- @Override
- public String getFieldName() {
+ public String getFieldName() {
return _fieldName;
}
}
this.maxPath = other.maxPath;
}
- @Override
- public multipaths_args deepCopy() {
+ public multipaths_args deepCopy() {
return new multipaths_args(this);
}
__isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __MAXPATH_ISSET_ID, value);
}
- @Override
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, Object value) {
switch (field) {
case RD:
if (value == null) {
}
}
- @Override
- public Object getFieldValue(_Fields field) {
+ public Object getFieldValue(_Fields field) {
switch (field) {
case RD:
return getRd();
case MAX_PATH:
- return Integer.valueOf(getMaxPath());
+ return getMaxPath();
}
throw new IllegalStateException();
}
/** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
- @Override
- public boolean isSet(_Fields field) {
+ public boolean isSet(_Fields field) {
if (field == null) {
throw new IllegalArgumentException();
}
@Override
public boolean equals(Object that) {
- if (that == null) {
- return false;
- }
- if (that instanceof multipaths_args) {
- return this.equals((multipaths_args)that);
- }
+ if (that == null)
+ return false;
+ if (that instanceof multipaths_args)
+ return this.equals((multipaths_args)that);
return false;
}
public boolean equals(multipaths_args that) {
- if (that == null) {
- return false;
- }
+ if (that == null)
+ return false;
boolean this_present_rd = true && this.isSetRd();
boolean that_present_rd = true && that.isSetRd();
if (this_present_rd || that_present_rd) {
- if (!(this_present_rd && that_present_rd)) {
- return false;
- }
- if (!this.rd.equals(that.rd)) {
- return false;
- }
+ if (!(this_present_rd && that_present_rd))
+ return false;
+ if (!this.rd.equals(that.rd))
+ return false;
}
boolean this_present_maxPath = true;
boolean that_present_maxPath = true;
if (this_present_maxPath || that_present_maxPath) {
- if (!(this_present_maxPath && that_present_maxPath)) {
- return false;
- }
- if (this.maxPath != that.maxPath) {
- return false;
- }
+ if (!(this_present_maxPath && that_present_maxPath))
+ return false;
+ if (this.maxPath != that.maxPath)
+ return false;
}
return true;
@Override
public int hashCode() {
List<Object> list = new ArrayList<Object>();
+
boolean present_rd = true && (isSetRd());
list.add(present_rd);
if (present_rd)
list.add(rd);
+
boolean present_maxPath = true;
list.add(present_maxPath);
if (present_maxPath)
list.add(maxPath);
+
return list.hashCode();
}
return 0;
}
- @Override
- public _Fields fieldForId(int fieldId) {
+ public _Fields fieldForId(int fieldId) {
return _Fields.findByThriftId(fieldId);
}
- @Override
- public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
+ public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
}
- @Override
- public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
+ public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
schemes.get(oprot.getScheme()).getScheme().write(oprot, this);
}
sb.append(this.rd);
}
first = false;
- if (!first) {
- sb.append(", ");
- }
+ if (!first) sb.append(", ");
sb.append("maxPath:");
sb.append(this.maxPath);
first = false;
}
private static class multipaths_argsStandardSchemeFactory implements SchemeFactory {
- @Override
- public multipaths_argsStandardScheme getScheme() {
+ public multipaths_argsStandardScheme getScheme() {
return new multipaths_argsStandardScheme();
}
}
private static class multipaths_argsStandardScheme extends StandardScheme<multipaths_args> {
- @Override
- public void read(org.apache.thrift.protocol.TProtocol iprot, multipaths_args struct) throws org.apache.thrift.TException {
+ public void read(org.apache.thrift.protocol.TProtocol iprot, multipaths_args struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
iprot.readStructBegin();
while (true)
struct.validate();
}
- @Override
- public void write(org.apache.thrift.protocol.TProtocol oprot, multipaths_args struct) throws org.apache.thrift.TException {
+ public void write(org.apache.thrift.protocol.TProtocol oprot, multipaths_args struct) throws org.apache.thrift.TException {
struct.validate();
oprot.writeStructBegin(STRUCT_DESC);
}
private static class multipaths_argsTupleSchemeFactory implements SchemeFactory {
- @Override
- public multipaths_argsTupleScheme getScheme() {
+ public multipaths_argsTupleScheme getScheme() {
return new multipaths_argsTupleScheme();
}
}
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) {
- throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
- }
+ if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
return fields;
}
_fieldName = fieldName;
}
- @Override
- public short getThriftFieldId() {
+ public short getThriftFieldId() {
return _thriftId;
}
- @Override
- public String getFieldName() {
+ public String getFieldName() {
return _fieldName;
}
}
this.success = other.success;
}
- @Override
- public multipaths_result deepCopy() {
+ public multipaths_result deepCopy() {
return new multipaths_result(this);
}
__isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __SUCCESS_ISSET_ID, value);
}
- @Override
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, Object value) {
switch (field) {
case SUCCESS:
if (value == null) {
}
}
- @Override
- public Object getFieldValue(_Fields field) {
+ public Object getFieldValue(_Fields field) {
switch (field) {
case SUCCESS:
- return Integer.valueOf(getSuccess());
+ return getSuccess();
}
throw new IllegalStateException();
}
/** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
- @Override
- public boolean isSet(_Fields field) {
+ public boolean isSet(_Fields field) {
if (field == null) {
throw new IllegalArgumentException();
}
@Override
public boolean equals(Object that) {
- if (that == null) {
- return false;
- }
- if (that instanceof multipaths_result) {
- return this.equals((multipaths_result)that);
- }
+ if (that == null)
+ return false;
+ if (that instanceof multipaths_result)
+ return this.equals((multipaths_result)that);
return false;
}
public boolean equals(multipaths_result that) {
- if (that == null) {
- return false;
- }
+ if (that == null)
+ return false;
boolean this_present_success = true;
boolean that_present_success = true;
if (this_present_success || that_present_success) {
- if (!(this_present_success && that_present_success)) {
- return false;
- }
- if (this.success != that.success) {
- return false;
- }
+ if (!(this_present_success && that_present_success))
+ return false;
+ if (this.success != that.success)
+ return false;
}
return true;
list.add(present_success);
if (present_success)
list.add(success);
+
return list.hashCode();
}
return 0;
}
- @Override
- public _Fields fieldForId(int fieldId) {
+ public _Fields fieldForId(int fieldId) {
return _Fields.findByThriftId(fieldId);
}
- @Override
- public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
+ public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
}
- @Override
- public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
+ public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
schemes.get(oprot.getScheme()).getScheme().write(oprot, this);
}
}
private static class multipaths_resultStandardSchemeFactory implements SchemeFactory {
- @Override
- public multipaths_resultStandardScheme getScheme() {
+ public multipaths_resultStandardScheme getScheme() {
return new multipaths_resultStandardScheme();
}
}
private static class multipaths_resultStandardScheme extends StandardScheme<multipaths_result> {
- @Override
- public void read(org.apache.thrift.protocol.TProtocol iprot, multipaths_result struct) throws org.apache.thrift.TException {
+ public void read(org.apache.thrift.protocol.TProtocol iprot, multipaths_result struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
iprot.readStructBegin();
while (true)
struct.validate();
}
- @Override
- public void write(org.apache.thrift.protocol.TProtocol oprot, multipaths_result struct) throws org.apache.thrift.TException {
+ public void write(org.apache.thrift.protocol.TProtocol oprot, multipaths_result struct) throws org.apache.thrift.TException {
struct.validate();
oprot.writeStructBegin(STRUCT_DESC);
}
private static class multipaths_resultTupleSchemeFactory implements SchemeFactory {
- @Override
- public multipaths_resultTupleScheme getScheme() {
+ public multipaths_resultTupleScheme getScheme() {
return new multipaths_resultTupleScheme();
}
}
private static final org.apache.thrift.protocol.TField DELAY_FIELD_DESC = new org.apache.thrift.protocol.TField("delay", org.apache.thrift.protocol.TType.I32, (short)1);
- private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<>();
+ private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
static {
schemes.put(StandardScheme.class, new enableEORDelay_argsStandardSchemeFactory());
schemes.put(TupleScheme.class, new enableEORDelay_argsTupleSchemeFactory());
public Object getFieldValue(_Fields field) {
switch (field) {
case DELAY:
- return Integer.valueOf(getDelay());
+ return getDelay();
}
throw new IllegalStateException();
list.add(present_delay);
if (present_delay)
list.add(delay);
+
return list.hashCode();
}
private static final org.apache.thrift.protocol.TField SUCCESS_FIELD_DESC = new org.apache.thrift.protocol.TField("success", org.apache.thrift.protocol.TType.I32, (short)0);
- private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<>();
+ private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
static {
schemes.put(StandardScheme.class, new enableEORDelay_resultStandardSchemeFactory());
schemes.put(TupleScheme.class, new enableEORDelay_resultTupleSchemeFactory());
public Object getFieldValue(_Fields field) {
switch (field) {
case SUCCESS:
- return Integer.valueOf(getSuccess());
+ return getSuccess();
}
throw new IllegalStateException();
list.add(present_success);
if (present_success)
list.add(success);
+
return list.hashCode();
}
public static class sendEOR_args implements org.apache.thrift.TBase<sendEOR_args, sendEOR_args._Fields>, java.io.Serializable, Cloneable, Comparable<sendEOR_args> {
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("sendEOR_args");
- private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<>();
+
+ private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
static {
schemes.put(StandardScheme.class, new sendEOR_argsStandardSchemeFactory());
schemes.put(TupleScheme.class, new sendEOR_argsTupleSchemeFactory());
private static final org.apache.thrift.protocol.TField SUCCESS_FIELD_DESC = new org.apache.thrift.protocol.TField("success", org.apache.thrift.protocol.TType.I32, (short)0);
- private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<>();
+ private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
static {
schemes.put(StandardScheme.class, new sendEOR_resultStandardSchemeFactory());
schemes.put(TupleScheme.class, new sendEOR_resultTupleSchemeFactory());
public Object getFieldValue(_Fields field) {
switch (field) {
case SUCCESS:
- return Integer.valueOf(getSuccess());
+ return getSuccess();
}
throw new IllegalStateException();
list.add(present_success);
if (present_success)
list.add(success);
+
return list.hashCode();
}
}
+ public static class enableBFDFailover_args implements org.apache.thrift.TBase<enableBFDFailover_args, enableBFDFailover_args._Fields>, java.io.Serializable, Cloneable, Comparable<enableBFDFailover_args> {
+ private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("enableBFDFailover_args");
+
+ private static final org.apache.thrift.protocol.TField BFD_CONFIG_FIELD_DESC = new org.apache.thrift.protocol.TField("bfdConfig", org.apache.thrift.protocol.TType.STRUCT, (short)1);
+
+ private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
+ static {
+ schemes.put(StandardScheme.class, new enableBFDFailover_argsStandardSchemeFactory());
+ schemes.put(TupleScheme.class, new enableBFDFailover_argsTupleSchemeFactory());
+ }
+
+ public BfdConfigData bfdConfig; // required
+
+ /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
+ public enum _Fields implements org.apache.thrift.TFieldIdEnum {
+ BFD_CONFIG((short)1, "bfdConfig");
+
+ private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+
+ static {
+ for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ byName.put(field.getFieldName(), field);
+ }
+ }
+
+ /**
+ * Find the _Fields constant that matches fieldId, or null if its not found.
+ */
+ public static _Fields findByThriftId(int fieldId) {
+ switch(fieldId) {
+ case 1: // BFD_CONFIG
+ return BFD_CONFIG;
+ default:
+ return null;
+ }
+ }
+
+ /**
+ * Find the _Fields constant that matches fieldId, throwing an exception
+ * if it is not found.
+ */
+ public static _Fields findByThriftIdOrThrow(int fieldId) {
+ _Fields fields = findByThriftId(fieldId);
+ if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ return fields;
+ }
+
+ /**
+ * Find the _Fields constant that matches name, or null if its not found.
+ */
+ public static _Fields findByName(String name) {
+ return byName.get(name);
+ }
+
+ private final short _thriftId;
+ private final String _fieldName;
+
+ _Fields(short thriftId, String fieldName) {
+ _thriftId = thriftId;
+ _fieldName = fieldName;
+ }
+
+ public short getThriftFieldId() {
+ return _thriftId;
+ }
+
+ public String getFieldName() {
+ return _fieldName;
+ }
+ }
+
+ // isset id assignments
+ public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ static {
+ Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
+ tmpMap.put(_Fields.BFD_CONFIG, new org.apache.thrift.meta_data.FieldMetaData("bfdConfig", org.apache.thrift.TFieldRequirementType.DEFAULT,
+ new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, BfdConfigData.class)));
+ metaDataMap = Collections.unmodifiableMap(tmpMap);
+ org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(enableBFDFailover_args.class, metaDataMap);
+ }
+
+ public enableBFDFailover_args() {
+ }
+
+ public enableBFDFailover_args(
+ BfdConfigData bfdConfig)
+ {
+ this();
+ this.bfdConfig = bfdConfig;
+ }
+
+ /**
+ * Performs a deep copy on <i>other</i>.
+ */
+ public enableBFDFailover_args(enableBFDFailover_args other) {
+ if (other.isSetBfdConfig()) {
+ this.bfdConfig = new BfdConfigData(other.bfdConfig);
+ }
+ }
+
+ public enableBFDFailover_args deepCopy() {
+ return new enableBFDFailover_args(this);
+ }
+
+ @Override
+ public void clear() {
+ this.bfdConfig = null;
+ }
+
+ public BfdConfigData getBfdConfig() {
+ return this.bfdConfig;
+ }
+
+ public enableBFDFailover_args setBfdConfig(BfdConfigData bfdConfig) {
+ this.bfdConfig = bfdConfig;
+ return this;
+ }
+
+ public void unsetBfdConfig() {
+ this.bfdConfig = null;
+ }
+
+ /** Returns true if field bfdConfig is set (has been assigned a value) and false otherwise */
+ public boolean isSetBfdConfig() {
+ return this.bfdConfig != null;
+ }
+
+ public void setBfdConfigIsSet(boolean value) {
+ if (!value) {
+ this.bfdConfig = null;
+ }
+ }
+
+ public void setFieldValue(_Fields field, Object value) {
+ switch (field) {
+ case BFD_CONFIG:
+ if (value == null) {
+ unsetBfdConfig();
+ } else {
+ setBfdConfig((BfdConfigData)value);
+ }
+ break;
+
+ }
+ }
+
+ public Object getFieldValue(_Fields field) {
+ switch (field) {
+ case BFD_CONFIG:
+ return getBfdConfig();
+
+ }
+ throw new IllegalStateException();
+ }
+
+ /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
+ public boolean isSet(_Fields field) {
+ if (field == null) {
+ throw new IllegalArgumentException();
+ }
+
+ switch (field) {
+ case BFD_CONFIG:
+ return isSetBfdConfig();
+ }
+ throw new IllegalStateException();
+ }
+
+ @Override
+ public boolean equals(Object that) {
+ if (that == null)
+ return false;
+ if (that instanceof enableBFDFailover_args)
+ return this.equals((enableBFDFailover_args)that);
+ return false;
+ }
+
+ public boolean equals(enableBFDFailover_args that) {
+ if (that == null)
+ return false;
+
+ boolean this_present_bfdConfig = true && this.isSetBfdConfig();
+ boolean that_present_bfdConfig = true && that.isSetBfdConfig();
+ if (this_present_bfdConfig || that_present_bfdConfig) {
+ if (!(this_present_bfdConfig && that_present_bfdConfig))
+ return false;
+ if (!this.bfdConfig.equals(that.bfdConfig))
+ return false;
+ }
+
+ return true;
+ }
+
+ @Override
+ public int hashCode() {
+ List<Object> list = new ArrayList<Object>();
+
+ boolean present_bfdConfig = true && (isSetBfdConfig());
+ list.add(present_bfdConfig);
+ if (present_bfdConfig)
+ list.add(bfdConfig);
+
+ return list.hashCode();
+ }
+
+ @Override
+ public int compareTo(enableBFDFailover_args other) {
+ if (!getClass().equals(other.getClass())) {
+ return getClass().getName().compareTo(other.getClass().getName());
+ }
+
+ int lastComparison = 0;
+
+ lastComparison = Boolean.valueOf(isSetBfdConfig()).compareTo(other.isSetBfdConfig());
+ if (lastComparison != 0) {
+ return lastComparison;
+ }
+ if (isSetBfdConfig()) {
+ lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.bfdConfig, other.bfdConfig);
+ if (lastComparison != 0) {
+ return lastComparison;
+ }
+ }
+ return 0;
+ }
+
+ public _Fields fieldForId(int fieldId) {
+ return _Fields.findByThriftId(fieldId);
+ }
+
+ public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
+ schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ }
+
+ public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
+ schemes.get(oprot.getScheme()).getScheme().write(oprot, this);
+ }
+
+ @Override
+ public String toString() {
+ StringBuilder sb = new StringBuilder("enableBFDFailover_args(");
+ boolean first = true;
+
+ sb.append("bfdConfig:");
+ if (this.bfdConfig == null) {
+ sb.append("null");
+ } else {
+ sb.append(this.bfdConfig);
+ }
+ first = false;
+ sb.append(")");
+ return sb.toString();
+ }
+
+ public void validate() throws org.apache.thrift.TException {
+ // check for required fields
+ // check for sub-struct validity
+ if (bfdConfig != null) {
+ bfdConfig.validate();
+ }
+ }
+
+ private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
+ try {
+ write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
+ } catch (org.apache.thrift.TException te) {
+ throw new java.io.IOException(te);
+ }
+ }
+
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
+ try {
+ read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
+ } catch (org.apache.thrift.TException te) {
+ throw new java.io.IOException(te);
+ }
+ }
+
+ private static class enableBFDFailover_argsStandardSchemeFactory implements SchemeFactory {
+ public enableBFDFailover_argsStandardScheme getScheme() {
+ return new enableBFDFailover_argsStandardScheme();
+ }
+ }
+
+ private static class enableBFDFailover_argsStandardScheme extends StandardScheme<enableBFDFailover_args> {
+
+ public void read(org.apache.thrift.protocol.TProtocol iprot, enableBFDFailover_args struct) throws org.apache.thrift.TException {
+ org.apache.thrift.protocol.TField schemeField;
+ iprot.readStructBegin();
+ while (true)
+ {
+ schemeField = iprot.readFieldBegin();
+ if (schemeField.type == org.apache.thrift.protocol.TType.STOP) {
+ break;
+ }
+ switch (schemeField.id) {
+ case 1: // BFD_CONFIG
+ if (schemeField.type == org.apache.thrift.protocol.TType.STRUCT) {
+ struct.bfdConfig = new BfdConfigData();
+ struct.bfdConfig.read(iprot);
+ struct.setBfdConfigIsSet(true);
+ } else {
+ org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
+ }
+ break;
+ default:
+ org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
+ }
+ iprot.readFieldEnd();
+ }
+ iprot.readStructEnd();
+
+ // check for required fields of primitive type, which can't be checked in the validate method
+ struct.validate();
+ }
+
+ public void write(org.apache.thrift.protocol.TProtocol oprot, enableBFDFailover_args struct) throws org.apache.thrift.TException {
+ struct.validate();
+
+ oprot.writeStructBegin(STRUCT_DESC);
+ if (struct.bfdConfig != null) {
+ oprot.writeFieldBegin(BFD_CONFIG_FIELD_DESC);
+ struct.bfdConfig.write(oprot);
+ oprot.writeFieldEnd();
+ }
+ oprot.writeFieldStop();
+ oprot.writeStructEnd();
+ }
+
+ }
+
+ private static class enableBFDFailover_argsTupleSchemeFactory implements SchemeFactory {
+ public enableBFDFailover_argsTupleScheme getScheme() {
+ return new enableBFDFailover_argsTupleScheme();
+ }
+ }
+
+ private static class enableBFDFailover_argsTupleScheme extends TupleScheme<enableBFDFailover_args> {
+
+ @Override
+ public void write(org.apache.thrift.protocol.TProtocol prot, enableBFDFailover_args struct) throws org.apache.thrift.TException {
+ TTupleProtocol oprot = (TTupleProtocol) prot;
+ BitSet optionals = new BitSet();
+ if (struct.isSetBfdConfig()) {
+ optionals.set(0);
+ }
+ oprot.writeBitSet(optionals, 1);
+ if (struct.isSetBfdConfig()) {
+ struct.bfdConfig.write(oprot);
+ }
+ }
+
+ @Override
+ public void read(org.apache.thrift.protocol.TProtocol prot, enableBFDFailover_args struct) throws org.apache.thrift.TException {
+ TTupleProtocol iprot = (TTupleProtocol) prot;
+ BitSet incoming = iprot.readBitSet(1);
+ if (incoming.get(0)) {
+ struct.bfdConfig = new BfdConfigData();
+ struct.bfdConfig.read(iprot);
+ struct.setBfdConfigIsSet(true);
+ }
+ }
+ }
+
+ }
+
+ public static class enableBFDFailover_result implements org.apache.thrift.TBase<enableBFDFailover_result, enableBFDFailover_result._Fields>, java.io.Serializable, Cloneable, Comparable<enableBFDFailover_result> {
+ private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("enableBFDFailover_result");
+
+ private static final org.apache.thrift.protocol.TField SUCCESS_FIELD_DESC = new org.apache.thrift.protocol.TField("success", org.apache.thrift.protocol.TType.I32, (short)0);
+
+ private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
+ static {
+ schemes.put(StandardScheme.class, new enableBFDFailover_resultStandardSchemeFactory());
+ schemes.put(TupleScheme.class, new enableBFDFailover_resultTupleSchemeFactory());
+ }
+
+ public int success; // required
+
+ /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
+ public enum _Fields implements org.apache.thrift.TFieldIdEnum {
+ SUCCESS((short)0, "success");
+
+ private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+
+ static {
+ for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ byName.put(field.getFieldName(), field);
+ }
+ }
+
+ /**
+ * Find the _Fields constant that matches fieldId, or null if its not found.
+ */
+ public static _Fields findByThriftId(int fieldId) {
+ switch(fieldId) {
+ case 0: // SUCCESS
+ return SUCCESS;
+ default:
+ return null;
+ }
+ }
+
+ /**
+ * Find the _Fields constant that matches fieldId, throwing an exception
+ * if it is not found.
+ */
+ public static _Fields findByThriftIdOrThrow(int fieldId) {
+ _Fields fields = findByThriftId(fieldId);
+ if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ return fields;
+ }
+
+ /**
+ * Find the _Fields constant that matches name, or null if its not found.
+ */
+ public static _Fields findByName(String name) {
+ return byName.get(name);
+ }
+
+ private final short _thriftId;
+ private final String _fieldName;
+
+ _Fields(short thriftId, String fieldName) {
+ _thriftId = thriftId;
+ _fieldName = fieldName;
+ }
+
+ public short getThriftFieldId() {
+ return _thriftId;
+ }
+
+ public String getFieldName() {
+ return _fieldName;
+ }
+ }
+
+ // isset id assignments
+ private static final int __SUCCESS_ISSET_ID = 0;
+ private byte __isset_bitfield = 0;
+ public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ static {
+ Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
+ tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT,
+ new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I32)));
+ metaDataMap = Collections.unmodifiableMap(tmpMap);
+ org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(enableBFDFailover_result.class, metaDataMap);
+ }
+
+ public enableBFDFailover_result() {
+ }
+
+ public enableBFDFailover_result(
+ int success)
+ {
+ this();
+ this.success = success;
+ setSuccessIsSet(true);
+ }
+
+ /**
+ * Performs a deep copy on <i>other</i>.
+ */
+ public enableBFDFailover_result(enableBFDFailover_result other) {
+ __isset_bitfield = other.__isset_bitfield;
+ this.success = other.success;
+ }
+
+ public enableBFDFailover_result deepCopy() {
+ return new enableBFDFailover_result(this);
+ }
+
+ @Override
+ public void clear() {
+ setSuccessIsSet(false);
+ this.success = 0;
+ }
+
+ public int getSuccess() {
+ return this.success;
+ }
+
+ public enableBFDFailover_result setSuccess(int success) {
+ this.success = success;
+ setSuccessIsSet(true);
+ return this;
+ }
+
+ public void unsetSuccess() {
+ __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __SUCCESS_ISSET_ID);
+ }
+
+ /** Returns true if field success is set (has been assigned a value) and false otherwise */
+ public boolean isSetSuccess() {
+ return EncodingUtils.testBit(__isset_bitfield, __SUCCESS_ISSET_ID);
+ }
+
+ public void setSuccessIsSet(boolean value) {
+ __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __SUCCESS_ISSET_ID, value);
+ }
+
+ public void setFieldValue(_Fields field, Object value) {
+ switch (field) {
+ case SUCCESS:
+ if (value == null) {
+ unsetSuccess();
+ } else {
+ setSuccess((Integer)value);
+ }
+ break;
+
+ }
+ }
+
+ public Object getFieldValue(_Fields field) {
+ switch (field) {
+ case SUCCESS:
+ return getSuccess();
+
+ }
+ throw new IllegalStateException();
+ }
+
+ /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
+ public boolean isSet(_Fields field) {
+ if (field == null) {
+ throw new IllegalArgumentException();
+ }
+
+ switch (field) {
+ case SUCCESS:
+ return isSetSuccess();
+ }
+ throw new IllegalStateException();
+ }
+
+ @Override
+ public boolean equals(Object that) {
+ if (that == null)
+ return false;
+ if (that instanceof enableBFDFailover_result)
+ return this.equals((enableBFDFailover_result)that);
+ return false;
+ }
+
+ public boolean equals(enableBFDFailover_result that) {
+ if (that == null)
+ return false;
+
+ boolean this_present_success = true;
+ boolean that_present_success = true;
+ if (this_present_success || that_present_success) {
+ if (!(this_present_success && that_present_success))
+ return false;
+ if (this.success != that.success)
+ return false;
+ }
+
+ return true;
+ }
+
+ @Override
+ public int hashCode() {
+ List<Object> list = new ArrayList<Object>();
+
+ boolean present_success = true;
+ list.add(present_success);
+ if (present_success)
+ list.add(success);
+
+ return list.hashCode();
+ }
+
+ @Override
+ public int compareTo(enableBFDFailover_result other) {
+ if (!getClass().equals(other.getClass())) {
+ return getClass().getName().compareTo(other.getClass().getName());
+ }
+
+ int lastComparison = 0;
+
+ lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(other.isSetSuccess());
+ if (lastComparison != 0) {
+ return lastComparison;
+ }
+ if (isSetSuccess()) {
+ lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, other.success);
+ if (lastComparison != 0) {
+ return lastComparison;
+ }
+ }
+ return 0;
+ }
+
+ public _Fields fieldForId(int fieldId) {
+ return _Fields.findByThriftId(fieldId);
+ }
+
+ public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
+ schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ }
+
+ public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
+ schemes.get(oprot.getScheme()).getScheme().write(oprot, this);
+ }
+
+ @Override
+ public String toString() {
+ StringBuilder sb = new StringBuilder("enableBFDFailover_result(");
+ boolean first = true;
+
+ sb.append("success:");
+ sb.append(this.success);
+ first = false;
+ sb.append(")");
+ return sb.toString();
+ }
+
+ public void validate() throws org.apache.thrift.TException {
+ // check for required fields
+ // check for sub-struct validity
+ }
+
+ private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
+ try {
+ write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
+ } catch (org.apache.thrift.TException te) {
+ throw new java.io.IOException(te);
+ }
+ }
+
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
+ try {
+ // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
+ __isset_bitfield = 0;
+ read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
+ } catch (org.apache.thrift.TException te) {
+ throw new java.io.IOException(te);
+ }
+ }
+
+ private static class enableBFDFailover_resultStandardSchemeFactory implements SchemeFactory {
+ public enableBFDFailover_resultStandardScheme getScheme() {
+ return new enableBFDFailover_resultStandardScheme();
+ }
+ }
+
+ private static class enableBFDFailover_resultStandardScheme extends StandardScheme<enableBFDFailover_result> {
+
+ public void read(org.apache.thrift.protocol.TProtocol iprot, enableBFDFailover_result struct) throws org.apache.thrift.TException {
+ org.apache.thrift.protocol.TField schemeField;
+ iprot.readStructBegin();
+ while (true)
+ {
+ schemeField = iprot.readFieldBegin();
+ if (schemeField.type == org.apache.thrift.protocol.TType.STOP) {
+ break;
+ }
+ switch (schemeField.id) {
+ case 0: // SUCCESS
+ if (schemeField.type == org.apache.thrift.protocol.TType.I32) {
+ struct.success = iprot.readI32();
+ struct.setSuccessIsSet(true);
+ } else {
+ org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
+ }
+ break;
+ default:
+ org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
+ }
+ iprot.readFieldEnd();
+ }
+ iprot.readStructEnd();
+
+ // check for required fields of primitive type, which can't be checked in the validate method
+ struct.validate();
+ }
+
+ public void write(org.apache.thrift.protocol.TProtocol oprot, enableBFDFailover_result struct) throws org.apache.thrift.TException {
+ struct.validate();
+
+ oprot.writeStructBegin(STRUCT_DESC);
+ if (struct.isSetSuccess()) {
+ oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
+ oprot.writeI32(struct.success);
+ oprot.writeFieldEnd();
+ }
+ oprot.writeFieldStop();
+ oprot.writeStructEnd();
+ }
+
+ }
+
+ private static class enableBFDFailover_resultTupleSchemeFactory implements SchemeFactory {
+ public enableBFDFailover_resultTupleScheme getScheme() {
+ return new enableBFDFailover_resultTupleScheme();
+ }
+ }
+
+ private static class enableBFDFailover_resultTupleScheme extends TupleScheme<enableBFDFailover_result> {
+
+ @Override
+ public void write(org.apache.thrift.protocol.TProtocol prot, enableBFDFailover_result struct) throws org.apache.thrift.TException {
+ TTupleProtocol oprot = (TTupleProtocol) prot;
+ BitSet optionals = new BitSet();
+ if (struct.isSetSuccess()) {
+ optionals.set(0);
+ }
+ oprot.writeBitSet(optionals, 1);
+ if (struct.isSetSuccess()) {
+ oprot.writeI32(struct.success);
+ }
+ }
+
+ @Override
+ public void read(org.apache.thrift.protocol.TProtocol prot, enableBFDFailover_result struct) throws org.apache.thrift.TException {
+ TTupleProtocol iprot = (TTupleProtocol) prot;
+ BitSet incoming = iprot.readBitSet(1);
+ if (incoming.get(0)) {
+ struct.success = iprot.readI32();
+ struct.setSuccessIsSet(true);
+ }
+ }
+ }
+
+ }
+
+ public static class disableBFDFailover_args implements org.apache.thrift.TBase<disableBFDFailover_args, disableBFDFailover_args._Fields>, java.io.Serializable, Cloneable, Comparable<disableBFDFailover_args> {
+ private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("disableBFDFailover_args");
+
+
+ private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
+ static {
+ schemes.put(StandardScheme.class, new disableBFDFailover_argsStandardSchemeFactory());
+ schemes.put(TupleScheme.class, new disableBFDFailover_argsTupleSchemeFactory());
+ }
+
+
+ /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
+ public enum _Fields implements org.apache.thrift.TFieldIdEnum {
+;
+
+ private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+
+ static {
+ for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ byName.put(field.getFieldName(), field);
+ }
+ }
+
+ /**
+ * Find the _Fields constant that matches fieldId, or null if its not found.
+ */
+ public static _Fields findByThriftId(int fieldId) {
+ switch(fieldId) {
+ default:
+ return null;
+ }
+ }
+
+ /**
+ * Find the _Fields constant that matches fieldId, throwing an exception
+ * if it is not found.
+ */
+ public static _Fields findByThriftIdOrThrow(int fieldId) {
+ _Fields fields = findByThriftId(fieldId);
+ if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ return fields;
+ }
+
+ /**
+ * Find the _Fields constant that matches name, or null if its not found.
+ */
+ public static _Fields findByName(String name) {
+ return byName.get(name);
+ }
+
+ private final short _thriftId;
+ private final String _fieldName;
+
+ _Fields(short thriftId, String fieldName) {
+ _thriftId = thriftId;
+ _fieldName = fieldName;
+ }
+
+ public short getThriftFieldId() {
+ return _thriftId;
+ }
+
+ public String getFieldName() {
+ return _fieldName;
+ }
+ }
+ public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ static {
+ Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
+ metaDataMap = Collections.unmodifiableMap(tmpMap);
+ org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(disableBFDFailover_args.class, metaDataMap);
+ }
+
+ public disableBFDFailover_args() {
+ }
+
+ /**
+ * Performs a deep copy on <i>other</i>.
+ */
+ public disableBFDFailover_args(disableBFDFailover_args other) {
+ }
+
+ public disableBFDFailover_args deepCopy() {
+ return new disableBFDFailover_args(this);
+ }
+
+ @Override
+ public void clear() {
+ }
+
+ public void setFieldValue(_Fields field, Object value) {
+ switch (field) {
+ }
+ }
+
+ public Object getFieldValue(_Fields field) {
+ switch (field) {
+ }
+ throw new IllegalStateException();
+ }
+
+ /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
+ public boolean isSet(_Fields field) {
+ if (field == null) {
+ throw new IllegalArgumentException();
+ }
+
+ switch (field) {
+ }
+ throw new IllegalStateException();
+ }
+
+ @Override
+ public boolean equals(Object that) {
+ if (that == null)
+ return false;
+ if (that instanceof disableBFDFailover_args)
+ return this.equals((disableBFDFailover_args)that);
+ return false;
+ }
+
+ public boolean equals(disableBFDFailover_args that) {
+ if (that == null)
+ return false;
+
+ return true;
+ }
+
+ @Override
+ public int hashCode() {
+ List<Object> list = new ArrayList<Object>();
+
+ return list.hashCode();
+ }
+
+ @Override
+ public int compareTo(disableBFDFailover_args other) {
+ if (!getClass().equals(other.getClass())) {
+ return getClass().getName().compareTo(other.getClass().getName());
+ }
+
+ int lastComparison = 0;
+
+ return 0;
+ }
+
+ public _Fields fieldForId(int fieldId) {
+ return _Fields.findByThriftId(fieldId);
+ }
+
+ public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
+ schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ }
+
+ public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
+ schemes.get(oprot.getScheme()).getScheme().write(oprot, this);
+ }
+
+ @Override
+ public String toString() {
+ StringBuilder sb = new StringBuilder("disableBFDFailover_args(");
+ boolean first = true;
+
+ sb.append(")");
+ return sb.toString();
+ }
+
+ public void validate() throws org.apache.thrift.TException {
+ // check for required fields
+ // check for sub-struct validity
+ }
+
+ private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
+ try {
+ write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
+ } catch (org.apache.thrift.TException te) {
+ throw new java.io.IOException(te);
+ }
+ }
+
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
+ try {
+ read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
+ } catch (org.apache.thrift.TException te) {
+ throw new java.io.IOException(te);
+ }
+ }
+
+ private static class disableBFDFailover_argsStandardSchemeFactory implements SchemeFactory {
+ public disableBFDFailover_argsStandardScheme getScheme() {
+ return new disableBFDFailover_argsStandardScheme();
+ }
+ }
+
+ private static class disableBFDFailover_argsStandardScheme extends StandardScheme<disableBFDFailover_args> {
+
+ public void read(org.apache.thrift.protocol.TProtocol iprot, disableBFDFailover_args struct) throws org.apache.thrift.TException {
+ org.apache.thrift.protocol.TField schemeField;
+ iprot.readStructBegin();
+ while (true)
+ {
+ schemeField = iprot.readFieldBegin();
+ if (schemeField.type == org.apache.thrift.protocol.TType.STOP) {
+ break;
+ }
+ switch (schemeField.id) {
+ default:
+ org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
+ }
+ iprot.readFieldEnd();
+ }
+ iprot.readStructEnd();
+
+ // check for required fields of primitive type, which can't be checked in the validate method
+ struct.validate();
+ }
+
+ public void write(org.apache.thrift.protocol.TProtocol oprot, disableBFDFailover_args struct) throws org.apache.thrift.TException {
+ struct.validate();
+
+ oprot.writeStructBegin(STRUCT_DESC);
+ oprot.writeFieldStop();
+ oprot.writeStructEnd();
+ }
+
+ }
+
+ private static class disableBFDFailover_argsTupleSchemeFactory implements SchemeFactory {
+ public disableBFDFailover_argsTupleScheme getScheme() {
+ return new disableBFDFailover_argsTupleScheme();
+ }
+ }
+
+ private static class disableBFDFailover_argsTupleScheme extends TupleScheme<disableBFDFailover_args> {
+
+ @Override
+ public void write(org.apache.thrift.protocol.TProtocol prot, disableBFDFailover_args struct) throws org.apache.thrift.TException {
+ TTupleProtocol oprot = (TTupleProtocol) prot;
+ }
+
+ @Override
+ public void read(org.apache.thrift.protocol.TProtocol prot, disableBFDFailover_args struct) throws org.apache.thrift.TException {
+ TTupleProtocol iprot = (TTupleProtocol) prot;
+ }
+ }
+
+ }
+
+ public static class disableBFDFailover_result implements org.apache.thrift.TBase<disableBFDFailover_result, disableBFDFailover_result._Fields>, java.io.Serializable, Cloneable, Comparable<disableBFDFailover_result> {
+ private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("disableBFDFailover_result");
+
+ private static final org.apache.thrift.protocol.TField SUCCESS_FIELD_DESC = new org.apache.thrift.protocol.TField("success", org.apache.thrift.protocol.TType.I32, (short)0);
+
+ private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
+ static {
+ schemes.put(StandardScheme.class, new disableBFDFailover_resultStandardSchemeFactory());
+ schemes.put(TupleScheme.class, new disableBFDFailover_resultTupleSchemeFactory());
+ }
+
+ public int success; // required
+
+ /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
+ public enum _Fields implements org.apache.thrift.TFieldIdEnum {
+ SUCCESS((short)0, "success");
+
+ private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+
+ static {
+ for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ byName.put(field.getFieldName(), field);
+ }
+ }
+
+ /**
+ * Find the _Fields constant that matches fieldId, or null if its not found.
+ */
+ public static _Fields findByThriftId(int fieldId) {
+ switch(fieldId) {
+ case 0: // SUCCESS
+ return SUCCESS;
+ default:
+ return null;
+ }
+ }
+
+ /**
+ * Find the _Fields constant that matches fieldId, throwing an exception
+ * if it is not found.
+ */
+ public static _Fields findByThriftIdOrThrow(int fieldId) {
+ _Fields fields = findByThriftId(fieldId);
+ if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ return fields;
+ }
+
+ /**
+ * Find the _Fields constant that matches name, or null if its not found.
+ */
+ public static _Fields findByName(String name) {
+ return byName.get(name);
+ }
+
+ private final short _thriftId;
+ private final String _fieldName;
+
+ _Fields(short thriftId, String fieldName) {
+ _thriftId = thriftId;
+ _fieldName = fieldName;
+ }
+
+ public short getThriftFieldId() {
+ return _thriftId;
+ }
+
+ public String getFieldName() {
+ return _fieldName;
+ }
+ }
+
+ // isset id assignments
+ private static final int __SUCCESS_ISSET_ID = 0;
+ private byte __isset_bitfield = 0;
+ public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ static {
+ Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
+ tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT,
+ new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I32)));
+ metaDataMap = Collections.unmodifiableMap(tmpMap);
+ org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(disableBFDFailover_result.class, metaDataMap);
+ }
+
+ public disableBFDFailover_result() {
+ }
+
+ public disableBFDFailover_result(
+ int success)
+ {
+ this();
+ this.success = success;
+ setSuccessIsSet(true);
+ }
+
+ /**
+ * Performs a deep copy on <i>other</i>.
+ */
+ public disableBFDFailover_result(disableBFDFailover_result other) {
+ __isset_bitfield = other.__isset_bitfield;
+ this.success = other.success;
+ }
+
+ public disableBFDFailover_result deepCopy() {
+ return new disableBFDFailover_result(this);
+ }
+
+ @Override
+ public void clear() {
+ setSuccessIsSet(false);
+ this.success = 0;
+ }
+
+ public int getSuccess() {
+ return this.success;
+ }
+
+ public disableBFDFailover_result setSuccess(int success) {
+ this.success = success;
+ setSuccessIsSet(true);
+ return this;
+ }
+
+ public void unsetSuccess() {
+ __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __SUCCESS_ISSET_ID);
+ }
+
+ /** Returns true if field success is set (has been assigned a value) and false otherwise */
+ public boolean isSetSuccess() {
+ return EncodingUtils.testBit(__isset_bitfield, __SUCCESS_ISSET_ID);
+ }
+
+ public void setSuccessIsSet(boolean value) {
+ __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __SUCCESS_ISSET_ID, value);
+ }
+
+ public void setFieldValue(_Fields field, Object value) {
+ switch (field) {
+ case SUCCESS:
+ if (value == null) {
+ unsetSuccess();
+ } else {
+ setSuccess((Integer)value);
+ }
+ break;
+
+ }
+ }
+
+ public Object getFieldValue(_Fields field) {
+ switch (field) {
+ case SUCCESS:
+ return getSuccess();
+
+ }
+ throw new IllegalStateException();
+ }
+
+ /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
+ public boolean isSet(_Fields field) {
+ if (field == null) {
+ throw new IllegalArgumentException();
+ }
+
+ switch (field) {
+ case SUCCESS:
+ return isSetSuccess();
+ }
+ throw new IllegalStateException();
+ }
+
+ @Override
+ public boolean equals(Object that) {
+ if (that == null)
+ return false;
+ if (that instanceof disableBFDFailover_result)
+ return this.equals((disableBFDFailover_result)that);
+ return false;
+ }
+
+ public boolean equals(disableBFDFailover_result that) {
+ if (that == null)
+ return false;
+
+ boolean this_present_success = true;
+ boolean that_present_success = true;
+ if (this_present_success || that_present_success) {
+ if (!(this_present_success && that_present_success))
+ return false;
+ if (this.success != that.success)
+ return false;
+ }
+
+ return true;
+ }
+
+ @Override
+ public int hashCode() {
+ List<Object> list = new ArrayList<Object>();
+
+ boolean present_success = true;
+ list.add(present_success);
+ if (present_success)
+ list.add(success);
+
+ return list.hashCode();
+ }
+
+ @Override
+ public int compareTo(disableBFDFailover_result other) {
+ if (!getClass().equals(other.getClass())) {
+ return getClass().getName().compareTo(other.getClass().getName());
+ }
+
+ int lastComparison = 0;
+
+ lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(other.isSetSuccess());
+ if (lastComparison != 0) {
+ return lastComparison;
+ }
+ if (isSetSuccess()) {
+ lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, other.success);
+ if (lastComparison != 0) {
+ return lastComparison;
+ }
+ }
+ return 0;
+ }
+
+ public _Fields fieldForId(int fieldId) {
+ return _Fields.findByThriftId(fieldId);
+ }
+
+ public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
+ schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ }
+
+ public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
+ schemes.get(oprot.getScheme()).getScheme().write(oprot, this);
+ }
+
+ @Override
+ public String toString() {
+ StringBuilder sb = new StringBuilder("disableBFDFailover_result(");
+ boolean first = true;
+
+ sb.append("success:");
+ sb.append(this.success);
+ first = false;
+ sb.append(")");
+ return sb.toString();
+ }
+
+ public void validate() throws org.apache.thrift.TException {
+ // check for required fields
+ // check for sub-struct validity
+ }
+
+ private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
+ try {
+ write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
+ } catch (org.apache.thrift.TException te) {
+ throw new java.io.IOException(te);
+ }
+ }
+
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
+ try {
+ // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
+ __isset_bitfield = 0;
+ read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
+ } catch (org.apache.thrift.TException te) {
+ throw new java.io.IOException(te);
+ }
+ }
+
+ private static class disableBFDFailover_resultStandardSchemeFactory implements SchemeFactory {
+ public disableBFDFailover_resultStandardScheme getScheme() {
+ return new disableBFDFailover_resultStandardScheme();
+ }
+ }
+
+ private static class disableBFDFailover_resultStandardScheme extends StandardScheme<disableBFDFailover_result> {
+
+ public void read(org.apache.thrift.protocol.TProtocol iprot, disableBFDFailover_result struct) throws org.apache.thrift.TException {
+ org.apache.thrift.protocol.TField schemeField;
+ iprot.readStructBegin();
+ while (true)
+ {
+ schemeField = iprot.readFieldBegin();
+ if (schemeField.type == org.apache.thrift.protocol.TType.STOP) {
+ break;
+ }
+ switch (schemeField.id) {
+ case 0: // SUCCESS
+ if (schemeField.type == org.apache.thrift.protocol.TType.I32) {
+ struct.success = iprot.readI32();
+ struct.setSuccessIsSet(true);
+ } else {
+ org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
+ }
+ break;
+ default:
+ org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
+ }
+ iprot.readFieldEnd();
+ }
+ iprot.readStructEnd();
+
+ // check for required fields of primitive type, which can't be checked in the validate method
+ struct.validate();
+ }
+
+ public void write(org.apache.thrift.protocol.TProtocol oprot, disableBFDFailover_result struct) throws org.apache.thrift.TException {
+ struct.validate();
+
+ oprot.writeStructBegin(STRUCT_DESC);
+ if (struct.isSetSuccess()) {
+ oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
+ oprot.writeI32(struct.success);
+ oprot.writeFieldEnd();
+ }
+ oprot.writeFieldStop();
+ oprot.writeStructEnd();
+ }
+
+ }
+
+ private static class disableBFDFailover_resultTupleSchemeFactory implements SchemeFactory {
+ public disableBFDFailover_resultTupleScheme getScheme() {
+ return new disableBFDFailover_resultTupleScheme();
+ }
+ }
+
+ private static class disableBFDFailover_resultTupleScheme extends TupleScheme<disableBFDFailover_result> {
+
+ @Override
+ public void write(org.apache.thrift.protocol.TProtocol prot, disableBFDFailover_result struct) throws org.apache.thrift.TException {
+ TTupleProtocol oprot = (TTupleProtocol) prot;
+ BitSet optionals = new BitSet();
+ if (struct.isSetSuccess()) {
+ optionals.set(0);
+ }
+ oprot.writeBitSet(optionals, 1);
+ if (struct.isSetSuccess()) {
+ oprot.writeI32(struct.success);
+ }
+ }
+
+ @Override
+ public void read(org.apache.thrift.protocol.TProtocol prot, disableBFDFailover_result struct) throws org.apache.thrift.TException {
+ TTupleProtocol iprot = (TTupleProtocol) prot;
+ BitSet incoming = iprot.readBitSet(1);
+ if (incoming.get(0)) {
+ struct.success = iprot.readI32();
+ struct.setSuccessIsSet(true);
+ }
+ }
+ }
+
+ }
+
+ public static class getPeerStatus_args implements org.apache.thrift.TBase<getPeerStatus_args, getPeerStatus_args._Fields>, java.io.Serializable, Cloneable, Comparable<getPeerStatus_args> {
+ private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getPeerStatus_args");
+
+ private static final org.apache.thrift.protocol.TField IP_ADDRESS_FIELD_DESC = new org.apache.thrift.protocol.TField("ipAddress", org.apache.thrift.protocol.TType.STRING, (short)1);
+ private static final org.apache.thrift.protocol.TField AS_NUMBER_FIELD_DESC = new org.apache.thrift.protocol.TField("asNumber", org.apache.thrift.protocol.TType.I64, (short)2);
+
+ private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
+ static {
+ schemes.put(StandardScheme.class, new getPeerStatus_argsStandardSchemeFactory());
+ schemes.put(TupleScheme.class, new getPeerStatus_argsTupleSchemeFactory());
+ }
+
+ public String ipAddress; // required
+ public long asNumber; // required
+
+ /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
+ public enum _Fields implements org.apache.thrift.TFieldIdEnum {
+ IP_ADDRESS((short)1, "ipAddress"),
+ AS_NUMBER((short)2, "asNumber");
+
+ private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+
+ static {
+ for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ byName.put(field.getFieldName(), field);
+ }
+ }
+
+ /**
+ * Find the _Fields constant that matches fieldId, or null if its not found.
+ */
+ public static _Fields findByThriftId(int fieldId) {
+ switch(fieldId) {
+ case 1: // IP_ADDRESS
+ return IP_ADDRESS;
+ case 2: // AS_NUMBER
+ return AS_NUMBER;
+ default:
+ return null;
+ }
+ }
+
+ /**
+ * Find the _Fields constant that matches fieldId, throwing an exception
+ * if it is not found.
+ */
+ public static _Fields findByThriftIdOrThrow(int fieldId) {
+ _Fields fields = findByThriftId(fieldId);
+ if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ return fields;
+ }
+
+ /**
+ * Find the _Fields constant that matches name, or null if its not found.
+ */
+ public static _Fields findByName(String name) {
+ return byName.get(name);
+ }
+
+ private final short _thriftId;
+ private final String _fieldName;
+
+ _Fields(short thriftId, String fieldName) {
+ _thriftId = thriftId;
+ _fieldName = fieldName;
+ }
+
+ public short getThriftFieldId() {
+ return _thriftId;
+ }
+
+ public String getFieldName() {
+ return _fieldName;
+ }
+ }
+
+ // isset id assignments
+ private static final int __ASNUMBER_ISSET_ID = 0;
+ private byte __isset_bitfield = 0;
+ public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ static {
+ Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
+ tmpMap.put(_Fields.IP_ADDRESS, new org.apache.thrift.meta_data.FieldMetaData("ipAddress", org.apache.thrift.TFieldRequirementType.DEFAULT,
+ new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
+ tmpMap.put(_Fields.AS_NUMBER, new org.apache.thrift.meta_data.FieldMetaData("asNumber", org.apache.thrift.TFieldRequirementType.DEFAULT,
+ new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
+ metaDataMap = Collections.unmodifiableMap(tmpMap);
+ org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getPeerStatus_args.class, metaDataMap);
+ }
+
+ public getPeerStatus_args() {
+ }
+
+ public getPeerStatus_args(
+ String ipAddress,
+ long asNumber)
+ {
+ this();
+ this.ipAddress = ipAddress;
+ this.asNumber = asNumber;
+ setAsNumberIsSet(true);
+ }
+
+ /**
+ * Performs a deep copy on <i>other</i>.
+ */
+ public getPeerStatus_args(getPeerStatus_args other) {
+ __isset_bitfield = other.__isset_bitfield;
+ if (other.isSetIpAddress()) {
+ this.ipAddress = other.ipAddress;
+ }
+ this.asNumber = other.asNumber;
+ }
+
+ public getPeerStatus_args deepCopy() {
+ return new getPeerStatus_args(this);
+ }
+
+ @Override
+ public void clear() {
+ this.ipAddress = null;
+ setAsNumberIsSet(false);
+ this.asNumber = 0;
+ }
+
+ public String getIpAddress() {
+ return this.ipAddress;
+ }
+
+ public getPeerStatus_args setIpAddress(String ipAddress) {
+ this.ipAddress = ipAddress;
+ return this;
+ }
+
+ public void unsetIpAddress() {
+ this.ipAddress = null;
+ }
+
+ /** Returns true if field ipAddress is set (has been assigned a value) and false otherwise */
+ public boolean isSetIpAddress() {
+ return this.ipAddress != null;
+ }
+
+ public void setIpAddressIsSet(boolean value) {
+ if (!value) {
+ this.ipAddress = null;
+ }
+ }
+
+ public long getAsNumber() {
+ return this.asNumber;
+ }
+
+ public getPeerStatus_args setAsNumber(long asNumber) {
+ this.asNumber = asNumber;
+ setAsNumberIsSet(true);
+ return this;
+ }
+
+ public void unsetAsNumber() {
+ __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __ASNUMBER_ISSET_ID);
+ }
+
+ /** Returns true if field asNumber is set (has been assigned a value) and false otherwise */
+ public boolean isSetAsNumber() {
+ return EncodingUtils.testBit(__isset_bitfield, __ASNUMBER_ISSET_ID);
+ }
+
+ public void setAsNumberIsSet(boolean value) {
+ __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __ASNUMBER_ISSET_ID, value);
+ }
+
+ public void setFieldValue(_Fields field, Object value) {
+ switch (field) {
+ case IP_ADDRESS:
+ if (value == null) {
+ unsetIpAddress();
+ } else {
+ setIpAddress((String)value);
+ }
+ break;
+
+ case AS_NUMBER:
+ if (value == null) {
+ unsetAsNumber();
+ } else {
+ setAsNumber((Long)value);
+ }
+ break;
+
+ }
+ }
+
+ public Object getFieldValue(_Fields field) {
+ switch (field) {
+ case IP_ADDRESS:
+ return getIpAddress();
+
+ case AS_NUMBER:
+ return getAsNumber();
+
+ }
+ throw new IllegalStateException();
+ }
+
+ /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
+ public boolean isSet(_Fields field) {
+ if (field == null) {
+ throw new IllegalArgumentException();
+ }
+
+ switch (field) {
+ case IP_ADDRESS:
+ return isSetIpAddress();
+ case AS_NUMBER:
+ return isSetAsNumber();
+ }
+ throw new IllegalStateException();
+ }
+
+ @Override
+ public boolean equals(Object that) {
+ if (that == null)
+ return false;
+ if (that instanceof getPeerStatus_args)
+ return this.equals((getPeerStatus_args)that);
+ return false;
+ }
+
+ public boolean equals(getPeerStatus_args that) {
+ if (that == null)
+ return false;
+
+ boolean this_present_ipAddress = true && this.isSetIpAddress();
+ boolean that_present_ipAddress = true && that.isSetIpAddress();
+ if (this_present_ipAddress || that_present_ipAddress) {
+ if (!(this_present_ipAddress && that_present_ipAddress))
+ return false;
+ if (!this.ipAddress.equals(that.ipAddress))
+ return false;
+ }
+
+ boolean this_present_asNumber = true;
+ boolean that_present_asNumber = true;
+ if (this_present_asNumber || that_present_asNumber) {
+ if (!(this_present_asNumber && that_present_asNumber))
+ return false;
+ if (this.asNumber != that.asNumber)
+ return false;
+ }
+
+ return true;
+ }
+
+ @Override
+ public int hashCode() {
+ List<Object> list = new ArrayList<Object>();
+
+ boolean present_ipAddress = true && (isSetIpAddress());
+ list.add(present_ipAddress);
+ if (present_ipAddress)
+ list.add(ipAddress);
+
+ boolean present_asNumber = true;
+ list.add(present_asNumber);
+ if (present_asNumber)
+ list.add(asNumber);
+
+ return list.hashCode();
+ }
+
+ @Override
+ public int compareTo(getPeerStatus_args other) {
+ if (!getClass().equals(other.getClass())) {
+ return getClass().getName().compareTo(other.getClass().getName());
+ }
+
+ int lastComparison = 0;
+
+ lastComparison = Boolean.valueOf(isSetIpAddress()).compareTo(other.isSetIpAddress());
+ if (lastComparison != 0) {
+ return lastComparison;
+ }
+ if (isSetIpAddress()) {
+ lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.ipAddress, other.ipAddress);
+ if (lastComparison != 0) {
+ return lastComparison;
+ }
+ }
+ lastComparison = Boolean.valueOf(isSetAsNumber()).compareTo(other.isSetAsNumber());
+ if (lastComparison != 0) {
+ return lastComparison;
+ }
+ if (isSetAsNumber()) {
+ lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.asNumber, other.asNumber);
+ if (lastComparison != 0) {
+ return lastComparison;
+ }
+ }
+ return 0;
+ }
+
+ public _Fields fieldForId(int fieldId) {
+ return _Fields.findByThriftId(fieldId);
+ }
+
+ public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
+ schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ }
+
+ public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
+ schemes.get(oprot.getScheme()).getScheme().write(oprot, this);
+ }
+
+ @Override
+ public String toString() {
+ StringBuilder sb = new StringBuilder("getPeerStatus_args(");
+ boolean first = true;
+
+ sb.append("ipAddress:");
+ if (this.ipAddress == null) {
+ sb.append("null");
+ } else {
+ sb.append(this.ipAddress);
+ }
+ first = false;
+ if (!first) sb.append(", ");
+ sb.append("asNumber:");
+ sb.append(this.asNumber);
+ first = false;
+ sb.append(")");
+ return sb.toString();
+ }
+
+ public void validate() throws org.apache.thrift.TException {
+ // check for required fields
+ // check for sub-struct validity
+ }
+
+ private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
+ try {
+ write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
+ } catch (org.apache.thrift.TException te) {
+ throw new java.io.IOException(te);
+ }
+ }
+
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
+ try {
+ // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
+ __isset_bitfield = 0;
+ read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
+ } catch (org.apache.thrift.TException te) {
+ throw new java.io.IOException(te);
+ }
+ }
+
+ private static class getPeerStatus_argsStandardSchemeFactory implements SchemeFactory {
+ public getPeerStatus_argsStandardScheme getScheme() {
+ return new getPeerStatus_argsStandardScheme();
+ }
+ }
+
+ private static class getPeerStatus_argsStandardScheme extends StandardScheme<getPeerStatus_args> {
+
+ public void read(org.apache.thrift.protocol.TProtocol iprot, getPeerStatus_args struct) throws org.apache.thrift.TException {
+ org.apache.thrift.protocol.TField schemeField;
+ iprot.readStructBegin();
+ while (true)
+ {
+ schemeField = iprot.readFieldBegin();
+ if (schemeField.type == org.apache.thrift.protocol.TType.STOP) {
+ break;
+ }
+ switch (schemeField.id) {
+ case 1: // IP_ADDRESS
+ if (schemeField.type == org.apache.thrift.protocol.TType.STRING) {
+ struct.ipAddress = iprot.readString();
+ struct.setIpAddressIsSet(true);
+ } else {
+ org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
+ }
+ break;
+ case 2: // AS_NUMBER
+ if (schemeField.type == org.apache.thrift.protocol.TType.I64) {
+ struct.asNumber = iprot.readI64();
+ struct.setAsNumberIsSet(true);
+ } else {
+ org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
+ }
+ break;
+ default:
+ org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
+ }
+ iprot.readFieldEnd();
+ }
+ iprot.readStructEnd();
+
+ // check for required fields of primitive type, which can't be checked in the validate method
+ struct.validate();
+ }
+
+ public void write(org.apache.thrift.protocol.TProtocol oprot, getPeerStatus_args struct) throws org.apache.thrift.TException {
+ struct.validate();
+
+ oprot.writeStructBegin(STRUCT_DESC);
+ if (struct.ipAddress != null) {
+ oprot.writeFieldBegin(IP_ADDRESS_FIELD_DESC);
+ oprot.writeString(struct.ipAddress);
+ oprot.writeFieldEnd();
+ }
+ oprot.writeFieldBegin(AS_NUMBER_FIELD_DESC);
+ oprot.writeI64(struct.asNumber);
+ oprot.writeFieldEnd();
+ oprot.writeFieldStop();
+ oprot.writeStructEnd();
+ }
+
+ }
+
+ private static class getPeerStatus_argsTupleSchemeFactory implements SchemeFactory {
+ public getPeerStatus_argsTupleScheme getScheme() {
+ return new getPeerStatus_argsTupleScheme();
+ }
+ }
+
+ private static class getPeerStatus_argsTupleScheme extends TupleScheme<getPeerStatus_args> {
+
+ @Override
+ public void write(org.apache.thrift.protocol.TProtocol prot, getPeerStatus_args struct) throws org.apache.thrift.TException {
+ TTupleProtocol oprot = (TTupleProtocol) prot;
+ BitSet optionals = new BitSet();
+ if (struct.isSetIpAddress()) {
+ optionals.set(0);
+ }
+ if (struct.isSetAsNumber()) {
+ optionals.set(1);
+ }
+ oprot.writeBitSet(optionals, 2);
+ if (struct.isSetIpAddress()) {
+ oprot.writeString(struct.ipAddress);
+ }
+ if (struct.isSetAsNumber()) {
+ oprot.writeI64(struct.asNumber);
+ }
+ }
+
+ @Override
+ public void read(org.apache.thrift.protocol.TProtocol prot, getPeerStatus_args struct) throws org.apache.thrift.TException {
+ TTupleProtocol iprot = (TTupleProtocol) prot;
+ BitSet incoming = iprot.readBitSet(2);
+ if (incoming.get(0)) {
+ struct.ipAddress = iprot.readString();
+ struct.setIpAddressIsSet(true);
+ }
+ if (incoming.get(1)) {
+ struct.asNumber = iprot.readI64();
+ struct.setAsNumberIsSet(true);
+ }
+ }
+ }
+
+ }
+
+ public static class getPeerStatus_result implements org.apache.thrift.TBase<getPeerStatus_result, getPeerStatus_result._Fields>, java.io.Serializable, Cloneable, Comparable<getPeerStatus_result> {
+ private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getPeerStatus_result");
+
+ private static final org.apache.thrift.protocol.TField SUCCESS_FIELD_DESC = new org.apache.thrift.protocol.TField("success", org.apache.thrift.protocol.TType.I32, (short)0);
+
+ private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
+ static {
+ schemes.put(StandardScheme.class, new getPeerStatus_resultStandardSchemeFactory());
+ schemes.put(TupleScheme.class, new getPeerStatus_resultTupleSchemeFactory());
+ }
+
+ /**
+ *
+ * @see peer_status_type
+ */
+ public peer_status_type success; // required
+
+ /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
+ public enum _Fields implements org.apache.thrift.TFieldIdEnum {
+ /**
+ *
+ * @see peer_status_type
+ */
+ SUCCESS((short)0, "success");
+
+ private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+
+ static {
+ for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ byName.put(field.getFieldName(), field);
+ }
+ }
+
+ /**
+ * Find the _Fields constant that matches fieldId, or null if its not found.
+ */
+ public static _Fields findByThriftId(int fieldId) {
+ switch(fieldId) {
+ case 0: // SUCCESS
+ return SUCCESS;
+ default:
+ return null;
+ }
+ }
+
+ /**
+ * Find the _Fields constant that matches fieldId, throwing an exception
+ * if it is not found.
+ */
+ public static _Fields findByThriftIdOrThrow(int fieldId) {
+ _Fields fields = findByThriftId(fieldId);
+ if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ return fields;
+ }
+
+ /**
+ * Find the _Fields constant that matches name, or null if its not found.
+ */
+ public static _Fields findByName(String name) {
+ return byName.get(name);
+ }
+
+ private final short _thriftId;
+ private final String _fieldName;
+
+ _Fields(short thriftId, String fieldName) {
+ _thriftId = thriftId;
+ _fieldName = fieldName;
+ }
+
+ public short getThriftFieldId() {
+ return _thriftId;
+ }
+
+ public String getFieldName() {
+ return _fieldName;
+ }
+ }
+
+ // isset id assignments
+ public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ static {
+ Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
+ tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT,
+ new org.apache.thrift.meta_data.EnumMetaData(org.apache.thrift.protocol.TType.ENUM, peer_status_type.class)));
+ metaDataMap = Collections.unmodifiableMap(tmpMap);
+ org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getPeerStatus_result.class, metaDataMap);
+ }
+
+ public getPeerStatus_result() {
+ }
+
+ public getPeerStatus_result(
+ peer_status_type success)
+ {
+ this();
+ this.success = success;
+ }
+
+ /**
+ * Performs a deep copy on <i>other</i>.
+ */
+ public getPeerStatus_result(getPeerStatus_result other) {
+ if (other.isSetSuccess()) {
+ this.success = other.success;
+ }
+ }
+
+ public getPeerStatus_result deepCopy() {
+ return new getPeerStatus_result(this);
+ }
+
+ @Override
+ public void clear() {
+ this.success = null;
+ }
+
+ /**
+ *
+ * @see peer_status_type
+ */
+ public peer_status_type getSuccess() {
+ return this.success;
+ }
+
+ /**
+ *
+ * @see peer_status_type
+ */
+ public getPeerStatus_result setSuccess(peer_status_type success) {
+ this.success = success;
+ return this;
+ }
+
+ public void unsetSuccess() {
+ this.success = null;
+ }
+
+ /** Returns true if field success is set (has been assigned a value) and false otherwise */
+ public boolean isSetSuccess() {
+ return this.success != null;
+ }
+
+ public void setSuccessIsSet(boolean value) {
+ if (!value) {
+ this.success = null;
+ }
+ }
+
+ public void setFieldValue(_Fields field, Object value) {
+ switch (field) {
+ case SUCCESS:
+ if (value == null) {
+ unsetSuccess();
+ } else {
+ setSuccess((peer_status_type)value);
+ }
+ break;
+
+ }
+ }
+
+ public Object getFieldValue(_Fields field) {
+ switch (field) {
+ case SUCCESS:
+ return getSuccess();
+
+ }
+ throw new IllegalStateException();
+ }
+
+ /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
+ public boolean isSet(_Fields field) {
+ if (field == null) {
+ throw new IllegalArgumentException();
+ }
+
+ switch (field) {
+ case SUCCESS:
+ return isSetSuccess();
+ }
+ throw new IllegalStateException();
+ }
+
+ @Override
+ public boolean equals(Object that) {
+ if (that == null)
+ return false;
+ if (that instanceof getPeerStatus_result)
+ return this.equals((getPeerStatus_result)that);
+ return false;
+ }
+
+ public boolean equals(getPeerStatus_result that) {
+ if (that == null)
+ return false;
+
+ boolean this_present_success = true && this.isSetSuccess();
+ boolean that_present_success = true && that.isSetSuccess();
+ if (this_present_success || that_present_success) {
+ if (!(this_present_success && that_present_success))
+ return false;
+ if (!this.success.equals(that.success))
+ return false;
+ }
+
+ return true;
+ }
+
+ @Override
+ public int hashCode() {
+ List<Object> list = new ArrayList<Object>();
+
+ boolean present_success = true && (isSetSuccess());
+ list.add(present_success);
+ if (present_success)
+ list.add(success.getValue());
+
+ return list.hashCode();
+ }
+
+ @Override
+ public int compareTo(getPeerStatus_result other) {
+ if (!getClass().equals(other.getClass())) {
+ return getClass().getName().compareTo(other.getClass().getName());
+ }
+
+ int lastComparison = 0;
+
+ lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(other.isSetSuccess());
+ if (lastComparison != 0) {
+ return lastComparison;
+ }
+ if (isSetSuccess()) {
+ lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, other.success);
+ if (lastComparison != 0) {
+ return lastComparison;
+ }
+ }
+ return 0;
+ }
+
+ public _Fields fieldForId(int fieldId) {
+ return _Fields.findByThriftId(fieldId);
+ }
+
+ public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
+ schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ }
+
+ public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
+ schemes.get(oprot.getScheme()).getScheme().write(oprot, this);
+ }
+
+ @Override
+ public String toString() {
+ StringBuilder sb = new StringBuilder("getPeerStatus_result(");
+ boolean first = true;
+
+ sb.append("success:");
+ if (this.success == null) {
+ sb.append("null");
+ } else {
+ sb.append(this.success);
+ }
+ first = false;
+ sb.append(")");
+ return sb.toString();
+ }
+
+ public void validate() throws org.apache.thrift.TException {
+ // check for required fields
+ // check for sub-struct validity
+ }
+
+ private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
+ try {
+ write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
+ } catch (org.apache.thrift.TException te) {
+ throw new java.io.IOException(te);
+ }
+ }
+
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
+ try {
+ read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
+ } catch (org.apache.thrift.TException te) {
+ throw new java.io.IOException(te);
+ }
+ }
+
+ private static class getPeerStatus_resultStandardSchemeFactory implements SchemeFactory {
+ public getPeerStatus_resultStandardScheme getScheme() {
+ return new getPeerStatus_resultStandardScheme();
+ }
+ }
+
+ private static class getPeerStatus_resultStandardScheme extends StandardScheme<getPeerStatus_result> {
+
+ public void read(org.apache.thrift.protocol.TProtocol iprot, getPeerStatus_result struct) throws org.apache.thrift.TException {
+ org.apache.thrift.protocol.TField schemeField;
+ iprot.readStructBegin();
+ while (true)
+ {
+ schemeField = iprot.readFieldBegin();
+ if (schemeField.type == org.apache.thrift.protocol.TType.STOP) {
+ break;
+ }
+ switch (schemeField.id) {
+ case 0: // SUCCESS
+ if (schemeField.type == org.apache.thrift.protocol.TType.I32) {
+ struct.success = peer_status_type.findByValue(iprot.readI32());
+ struct.setSuccessIsSet(true);
+ } else {
+ org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
+ }
+ break;
+ default:
+ org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
+ }
+ iprot.readFieldEnd();
+ }
+ iprot.readStructEnd();
+
+ // check for required fields of primitive type, which can't be checked in the validate method
+ struct.validate();
+ }
+
+ public void write(org.apache.thrift.protocol.TProtocol oprot, getPeerStatus_result struct) throws org.apache.thrift.TException {
+ struct.validate();
+
+ oprot.writeStructBegin(STRUCT_DESC);
+ if (struct.success != null) {
+ oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
+ oprot.writeI32(struct.success.getValue());
+ oprot.writeFieldEnd();
+ }
+ oprot.writeFieldStop();
+ oprot.writeStructEnd();
+ }
+
+ }
+
+ private static class getPeerStatus_resultTupleSchemeFactory implements SchemeFactory {
+ public getPeerStatus_resultTupleScheme getScheme() {
+ return new getPeerStatus_resultTupleScheme();
+ }
+ }
+
+ private static class getPeerStatus_resultTupleScheme extends TupleScheme<getPeerStatus_result> {
+
+ @Override
+ public void write(org.apache.thrift.protocol.TProtocol prot, getPeerStatus_result struct) throws org.apache.thrift.TException {
+ TTupleProtocol oprot = (TTupleProtocol) prot;
+ BitSet optionals = new BitSet();
+ if (struct.isSetSuccess()) {
+ optionals.set(0);
+ }
+ oprot.writeBitSet(optionals, 1);
+ if (struct.isSetSuccess()) {
+ oprot.writeI32(struct.success.getValue());
+ }
+ }
+
+ @Override
+ public void read(org.apache.thrift.protocol.TProtocol prot, getPeerStatus_result struct) throws org.apache.thrift.TException {
+ TTupleProtocol iprot = (TTupleProtocol) prot;
+ BitSet incoming = iprot.readBitSet(1);
+ if (incoming.get(0)) {
+ struct.success = peer_status_type.findByValue(iprot.readI32());
+ struct.setSuccessIsSet(true);
+ }
+ }
+ }
+
+ }
+
}
-/**
- * Autogenerated by Thrift Compiler (0.9.3)
- *
- * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
- * @generated
- */
-
- package org.opendaylight.netvirt.bgpmanager.thrift.gen;
-import org.apache.thrift.scheme.IScheme;
-import org.apache.thrift.scheme.SchemeFactory;
-import org.apache.thrift.scheme.StandardScheme;
-
-import org.apache.thrift.scheme.TupleScheme;
-import org.apache.thrift.protocol.TTupleProtocol;
-import org.apache.thrift.protocol.TProtocolException;
-import org.apache.thrift.EncodingUtils;
-import org.apache.thrift.TException;
-import org.apache.thrift.async.AsyncMethodCallback;
-import org.apache.thrift.server.AbstractNonblockingServer.*;
-import java.util.List;
-import java.util.ArrayList;
-import java.util.Map;
-import java.util.HashMap;
-import java.util.EnumMap;
-import java.util.Set;
-import java.util.HashSet;
-import java.util.EnumSet;
-import java.util.Collections;
-import java.util.BitSet;
-import java.nio.ByteBuffer;
-import java.util.Arrays;
-import javax.annotation.Generated;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"})
-@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)", date = "2017-09-13")
-public class BgpUpdater {
-
- public interface Iface {
-
- public void onUpdatePushRoute(protocol_type p_type, String rd, String prefix, int prefixlen, String nexthop, int ethtag, String esi, String macaddress, int l3label, int l2label, String routermac, af_afi afi) throws org.apache.thrift.TException;
-
- public void onUpdateWithdrawRoute(protocol_type p_type, String rd, String prefix, int prefixlen, String nexthop, int ethtag, String esi, String macaddress, int l3label, int l2label, af_afi afi) throws org.apache.thrift.TException;
-
- public void onStartConfigResyncNotification() throws org.apache.thrift.TException;
-
- public void onNotificationSendEvent(String prefix, byte errCode, byte errSubcode) throws org.apache.thrift.TException;
-
- }
-
- public interface AsyncIface {
-
- public void onUpdatePushRoute(protocol_type p_type, String rd, String prefix, int prefixlen, String nexthop, int ethtag, String esi, String macaddress, int l3label, int l2label, String routermac, af_afi afi, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
-
- public void onUpdateWithdrawRoute(protocol_type p_type, String rd, String prefix, int prefixlen, String nexthop, int ethtag, String esi, String macaddress, int l3label, int l2label, af_afi afi, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
-
- public void onStartConfigResyncNotification(org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
-
- public void onNotificationSendEvent(String prefix, byte errCode, byte errSubcode, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
-
- }
-
- public static class Client extends org.apache.thrift.TServiceClient implements Iface {
- public static class Factory implements org.apache.thrift.TServiceClientFactory<Client> {
- public Factory() {}
- public Client getClient(org.apache.thrift.protocol.TProtocol prot) {
- return new Client(prot);
- }
- public Client getClient(org.apache.thrift.protocol.TProtocol iprot, org.apache.thrift.protocol.TProtocol oprot) {
- return new Client(iprot, oprot);
- }
- }
-
- public Client(org.apache.thrift.protocol.TProtocol prot)
- {
- super(prot, prot);
- }
-
- public Client(org.apache.thrift.protocol.TProtocol iprot, org.apache.thrift.protocol.TProtocol oprot) {
- super(iprot, oprot);
- }
-
- public void onUpdatePushRoute(protocol_type p_type, String rd, String prefix, int prefixlen, String nexthop, int ethtag, String esi, String macaddress, int l3label, int l2label, String routermac, af_afi afi) throws org.apache.thrift.TException
- {
- send_onUpdatePushRoute(p_type, rd, prefix, prefixlen, nexthop, ethtag, esi, macaddress, l3label, l2label, routermac, afi);
- }
-
- public void send_onUpdatePushRoute(protocol_type p_type, String rd, String prefix, int prefixlen, String nexthop, int ethtag, String esi, String macaddress, int l3label, int l2label, String routermac, af_afi afi) throws org.apache.thrift.TException
- {
- onUpdatePushRoute_args args = new onUpdatePushRoute_args();
- args.setP_type(p_type);
- args.setRd(rd);
- args.setPrefix(prefix);
- args.setPrefixlen(prefixlen);
- args.setNexthop(nexthop);
- args.setEthtag(ethtag);
- args.setEsi(esi);
- args.setMacaddress(macaddress);
- args.setL3label(l3label);
- args.setL2label(l2label);
- args.setRoutermac(routermac);
- args.setAfi(afi);
- sendBaseOneway("onUpdatePushRoute", args);
- }
-
- public void onUpdateWithdrawRoute(protocol_type p_type, String rd, String prefix, int prefixlen, String nexthop, int ethtag, String esi, String macaddress, int l3label, int l2label, af_afi afi) throws org.apache.thrift.TException
- {
- send_onUpdateWithdrawRoute(p_type, rd, prefix, prefixlen, nexthop, ethtag, esi, macaddress, l3label, l2label, afi);
- }
-
- public void send_onUpdateWithdrawRoute(protocol_type p_type, String rd, String prefix, int prefixlen, String nexthop, int ethtag, String esi, String macaddress, int l3label, int l2label, af_afi afi) throws org.apache.thrift.TException
- {
- onUpdateWithdrawRoute_args args = new onUpdateWithdrawRoute_args();
- args.setP_type(p_type);
- args.setRd(rd);
- args.setPrefix(prefix);
- args.setPrefixlen(prefixlen);
- args.setNexthop(nexthop);
- args.setEthtag(ethtag);
- args.setEsi(esi);
- args.setMacaddress(macaddress);
- args.setL3label(l3label);
- args.setL2label(l2label);
- args.setAfi(afi);
- sendBaseOneway("onUpdateWithdrawRoute", args);
- }
-
- public void onStartConfigResyncNotification() throws org.apache.thrift.TException
- {
- send_onStartConfigResyncNotification();
- }
-
- public void send_onStartConfigResyncNotification() throws org.apache.thrift.TException
- {
- onStartConfigResyncNotification_args args = new onStartConfigResyncNotification_args();
- sendBaseOneway("onStartConfigResyncNotification", args);
- }
-
- public void onNotificationSendEvent(String prefix, byte errCode, byte errSubcode) throws org.apache.thrift.TException
- {
- send_onNotificationSendEvent(prefix, errCode, errSubcode);
- }
-
- public void send_onNotificationSendEvent(String prefix, byte errCode, byte errSubcode) throws org.apache.thrift.TException
- {
- onNotificationSendEvent_args args = new onNotificationSendEvent_args();
- args.setPrefix(prefix);
- args.setErrCode(errCode);
- args.setErrSubcode(errSubcode);
- sendBaseOneway("onNotificationSendEvent", args);
- }
-
- }
- public static class AsyncClient extends org.apache.thrift.async.TAsyncClient implements AsyncIface {
- public static class Factory implements org.apache.thrift.async.TAsyncClientFactory<AsyncClient> {
- private org.apache.thrift.async.TAsyncClientManager clientManager;
- private org.apache.thrift.protocol.TProtocolFactory protocolFactory;
- public Factory(org.apache.thrift.async.TAsyncClientManager clientManager, org.apache.thrift.protocol.TProtocolFactory protocolFactory) {
- this.clientManager = clientManager;
- this.protocolFactory = protocolFactory;
- }
- public AsyncClient getAsyncClient(org.apache.thrift.transport.TNonblockingTransport transport) {
- return new AsyncClient(protocolFactory, clientManager, transport);
- }
- }
-
- public AsyncClient(org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.async.TAsyncClientManager clientManager, org.apache.thrift.transport.TNonblockingTransport transport) {
- super(protocolFactory, clientManager, transport);
- }
-
- public void onUpdatePushRoute(protocol_type p_type, String rd, String prefix, int prefixlen, String nexthop, int ethtag, String esi, String macaddress, int l3label, int l2label, String routermac, af_afi afi, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {
- checkReady();
- onUpdatePushRoute_call method_call = new onUpdatePushRoute_call(p_type, rd, prefix, prefixlen, nexthop, ethtag, esi, macaddress, l3label, l2label, routermac, afi, resultHandler, this, ___protocolFactory, ___transport);
- this.___currentMethod = method_call;
- ___manager.call(method_call);
- }
-
- public static class onUpdatePushRoute_call extends org.apache.thrift.async.TAsyncMethodCall {
- private protocol_type p_type;
- private String rd;
- private String prefix;
- private int prefixlen;
- private String nexthop;
- private int ethtag;
- private String esi;
- private String macaddress;
- private int l3label;
- private int l2label;
- private String routermac;
- private af_afi afi;
- public onUpdatePushRoute_call(protocol_type p_type, String rd, String prefix, int prefixlen, String nexthop, int ethtag, String esi, String macaddress, int l3label, int l2label, String routermac, af_afi afi, org.apache.thrift.async.AsyncMethodCallback resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
- super(client, protocolFactory, transport, resultHandler, true);
- this.p_type = p_type;
- this.rd = rd;
- this.prefix = prefix;
- this.prefixlen = prefixlen;
- this.nexthop = nexthop;
- this.ethtag = ethtag;
- this.esi = esi;
- this.macaddress = macaddress;
- this.l3label = l3label;
- this.l2label = l2label;
- this.routermac = routermac;
- this.afi = afi;
- }
-
- public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
- prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("onUpdatePushRoute", org.apache.thrift.protocol.TMessageType.ONEWAY, 0));
- onUpdatePushRoute_args args = new onUpdatePushRoute_args();
- args.setP_type(p_type);
- args.setRd(rd);
- args.setPrefix(prefix);
- args.setPrefixlen(prefixlen);
- args.setNexthop(nexthop);
- args.setEthtag(ethtag);
- args.setEsi(esi);
- args.setMacaddress(macaddress);
- args.setL3label(l3label);
- args.setL2label(l2label);
- args.setRoutermac(routermac);
- args.setAfi(afi);
- args.write(prot);
- prot.writeMessageEnd();
- }
-
- public void getResult() throws org.apache.thrift.TException {
- if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
- throw new IllegalStateException("Method call not finished!");
- }
- org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
- org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
- }
- }
-
- public void onUpdateWithdrawRoute(protocol_type p_type, String rd, String prefix, int prefixlen, String nexthop, int ethtag, String esi, String macaddress, int l3label, int l2label, af_afi afi, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {
- checkReady();
- onUpdateWithdrawRoute_call method_call = new onUpdateWithdrawRoute_call(p_type, rd, prefix, prefixlen, nexthop, ethtag, esi, macaddress, l3label, l2label, afi, resultHandler, this, ___protocolFactory, ___transport);
- this.___currentMethod = method_call;
- ___manager.call(method_call);
- }
-
- public static class onUpdateWithdrawRoute_call extends org.apache.thrift.async.TAsyncMethodCall {
- private protocol_type p_type;
- private String rd;
- private String prefix;
- private int prefixlen;
- private String nexthop;
- private int ethtag;
- private String esi;
- private String macaddress;
- private int l3label;
- private int l2label;
- private af_afi afi;
- public onUpdateWithdrawRoute_call(protocol_type p_type, String rd, String prefix, int prefixlen, String nexthop, int ethtag, String esi, String macaddress, int l3label, int l2label, af_afi afi, org.apache.thrift.async.AsyncMethodCallback resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
- super(client, protocolFactory, transport, resultHandler, true);
- this.p_type = p_type;
- this.rd = rd;
- this.prefix = prefix;
- this.prefixlen = prefixlen;
- this.nexthop = nexthop;
- this.ethtag = ethtag;
- this.esi = esi;
- this.macaddress = macaddress;
- this.l3label = l3label;
- this.l2label = l2label;
- this.afi = afi;
- }
-
- public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
- prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("onUpdateWithdrawRoute", org.apache.thrift.protocol.TMessageType.ONEWAY, 0));
- onUpdateWithdrawRoute_args args = new onUpdateWithdrawRoute_args();
- args.setP_type(p_type);
- args.setRd(rd);
- args.setPrefix(prefix);
- args.setPrefixlen(prefixlen);
- args.setNexthop(nexthop);
- args.setEthtag(ethtag);
- args.setEsi(esi);
- args.setMacaddress(macaddress);
- args.setL3label(l3label);
- args.setL2label(l2label);
- args.setAfi(afi);
- args.write(prot);
- prot.writeMessageEnd();
- }
-
- public void getResult() throws org.apache.thrift.TException {
- if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
- throw new IllegalStateException("Method call not finished!");
- }
- org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
- org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
- }
- }
-
- public void onStartConfigResyncNotification(org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {
- checkReady();
- onStartConfigResyncNotification_call method_call = new onStartConfigResyncNotification_call(resultHandler, this, ___protocolFactory, ___transport);
- this.___currentMethod = method_call;
- ___manager.call(method_call);
- }
-
- public static class onStartConfigResyncNotification_call extends org.apache.thrift.async.TAsyncMethodCall {
- public onStartConfigResyncNotification_call(org.apache.thrift.async.AsyncMethodCallback resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
- super(client, protocolFactory, transport, resultHandler, true);
- }
-
- public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
- prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("onStartConfigResyncNotification", org.apache.thrift.protocol.TMessageType.ONEWAY, 0));
- onStartConfigResyncNotification_args args = new onStartConfigResyncNotification_args();
- args.write(prot);
- prot.writeMessageEnd();
- }
-
- public void getResult() throws org.apache.thrift.TException {
- if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
- throw new IllegalStateException("Method call not finished!");
- }
- org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
- org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
- }
- }
-
- public void onNotificationSendEvent(String prefix, byte errCode, byte errSubcode, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {
- checkReady();
- onNotificationSendEvent_call method_call = new onNotificationSendEvent_call(prefix, errCode, errSubcode, resultHandler, this, ___protocolFactory, ___transport);
- this.___currentMethod = method_call;
- ___manager.call(method_call);
- }
-
- public static class onNotificationSendEvent_call extends org.apache.thrift.async.TAsyncMethodCall {
- private String prefix;
- private byte errCode;
- private byte errSubcode;
- public onNotificationSendEvent_call(String prefix, byte errCode, byte errSubcode, org.apache.thrift.async.AsyncMethodCallback resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
- super(client, protocolFactory, transport, resultHandler, true);
- this.prefix = prefix;
- this.errCode = errCode;
- this.errSubcode = errSubcode;
- }
-
- public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
- prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("onNotificationSendEvent", org.apache.thrift.protocol.TMessageType.ONEWAY, 0));
- onNotificationSendEvent_args args = new onNotificationSendEvent_args();
- args.setPrefix(prefix);
- args.setErrCode(errCode);
- args.setErrSubcode(errSubcode);
- args.write(prot);
- prot.writeMessageEnd();
- }
-
- public void getResult() throws org.apache.thrift.TException {
- if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
- throw new IllegalStateException("Method call not finished!");
- }
- org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
- org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
- }
- }
-
- }
-
- public static class Processor<I extends Iface> extends org.apache.thrift.TBaseProcessor<I> implements org.apache.thrift.TProcessor {
- private static final Logger LOG = LoggerFactory.getLogger(Processor.class.getName());
- public Processor(I iface) {
- super(iface, getProcessMap(new HashMap<String, org.apache.thrift.ProcessFunction<I, ? extends org.apache.thrift.TBase>>()));
- }
-
- protected Processor(I iface, Map<String, org.apache.thrift.ProcessFunction<I, ? extends org.apache.thrift.TBase>> processMap) {
- super(iface, getProcessMap(processMap));
- }
-
- private static <I extends Iface> Map<String, org.apache.thrift.ProcessFunction<I, ? extends org.apache.thrift.TBase>> getProcessMap(Map<String, org.apache.thrift.ProcessFunction<I, ? extends org.apache.thrift.TBase>> processMap) {
- processMap.put("onUpdatePushRoute", new onUpdatePushRoute());
- processMap.put("onUpdateWithdrawRoute", new onUpdateWithdrawRoute());
- processMap.put("onStartConfigResyncNotification", new onStartConfigResyncNotification());
- processMap.put("onNotificationSendEvent", new onNotificationSendEvent());
- return processMap;
- }
-
- public static class onUpdatePushRoute<I extends Iface> extends org.apache.thrift.ProcessFunction<I, onUpdatePushRoute_args> {
- public onUpdatePushRoute() {
- super("onUpdatePushRoute");
- }
-
- public onUpdatePushRoute_args getEmptyArgsInstance() {
- return new onUpdatePushRoute_args();
- }
-
- protected boolean isOneway() {
- return true;
- }
-
- public org.apache.thrift.TBase getResult(I iface, onUpdatePushRoute_args args) throws org.apache.thrift.TException {
- iface.onUpdatePushRoute(args.p_type, args.rd, args.prefix, args.prefixlen, args.nexthop, args.ethtag, args.esi, args.macaddress, args.l3label, args.l2label, args.routermac, args.afi);
- return null;
- }
- }
-
- public static class onUpdateWithdrawRoute<I extends Iface> extends org.apache.thrift.ProcessFunction<I, onUpdateWithdrawRoute_args> {
- public onUpdateWithdrawRoute() {
- super("onUpdateWithdrawRoute");
- }
-
- public onUpdateWithdrawRoute_args getEmptyArgsInstance() {
- return new onUpdateWithdrawRoute_args();
- }
-
- protected boolean isOneway() {
- return true;
- }
-
- public org.apache.thrift.TBase getResult(I iface, onUpdateWithdrawRoute_args args) throws org.apache.thrift.TException {
- iface.onUpdateWithdrawRoute(args.p_type, args.rd, args.prefix, args.prefixlen, args.nexthop, args.ethtag, args.esi, args.macaddress, args.l3label, args.l2label, args.afi);
- return null;
- }
- }
-
- public static class onStartConfigResyncNotification<I extends Iface> extends org.apache.thrift.ProcessFunction<I, onStartConfigResyncNotification_args> {
- public onStartConfigResyncNotification() {
- super("onStartConfigResyncNotification");
- }
-
- public onStartConfigResyncNotification_args getEmptyArgsInstance() {
- return new onStartConfigResyncNotification_args();
- }
-
- protected boolean isOneway() {
- return true;
- }
-
- public org.apache.thrift.TBase getResult(I iface, onStartConfigResyncNotification_args args) throws org.apache.thrift.TException {
- iface.onStartConfigResyncNotification();
- return null;
- }
- }
-
- public static class onNotificationSendEvent<I extends Iface> extends org.apache.thrift.ProcessFunction<I, onNotificationSendEvent_args> {
- public onNotificationSendEvent() {
- super("onNotificationSendEvent");
- }
-
- public onNotificationSendEvent_args getEmptyArgsInstance() {
- return new onNotificationSendEvent_args();
- }
-
- protected boolean isOneway() {
- return true;
- }
-
- public org.apache.thrift.TBase getResult(I iface, onNotificationSendEvent_args args) throws org.apache.thrift.TException {
- iface.onNotificationSendEvent(args.prefix, args.errCode, args.errSubcode);
- return null;
- }
- }
-
- }
-
- public static class AsyncProcessor<I extends AsyncIface> extends org.apache.thrift.TBaseAsyncProcessor<I> {
- private static final Logger LOG = LoggerFactory.getLogger(AsyncProcessor.class.getName());
- public AsyncProcessor(I iface) {
- super(iface, getProcessMap(new HashMap<String, org.apache.thrift.AsyncProcessFunction<I, ? extends org.apache.thrift.TBase, ?>>()));
- }
-
- protected AsyncProcessor(I iface, Map<String, org.apache.thrift.AsyncProcessFunction<I, ? extends org.apache.thrift.TBase, ?>> processMap) {
- super(iface, getProcessMap(processMap));
- }
-
- private static <I extends AsyncIface> Map<String, org.apache.thrift.AsyncProcessFunction<I, ? extends org.apache.thrift.TBase,?>> getProcessMap(Map<String, org.apache.thrift.AsyncProcessFunction<I, ? extends org.apache.thrift.TBase, ?>> processMap) {
- processMap.put("onUpdatePushRoute", new onUpdatePushRoute());
- processMap.put("onUpdateWithdrawRoute", new onUpdateWithdrawRoute());
- processMap.put("onStartConfigResyncNotification", new onStartConfigResyncNotification());
- processMap.put("onNotificationSendEvent", new onNotificationSendEvent());
- return processMap;
- }
-
- public static class onUpdatePushRoute<I extends AsyncIface> extends org.apache.thrift.AsyncProcessFunction<I, onUpdatePushRoute_args, Void> {
- public onUpdatePushRoute() {
- super("onUpdatePushRoute");
- }
-
- public onUpdatePushRoute_args getEmptyArgsInstance() {
- return new onUpdatePushRoute_args();
- }
-
- public AsyncMethodCallback<Void> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
- final org.apache.thrift.AsyncProcessFunction fcall = this;
- return new AsyncMethodCallback<Void>() {
- public void onComplete(Void o) {
- }
- public void onError(Exception e) {
- }
- };
- }
-
- protected boolean isOneway() {
- return true;
- }
-
- public void start(I iface, onUpdatePushRoute_args args, org.apache.thrift.async.AsyncMethodCallback<Void> resultHandler) throws TException {
- iface.onUpdatePushRoute(args.p_type, args.rd, args.prefix, args.prefixlen, args.nexthop, args.ethtag, args.esi, args.macaddress, args.l3label, args.l2label, args.routermac, args.afi,resultHandler);
- }
- }
-
- public static class onUpdateWithdrawRoute<I extends AsyncIface> extends org.apache.thrift.AsyncProcessFunction<I, onUpdateWithdrawRoute_args, Void> {
- public onUpdateWithdrawRoute() {
- super("onUpdateWithdrawRoute");
- }
-
- public onUpdateWithdrawRoute_args getEmptyArgsInstance() {
- return new onUpdateWithdrawRoute_args();
- }
-
- public AsyncMethodCallback<Void> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
- final org.apache.thrift.AsyncProcessFunction fcall = this;
- return new AsyncMethodCallback<Void>() {
- public void onComplete(Void o) {
- }
- public void onError(Exception e) {
- }
- };
- }
-
- protected boolean isOneway() {
- return true;
- }
-
- public void start(I iface, onUpdateWithdrawRoute_args args, org.apache.thrift.async.AsyncMethodCallback<Void> resultHandler) throws TException {
- iface.onUpdateWithdrawRoute(args.p_type, args.rd, args.prefix, args.prefixlen, args.nexthop, args.ethtag, args.esi, args.macaddress, args.l3label, args.l2label, args.afi,resultHandler);
- }
- }
-
- public static class onStartConfigResyncNotification<I extends AsyncIface> extends org.apache.thrift.AsyncProcessFunction<I, onStartConfigResyncNotification_args, Void> {
- public onStartConfigResyncNotification() {
- super("onStartConfigResyncNotification");
- }
-
- public onStartConfigResyncNotification_args getEmptyArgsInstance() {
- return new onStartConfigResyncNotification_args();
- }
-
- public AsyncMethodCallback<Void> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
- final org.apache.thrift.AsyncProcessFunction fcall = this;
- return new AsyncMethodCallback<Void>() {
- public void onComplete(Void o) {
- }
- public void onError(Exception e) {
- }
- };
- }
-
- protected boolean isOneway() {
- return true;
- }
-
- public void start(I iface, onStartConfigResyncNotification_args args, org.apache.thrift.async.AsyncMethodCallback<Void> resultHandler) throws TException {
- iface.onStartConfigResyncNotification(resultHandler);
- }
- }
-
- public static class onNotificationSendEvent<I extends AsyncIface> extends org.apache.thrift.AsyncProcessFunction<I, onNotificationSendEvent_args, Void> {
- public onNotificationSendEvent() {
- super("onNotificationSendEvent");
- }
-
- public onNotificationSendEvent_args getEmptyArgsInstance() {
- return new onNotificationSendEvent_args();
- }
-
- public AsyncMethodCallback<Void> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
- final org.apache.thrift.AsyncProcessFunction fcall = this;
- return new AsyncMethodCallback<Void>() {
- public void onComplete(Void o) {
- }
- public void onError(Exception e) {
- }
- };
- }
-
- protected boolean isOneway() {
- return true;
- }
-
- public void start(I iface, onNotificationSendEvent_args args, org.apache.thrift.async.AsyncMethodCallback<Void> resultHandler) throws TException {
- iface.onNotificationSendEvent(args.prefix, args.errCode, args.errSubcode,resultHandler);
- }
- }
-
- }
-
- public static class onUpdatePushRoute_args implements org.apache.thrift.TBase<onUpdatePushRoute_args, onUpdatePushRoute_args._Fields>, java.io.Serializable, Cloneable, Comparable<onUpdatePushRoute_args> {
- private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("onUpdatePushRoute_args");
-
- private static final org.apache.thrift.protocol.TField P_TYPE_FIELD_DESC = new org.apache.thrift.protocol.TField("p_type", org.apache.thrift.protocol.TType.I32, (short)1);
- private static final org.apache.thrift.protocol.TField RD_FIELD_DESC = new org.apache.thrift.protocol.TField("rd", org.apache.thrift.protocol.TType.STRING, (short)2);
- private static final org.apache.thrift.protocol.TField PREFIX_FIELD_DESC = new org.apache.thrift.protocol.TField("prefix", org.apache.thrift.protocol.TType.STRING, (short)3);
- private static final org.apache.thrift.protocol.TField PREFIXLEN_FIELD_DESC = new org.apache.thrift.protocol.TField("prefixlen", org.apache.thrift.protocol.TType.I32, (short)4);
- private static final org.apache.thrift.protocol.TField NEXTHOP_FIELD_DESC = new org.apache.thrift.protocol.TField("nexthop", org.apache.thrift.protocol.TType.STRING, (short)5);
- private static final org.apache.thrift.protocol.TField ETHTAG_FIELD_DESC = new org.apache.thrift.protocol.TField("ethtag", org.apache.thrift.protocol.TType.I32, (short)6);
- private static final org.apache.thrift.protocol.TField ESI_FIELD_DESC = new org.apache.thrift.protocol.TField("esi", org.apache.thrift.protocol.TType.STRING, (short)7);
- private static final org.apache.thrift.protocol.TField MACADDRESS_FIELD_DESC = new org.apache.thrift.protocol.TField("macaddress", org.apache.thrift.protocol.TType.STRING, (short)8);
- private static final org.apache.thrift.protocol.TField L3LABEL_FIELD_DESC = new org.apache.thrift.protocol.TField("l3label", org.apache.thrift.protocol.TType.I32, (short)9);
- private static final org.apache.thrift.protocol.TField L2LABEL_FIELD_DESC = new org.apache.thrift.protocol.TField("l2label", org.apache.thrift.protocol.TType.I32, (short)10);
- private static final org.apache.thrift.protocol.TField ROUTERMAC_FIELD_DESC = new org.apache.thrift.protocol.TField("routermac", org.apache.thrift.protocol.TType.STRING, (short)11);
- private static final org.apache.thrift.protocol.TField AFI_FIELD_DESC = new org.apache.thrift.protocol.TField("afi", org.apache.thrift.protocol.TType.I32, (short)12);
-
- private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
- static {
- schemes.put(StandardScheme.class, new onUpdatePushRoute_argsStandardSchemeFactory());
- schemes.put(TupleScheme.class, new onUpdatePushRoute_argsTupleSchemeFactory());
- }
-
- /**
- *
- * @see protocol_type
- */
- public protocol_type p_type; // required
- public String rd; // required
- public String prefix; // required
- public int prefixlen; // required
- public String nexthop; // required
- public int ethtag; // required
- public String esi; // required
- public String macaddress; // required
- public int l3label; // required
- public int l2label; // required
- public String routermac; // required
- /**
- *
- * @see af_afi
- */
- public af_afi afi; // required
-
- /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
- public enum _Fields implements org.apache.thrift.TFieldIdEnum {
- /**
- *
- * @see protocol_type
- */
- P_TYPE((short)1, "p_type"),
- RD((short)2, "rd"),
- PREFIX((short)3, "prefix"),
- PREFIXLEN((short)4, "prefixlen"),
- NEXTHOP((short)5, "nexthop"),
- ETHTAG((short)6, "ethtag"),
- ESI((short)7, "esi"),
- MACADDRESS((short)8, "macaddress"),
- L3LABEL((short)9, "l3label"),
- L2LABEL((short)10, "l2label"),
- ROUTERMAC((short)11, "routermac"),
- /**
- *
- * @see af_afi
- */
- AFI((short)12, "afi");
-
- private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
-
- static {
- for (_Fields field : EnumSet.allOf(_Fields.class)) {
- byName.put(field.getFieldName(), field);
- }
- }
-
- /**
- * Find the _Fields constant that matches fieldId, or null if its not found.
- */
- public static _Fields findByThriftId(int fieldId) {
- switch(fieldId) {
- case 1: // P_TYPE
- return P_TYPE;
- case 2: // RD
- return RD;
- case 3: // PREFIX
- return PREFIX;
- case 4: // PREFIXLEN
- return PREFIXLEN;
- case 5: // NEXTHOP
- return NEXTHOP;
- case 6: // ETHTAG
- return ETHTAG;
- case 7: // ESI
- return ESI;
- case 8: // MACADDRESS
- return MACADDRESS;
- case 9: // L3LABEL
- return L3LABEL;
- case 10: // L2LABEL
- return L2LABEL;
- case 11: // ROUTERMAC
- return ROUTERMAC;
- case 12: // AFI
- return AFI;
- default:
- return null;
- }
- }
-
- /**
- * Find the _Fields constant that matches fieldId, throwing an exception
- * if it is not found.
- */
- public static _Fields findByThriftIdOrThrow(int fieldId) {
- _Fields fields = findByThriftId(fieldId);
- if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
- return fields;
- }
-
- /**
- * Find the _Fields constant that matches name, or null if its not found.
- */
- public static _Fields findByName(String name) {
- return byName.get(name);
- }
-
- private final short _thriftId;
- private final String _fieldName;
-
- _Fields(short thriftId, String fieldName) {
- _thriftId = thriftId;
- _fieldName = fieldName;
- }
-
- public short getThriftFieldId() {
- return _thriftId;
- }
-
- public String getFieldName() {
- return _fieldName;
- }
- }
-
- // isset id assignments
- private static final int __PREFIXLEN_ISSET_ID = 0;
- private static final int __ETHTAG_ISSET_ID = 1;
- private static final int __L3LABEL_ISSET_ID = 2;
- private static final int __L2LABEL_ISSET_ID = 3;
- private byte __isset_bitfield = 0;
- public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
- static {
- Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
- tmpMap.put(_Fields.P_TYPE, new org.apache.thrift.meta_data.FieldMetaData("p_type", org.apache.thrift.TFieldRequirementType.DEFAULT,
- new org.apache.thrift.meta_data.EnumMetaData(org.apache.thrift.protocol.TType.ENUM, protocol_type.class)));
- tmpMap.put(_Fields.RD, new org.apache.thrift.meta_data.FieldMetaData("rd", org.apache.thrift.TFieldRequirementType.DEFAULT,
- new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
- tmpMap.put(_Fields.PREFIX, new org.apache.thrift.meta_data.FieldMetaData("prefix", org.apache.thrift.TFieldRequirementType.DEFAULT,
- new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
- tmpMap.put(_Fields.PREFIXLEN, new org.apache.thrift.meta_data.FieldMetaData("prefixlen", org.apache.thrift.TFieldRequirementType.DEFAULT,
- new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I32)));
- tmpMap.put(_Fields.NEXTHOP, new org.apache.thrift.meta_data.FieldMetaData("nexthop", org.apache.thrift.TFieldRequirementType.DEFAULT,
- new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
- tmpMap.put(_Fields.ETHTAG, new org.apache.thrift.meta_data.FieldMetaData("ethtag", org.apache.thrift.TFieldRequirementType.DEFAULT,
- new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I32)));
- tmpMap.put(_Fields.ESI, new org.apache.thrift.meta_data.FieldMetaData("esi", org.apache.thrift.TFieldRequirementType.DEFAULT,
- new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
- tmpMap.put(_Fields.MACADDRESS, new org.apache.thrift.meta_data.FieldMetaData("macaddress", org.apache.thrift.TFieldRequirementType.DEFAULT,
- new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
- tmpMap.put(_Fields.L3LABEL, new org.apache.thrift.meta_data.FieldMetaData("l3label", org.apache.thrift.TFieldRequirementType.DEFAULT,
- new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I32)));
- tmpMap.put(_Fields.L2LABEL, new org.apache.thrift.meta_data.FieldMetaData("l2label", org.apache.thrift.TFieldRequirementType.DEFAULT,
- new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I32)));
- tmpMap.put(_Fields.ROUTERMAC, new org.apache.thrift.meta_data.FieldMetaData("routermac", org.apache.thrift.TFieldRequirementType.DEFAULT,
- new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
- tmpMap.put(_Fields.AFI, new org.apache.thrift.meta_data.FieldMetaData("afi", org.apache.thrift.TFieldRequirementType.DEFAULT,
- new org.apache.thrift.meta_data.EnumMetaData(org.apache.thrift.protocol.TType.ENUM, af_afi.class)));
- metaDataMap = Collections.unmodifiableMap(tmpMap);
- org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(onUpdatePushRoute_args.class, metaDataMap);
- }
-
- public onUpdatePushRoute_args() {
- }
-
- public onUpdatePushRoute_args(
- protocol_type p_type,
- String rd,
- String prefix,
- int prefixlen,
- String nexthop,
- int ethtag,
- String esi,
- String macaddress,
- int l3label,
- int l2label,
- String routermac,
- af_afi afi)
- {
- this();
- this.p_type = p_type;
- this.rd = rd;
- this.prefix = prefix;
- this.prefixlen = prefixlen;
- setPrefixlenIsSet(true);
- this.nexthop = nexthop;
- this.ethtag = ethtag;
- setEthtagIsSet(true);
- this.esi = esi;
- this.macaddress = macaddress;
- this.l3label = l3label;
- setL3labelIsSet(true);
- this.l2label = l2label;
- setL2labelIsSet(true);
- this.routermac = routermac;
- this.afi = afi;
- }
-
- /**
- * Performs a deep copy on <i>other</i>.
- */
- public onUpdatePushRoute_args(onUpdatePushRoute_args other) {
- __isset_bitfield = other.__isset_bitfield;
- if (other.isSetP_type()) {
- this.p_type = other.p_type;
- }
- if (other.isSetRd()) {
- this.rd = other.rd;
- }
- if (other.isSetPrefix()) {
- this.prefix = other.prefix;
- }
- this.prefixlen = other.prefixlen;
- if (other.isSetNexthop()) {
- this.nexthop = other.nexthop;
- }
- this.ethtag = other.ethtag;
- if (other.isSetEsi()) {
- this.esi = other.esi;
- }
- if (other.isSetMacaddress()) {
- this.macaddress = other.macaddress;
- }
- this.l3label = other.l3label;
- this.l2label = other.l2label;
- if (other.isSetRoutermac()) {
- this.routermac = other.routermac;
- }
- if (other.isSetAfi()) {
- this.afi = other.afi;
- }
- }
-
- public onUpdatePushRoute_args deepCopy() {
- return new onUpdatePushRoute_args(this);
- }
-
- @Override
- public void clear() {
- this.p_type = null;
- this.rd = null;
- this.prefix = null;
- setPrefixlenIsSet(false);
- this.prefixlen = 0;
- this.nexthop = null;
- setEthtagIsSet(false);
- this.ethtag = 0;
- this.esi = null;
- this.macaddress = null;
- setL3labelIsSet(false);
- this.l3label = 0;
- setL2labelIsSet(false);
- this.l2label = 0;
- this.routermac = null;
- this.afi = null;
- }
-
- /**
- *
- * @see protocol_type
- */
- public protocol_type getP_type() {
- return this.p_type;
- }
-
- /**
- *
- * @see protocol_type
- */
- public onUpdatePushRoute_args setP_type(protocol_type p_type) {
- this.p_type = p_type;
- return this;
- }
-
- public void unsetP_type() {
- this.p_type = null;
- }
-
- /** Returns true if field p_type is set (has been assigned a value) and false otherwise */
- public boolean isSetP_type() {
- return this.p_type != null;
- }
-
- public void setP_typeIsSet(boolean value) {
- if (!value) {
- this.p_type = null;
- }
- }
-
- public String getRd() {
- return this.rd;
- }
-
- public onUpdatePushRoute_args setRd(String rd) {
- this.rd = rd;
- return this;
- }
-
- public void unsetRd() {
- this.rd = null;
- }
-
- /** Returns true if field rd is set (has been assigned a value) and false otherwise */
- public boolean isSetRd() {
- return this.rd != null;
- }
-
- public void setRdIsSet(boolean value) {
- if (!value) {
- this.rd = null;
- }
- }
-
- public String getPrefix() {
- return this.prefix;
- }
-
- public onUpdatePushRoute_args setPrefix(String prefix) {
- this.prefix = prefix;
- return this;
- }
-
- public void unsetPrefix() {
- this.prefix = null;
- }
-
- /** Returns true if field prefix is set (has been assigned a value) and false otherwise */
- public boolean isSetPrefix() {
- return this.prefix != null;
- }
-
- public void setPrefixIsSet(boolean value) {
- if (!value) {
- this.prefix = null;
- }
- }
-
- public int getPrefixlen() {
- return this.prefixlen;
- }
-
- public onUpdatePushRoute_args setPrefixlen(int prefixlen) {
- this.prefixlen = prefixlen;
- setPrefixlenIsSet(true);
- return this;
- }
-
- public void unsetPrefixlen() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __PREFIXLEN_ISSET_ID);
- }
-
- /** Returns true if field prefixlen is set (has been assigned a value) and false otherwise */
- public boolean isSetPrefixlen() {
- return EncodingUtils.testBit(__isset_bitfield, __PREFIXLEN_ISSET_ID);
- }
-
- public void setPrefixlenIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __PREFIXLEN_ISSET_ID, value);
- }
-
- public String getNexthop() {
- return this.nexthop;
- }
-
- public onUpdatePushRoute_args setNexthop(String nexthop) {
- this.nexthop = nexthop;
- return this;
- }
-
- public void unsetNexthop() {
- this.nexthop = null;
- }
-
- /** Returns true if field nexthop is set (has been assigned a value) and false otherwise */
- public boolean isSetNexthop() {
- return this.nexthop != null;
- }
-
- public void setNexthopIsSet(boolean value) {
- if (!value) {
- this.nexthop = null;
- }
- }
-
- public int getEthtag() {
- return this.ethtag;
- }
-
- public onUpdatePushRoute_args setEthtag(int ethtag) {
- this.ethtag = ethtag;
- setEthtagIsSet(true);
- return this;
- }
-
- public void unsetEthtag() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __ETHTAG_ISSET_ID);
- }
-
- /** Returns true if field ethtag is set (has been assigned a value) and false otherwise */
- public boolean isSetEthtag() {
- return EncodingUtils.testBit(__isset_bitfield, __ETHTAG_ISSET_ID);
- }
-
- public void setEthtagIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __ETHTAG_ISSET_ID, value);
- }
-
- public String getEsi() {
- return this.esi;
- }
-
- public onUpdatePushRoute_args setEsi(String esi) {
- this.esi = esi;
- return this;
- }
-
- public void unsetEsi() {
- this.esi = null;
- }
-
- /** Returns true if field esi is set (has been assigned a value) and false otherwise */
- public boolean isSetEsi() {
- return this.esi != null;
- }
-
- public void setEsiIsSet(boolean value) {
- if (!value) {
- this.esi = null;
- }
- }
-
- public String getMacaddress() {
- return this.macaddress;
- }
-
- public onUpdatePushRoute_args setMacaddress(String macaddress) {
- this.macaddress = macaddress;
- return this;
- }
-
- public void unsetMacaddress() {
- this.macaddress = null;
- }
-
- /** Returns true if field macaddress is set (has been assigned a value) and false otherwise */
- public boolean isSetMacaddress() {
- return this.macaddress != null;
- }
-
- public void setMacaddressIsSet(boolean value) {
- if (!value) {
- this.macaddress = null;
- }
- }
-
- public int getL3label() {
- return this.l3label;
- }
-
- public onUpdatePushRoute_args setL3label(int l3label) {
- this.l3label = l3label;
- setL3labelIsSet(true);
- return this;
- }
-
- public void unsetL3label() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __L3LABEL_ISSET_ID);
- }
-
- /** Returns true if field l3label is set (has been assigned a value) and false otherwise */
- public boolean isSetL3label() {
- return EncodingUtils.testBit(__isset_bitfield, __L3LABEL_ISSET_ID);
- }
-
- public void setL3labelIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __L3LABEL_ISSET_ID, value);
- }
-
- public int getL2label() {
- return this.l2label;
- }
-
- public onUpdatePushRoute_args setL2label(int l2label) {
- this.l2label = l2label;
- setL2labelIsSet(true);
- return this;
- }
-
- public void unsetL2label() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __L2LABEL_ISSET_ID);
- }
-
- /** Returns true if field l2label is set (has been assigned a value) and false otherwise */
- public boolean isSetL2label() {
- return EncodingUtils.testBit(__isset_bitfield, __L2LABEL_ISSET_ID);
- }
-
- public void setL2labelIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __L2LABEL_ISSET_ID, value);
- }
-
- public String getRoutermac() {
- return this.routermac;
- }
-
- public onUpdatePushRoute_args setRoutermac(String routermac) {
- this.routermac = routermac;
- return this;
- }
-
- public void unsetRoutermac() {
- this.routermac = null;
- }
-
- /** Returns true if field routermac is set (has been assigned a value) and false otherwise */
- public boolean isSetRoutermac() {
- return this.routermac != null;
- }
-
- public void setRoutermacIsSet(boolean value) {
- if (!value) {
- this.routermac = null;
- }
- }
-
- /**
- *
- * @see af_afi
- */
- public af_afi getAfi() {
- return this.afi;
- }
-
- /**
- *
- * @see af_afi
- */
- public onUpdatePushRoute_args setAfi(af_afi afi) {
- this.afi = afi;
- return this;
- }
-
- public void unsetAfi() {
- this.afi = null;
- }
-
- /** Returns true if field afi is set (has been assigned a value) and false otherwise */
- public boolean isSetAfi() {
- return this.afi != null;
- }
-
- public void setAfiIsSet(boolean value) {
- if (!value) {
- this.afi = null;
- }
- }
-
- public void setFieldValue(_Fields field, Object value) {
- switch (field) {
- case P_TYPE:
- if (value == null) {
- unsetP_type();
- } else {
- setP_type((protocol_type)value);
- }
- break;
-
- case RD:
- if (value == null) {
- unsetRd();
- } else {
- setRd((String)value);
- }
- break;
-
- case PREFIX:
- if (value == null) {
- unsetPrefix();
- } else {
- setPrefix((String)value);
- }
- break;
-
- case PREFIXLEN:
- if (value == null) {
- unsetPrefixlen();
- } else {
- setPrefixlen((Integer)value);
- }
- break;
-
- case NEXTHOP:
- if (value == null) {
- unsetNexthop();
- } else {
- setNexthop((String)value);
- }
- break;
-
- case ETHTAG:
- if (value == null) {
- unsetEthtag();
- } else {
- setEthtag((Integer)value);
- }
- break;
-
- case ESI:
- if (value == null) {
- unsetEsi();
- } else {
- setEsi((String)value);
- }
- break;
-
- case MACADDRESS:
- if (value == null) {
- unsetMacaddress();
- } else {
- setMacaddress((String)value);
- }
- break;
-
- case L3LABEL:
- if (value == null) {
- unsetL3label();
- } else {
- setL3label((Integer)value);
- }
- break;
-
- case L2LABEL:
- if (value == null) {
- unsetL2label();
- } else {
- setL2label((Integer)value);
- }
- break;
-
- case ROUTERMAC:
- if (value == null) {
- unsetRoutermac();
- } else {
- setRoutermac((String)value);
- }
- break;
-
- case AFI:
- if (value == null) {
- unsetAfi();
- } else {
- setAfi((af_afi)value);
- }
- break;
-
- }
- }
-
- public Object getFieldValue(_Fields field) {
- switch (field) {
- case P_TYPE:
- return getP_type();
-
- case RD:
- return getRd();
-
- case PREFIX:
- return getPrefix();
-
- case PREFIXLEN:
- return Integer.valueOf(getPrefixlen());
-
- case NEXTHOP:
- return getNexthop();
-
- case ETHTAG:
- return Integer.valueOf(getEthtag());
-
- case ESI:
- return getEsi();
-
- case MACADDRESS:
- return getMacaddress();
-
- case L3LABEL:
- return Integer.valueOf(getL3label());
-
- case L2LABEL:
- return Integer.valueOf(getL2label());
-
- case ROUTERMAC:
- return getRoutermac();
-
- case AFI:
- return getAfi();
-
- }
- throw new IllegalStateException();
- }
-
- /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
- public boolean isSet(_Fields field) {
- if (field == null) {
- throw new IllegalArgumentException();
- }
-
- switch (field) {
- case P_TYPE:
- return isSetP_type();
- case RD:
- return isSetRd();
- case PREFIX:
- return isSetPrefix();
- case PREFIXLEN:
- return isSetPrefixlen();
- case NEXTHOP:
- return isSetNexthop();
- case ETHTAG:
- return isSetEthtag();
- case ESI:
- return isSetEsi();
- case MACADDRESS:
- return isSetMacaddress();
- case L3LABEL:
- return isSetL3label();
- case L2LABEL:
- return isSetL2label();
- case ROUTERMAC:
- return isSetRoutermac();
- case AFI:
- return isSetAfi();
- }
- throw new IllegalStateException();
- }
-
- @Override
- public boolean equals(Object that) {
- if (that == null)
- return false;
- if (that instanceof onUpdatePushRoute_args)
- return this.equals((onUpdatePushRoute_args)that);
- return false;
- }
-
- public boolean equals(onUpdatePushRoute_args that) {
- if (that == null)
- return false;
-
- boolean this_present_p_type = true && this.isSetP_type();
- boolean that_present_p_type = true && that.isSetP_type();
- if (this_present_p_type || that_present_p_type) {
- if (!(this_present_p_type && that_present_p_type))
- return false;
- if (!this.p_type.equals(that.p_type))
- return false;
- }
-
- boolean this_present_rd = true && this.isSetRd();
- boolean that_present_rd = true && that.isSetRd();
- if (this_present_rd || that_present_rd) {
- if (!(this_present_rd && that_present_rd))
- return false;
- if (!this.rd.equals(that.rd))
- return false;
- }
-
- boolean this_present_prefix = true && this.isSetPrefix();
- boolean that_present_prefix = true && that.isSetPrefix();
- if (this_present_prefix || that_present_prefix) {
- if (!(this_present_prefix && that_present_prefix))
- return false;
- if (!this.prefix.equals(that.prefix))
- return false;
- }
-
- boolean this_present_prefixlen = true;
- boolean that_present_prefixlen = true;
- if (this_present_prefixlen || that_present_prefixlen) {
- if (!(this_present_prefixlen && that_present_prefixlen))
- return false;
- if (this.prefixlen != that.prefixlen)
- return false;
- }
-
- boolean this_present_nexthop = true && this.isSetNexthop();
- boolean that_present_nexthop = true && that.isSetNexthop();
- if (this_present_nexthop || that_present_nexthop) {
- if (!(this_present_nexthop && that_present_nexthop))
- return false;
- if (!this.nexthop.equals(that.nexthop))
- return false;
- }
-
- boolean this_present_ethtag = true;
- boolean that_present_ethtag = true;
- if (this_present_ethtag || that_present_ethtag) {
- if (!(this_present_ethtag && that_present_ethtag))
- return false;
- if (this.ethtag != that.ethtag)
- return false;
- }
-
- boolean this_present_esi = true && this.isSetEsi();
- boolean that_present_esi = true && that.isSetEsi();
- if (this_present_esi || that_present_esi) {
- if (!(this_present_esi && that_present_esi))
- return false;
- if (!this.esi.equals(that.esi))
- return false;
- }
-
- boolean this_present_macaddress = true && this.isSetMacaddress();
- boolean that_present_macaddress = true && that.isSetMacaddress();
- if (this_present_macaddress || that_present_macaddress) {
- if (!(this_present_macaddress && that_present_macaddress))
- return false;
- if (!this.macaddress.equals(that.macaddress))
- return false;
- }
-
- boolean this_present_l3label = true;
- boolean that_present_l3label = true;
- if (this_present_l3label || that_present_l3label) {
- if (!(this_present_l3label && that_present_l3label))
- return false;
- if (this.l3label != that.l3label)
- return false;
- }
-
- boolean this_present_l2label = true;
- boolean that_present_l2label = true;
- if (this_present_l2label || that_present_l2label) {
- if (!(this_present_l2label && that_present_l2label))
- return false;
- if (this.l2label != that.l2label)
- return false;
- }
-
- boolean this_present_routermac = true && this.isSetRoutermac();
- boolean that_present_routermac = true && that.isSetRoutermac();
- if (this_present_routermac || that_present_routermac) {
- if (!(this_present_routermac && that_present_routermac))
- return false;
- if (!this.routermac.equals(that.routermac))
- return false;
- }
-
- boolean this_present_afi = true && this.isSetAfi();
- boolean that_present_afi = true && that.isSetAfi();
- if (this_present_afi || that_present_afi) {
- if (!(this_present_afi && that_present_afi))
- return false;
- if (!this.afi.equals(that.afi))
- return false;
- }
-
- return true;
- }
-
- @Override
- public int hashCode() {
- List<Object> list = new ArrayList<Object>();
- boolean present_p_type = true && (isSetP_type());
- list.add(present_p_type);
- if (present_p_type)
- list.add(p_type.getValue());
- boolean present_rd = true && (isSetRd());
- list.add(present_rd);
- if (present_rd)
- list.add(rd);
- boolean present_prefix = true && (isSetPrefix());
- list.add(present_prefix);
- if (present_prefix)
- list.add(prefix);
- boolean present_prefixlen = true;
- list.add(present_prefixlen);
- if (present_prefixlen)
- list.add(prefixlen);
- boolean present_nexthop = true && (isSetNexthop());
- list.add(present_nexthop);
- if (present_nexthop)
- list.add(nexthop);
- boolean present_ethtag = true;
- list.add(present_ethtag);
- if (present_ethtag)
- list.add(ethtag);
- boolean present_esi = true && (isSetEsi());
- list.add(present_esi);
- if (present_esi)
- list.add(esi);
- boolean present_macaddress = true && (isSetMacaddress());
- list.add(present_macaddress);
- if (present_macaddress)
- list.add(macaddress);
- boolean present_l3label = true;
- list.add(present_l3label);
- if (present_l3label)
- list.add(l3label);
- boolean present_l2label = true;
- list.add(present_l2label);
- if (present_l2label)
- list.add(l2label);
- boolean present_routermac = true && (isSetRoutermac());
- list.add(present_routermac);
- if (present_routermac)
- list.add(routermac);
- boolean present_afi = true && (isSetAfi());
- list.add(present_afi);
- if (present_afi)
- list.add(afi.getValue());
- return list.hashCode();
- }
-
- @Override
- public int compareTo(onUpdatePushRoute_args other) {
- if (!getClass().equals(other.getClass())) {
- return getClass().getName().compareTo(other.getClass().getName());
- }
-
- int lastComparison = 0;
-
- lastComparison = Boolean.valueOf(isSetP_type()).compareTo(other.isSetP_type());
- if (lastComparison != 0) {
- return lastComparison;
- }
- if (isSetP_type()) {
- lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.p_type, other.p_type);
- if (lastComparison != 0) {
- return lastComparison;
- }
- }
- lastComparison = Boolean.valueOf(isSetRd()).compareTo(other.isSetRd());
- if (lastComparison != 0) {
- return lastComparison;
- }
- if (isSetRd()) {
- lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.rd, other.rd);
- if (lastComparison != 0) {
- return lastComparison;
- }
- }
- lastComparison = Boolean.valueOf(isSetPrefix()).compareTo(other.isSetPrefix());
- if (lastComparison != 0) {
- return lastComparison;
- }
- if (isSetPrefix()) {
- lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.prefix, other.prefix);
- if (lastComparison != 0) {
- return lastComparison;
- }
- }
- lastComparison = Boolean.valueOf(isSetPrefixlen()).compareTo(other.isSetPrefixlen());
- if (lastComparison != 0) {
- return lastComparison;
- }
- if (isSetPrefixlen()) {
- lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.prefixlen, other.prefixlen);
- if (lastComparison != 0) {
- return lastComparison;
- }
- }
- lastComparison = Boolean.valueOf(isSetNexthop()).compareTo(other.isSetNexthop());
- if (lastComparison != 0) {
- return lastComparison;
- }
- if (isSetNexthop()) {
- lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.nexthop, other.nexthop);
- if (lastComparison != 0) {
- return lastComparison;
- }
- }
- lastComparison = Boolean.valueOf(isSetEthtag()).compareTo(other.isSetEthtag());
- if (lastComparison != 0) {
- return lastComparison;
- }
- if (isSetEthtag()) {
- lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.ethtag, other.ethtag);
- if (lastComparison != 0) {
- return lastComparison;
- }
- }
- lastComparison = Boolean.valueOf(isSetEsi()).compareTo(other.isSetEsi());
- if (lastComparison != 0) {
- return lastComparison;
- }
- if (isSetEsi()) {
- lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.esi, other.esi);
- if (lastComparison != 0) {
- return lastComparison;
- }
- }
- lastComparison = Boolean.valueOf(isSetMacaddress()).compareTo(other.isSetMacaddress());
- if (lastComparison != 0) {
- return lastComparison;
- }
- if (isSetMacaddress()) {
- lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.macaddress, other.macaddress);
- if (lastComparison != 0) {
- return lastComparison;
- }
- }
- lastComparison = Boolean.valueOf(isSetL3label()).compareTo(other.isSetL3label());
- if (lastComparison != 0) {
- return lastComparison;
- }
- if (isSetL3label()) {
- lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.l3label, other.l3label);
- if (lastComparison != 0) {
- return lastComparison;
- }
- }
- lastComparison = Boolean.valueOf(isSetL2label()).compareTo(other.isSetL2label());
- if (lastComparison != 0) {
- return lastComparison;
- }
- if (isSetL2label()) {
- lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.l2label, other.l2label);
- if (lastComparison != 0) {
- return lastComparison;
- }
- }
- lastComparison = Boolean.valueOf(isSetRoutermac()).compareTo(other.isSetRoutermac());
- if (lastComparison != 0) {
- return lastComparison;
- }
- if (isSetRoutermac()) {
- lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.routermac, other.routermac);
- if (lastComparison != 0) {
- return lastComparison;
- }
- }
- lastComparison = Boolean.valueOf(isSetAfi()).compareTo(other.isSetAfi());
- if (lastComparison != 0) {
- return lastComparison;
- }
- if (isSetAfi()) {
- lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.afi, other.afi);
- if (lastComparison != 0) {
- return lastComparison;
- }
- }
- return 0;
- }
-
- public _Fields fieldForId(int fieldId) {
- return _Fields.findByThriftId(fieldId);
- }
-
- public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
- schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
- }
-
- public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
- schemes.get(oprot.getScheme()).getScheme().write(oprot, this);
- }
-
- @Override
- public String toString() {
- StringBuilder sb = new StringBuilder("onUpdatePushRoute_args(");
- boolean first = true;
-
- sb.append("p_type:");
- if (this.p_type == null) {
- sb.append("null");
- } else {
- sb.append(this.p_type);
- }
- first = false;
- if (!first) sb.append(", ");
- sb.append("rd:");
- if (this.rd == null) {
- sb.append("null");
- } else {
- sb.append(this.rd);
- }
- first = false;
- if (!first) sb.append(", ");
- sb.append("prefix:");
- if (this.prefix == null) {
- sb.append("null");
- } else {
- sb.append(this.prefix);
- }
- first = false;
- if (!first) sb.append(", ");
- sb.append("prefixlen:");
- sb.append(this.prefixlen);
- first = false;
- if (!first) sb.append(", ");
- sb.append("nexthop:");
- if (this.nexthop == null) {
- sb.append("null");
- } else {
- sb.append(this.nexthop);
- }
- first = false;
- if (!first) sb.append(", ");
- sb.append("ethtag:");
- sb.append(this.ethtag);
- first = false;
- if (!first) sb.append(", ");
- sb.append("esi:");
- if (this.esi == null) {
- sb.append("null");
- } else {
- sb.append(this.esi);
- }
- first = false;
- if (!first) sb.append(", ");
- sb.append("macaddress:");
- if (this.macaddress == null) {
- sb.append("null");
- } else {
- sb.append(this.macaddress);
- }
- first = false;
- if (!first) sb.append(", ");
- sb.append("l3label:");
- sb.append(this.l3label);
- first = false;
- if (!first) sb.append(", ");
- sb.append("l2label:");
- sb.append(this.l2label);
- first = false;
- if (!first) sb.append(", ");
- sb.append("routermac:");
- if (this.routermac == null) {
- sb.append("null");
- } else {
- sb.append(this.routermac);
- }
- first = false;
- if (!first) sb.append(", ");
- sb.append("afi:");
- if (this.afi == null) {
- sb.append("null");
- } else {
- sb.append(this.afi);
- }
- first = false;
- sb.append(")");
- return sb.toString();
- }
-
- public void validate() throws org.apache.thrift.TException {
- // check for required fields
- // check for sub-struct validity
- }
-
- private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
- try {
- write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
- } catch (org.apache.thrift.TException te) {
- throw new java.io.IOException(te);
- }
- }
-
- private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
- try {
- // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
- __isset_bitfield = 0;
- read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
- } catch (org.apache.thrift.TException te) {
- throw new java.io.IOException(te);
- }
- }
-
- private static class onUpdatePushRoute_argsStandardSchemeFactory implements SchemeFactory {
- public onUpdatePushRoute_argsStandardScheme getScheme() {
- return new onUpdatePushRoute_argsStandardScheme();
- }
- }
-
- private static class onUpdatePushRoute_argsStandardScheme extends StandardScheme<onUpdatePushRoute_args> {
-
- public void read(org.apache.thrift.protocol.TProtocol iprot, onUpdatePushRoute_args struct) throws org.apache.thrift.TException {
- org.apache.thrift.protocol.TField schemeField;
- iprot.readStructBegin();
- while (true)
- {
- schemeField = iprot.readFieldBegin();
- if (schemeField.type == org.apache.thrift.protocol.TType.STOP) {
- break;
- }
- switch (schemeField.id) {
- case 1: // P_TYPE
- if (schemeField.type == org.apache.thrift.protocol.TType.I32) {
- struct.p_type = protocol_type.findByValue(iprot.readI32());
- struct.setP_typeIsSet(true);
- } else {
- org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
- }
- break;
- case 2: // RD
- if (schemeField.type == org.apache.thrift.protocol.TType.STRING) {
- struct.rd = iprot.readString();
- struct.setRdIsSet(true);
- } else {
- org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
- }
- break;
- case 3: // PREFIX
- if (schemeField.type == org.apache.thrift.protocol.TType.STRING) {
- struct.prefix = iprot.readString();
- struct.setPrefixIsSet(true);
- } else {
- org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
- }
- break;
- case 4: // PREFIXLEN
- if (schemeField.type == org.apache.thrift.protocol.TType.I32) {
- struct.prefixlen = iprot.readI32();
- struct.setPrefixlenIsSet(true);
- } else {
- org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
- }
- break;
- case 5: // NEXTHOP
- if (schemeField.type == org.apache.thrift.protocol.TType.STRING) {
- struct.nexthop = iprot.readString();
- struct.setNexthopIsSet(true);
- } else {
- org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
- }
- break;
- case 6: // ETHTAG
- if (schemeField.type == org.apache.thrift.protocol.TType.I32) {
- struct.ethtag = iprot.readI32();
- struct.setEthtagIsSet(true);
- } else {
- org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
- }
- break;
- case 7: // ESI
- if (schemeField.type == org.apache.thrift.protocol.TType.STRING) {
- struct.esi = iprot.readString();
- struct.setEsiIsSet(true);
- } else {
- org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
- }
- break;
- case 8: // MACADDRESS
- if (schemeField.type == org.apache.thrift.protocol.TType.STRING) {
- struct.macaddress = iprot.readString();
- struct.setMacaddressIsSet(true);
- } else {
- org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
- }
- break;
- case 9: // L3LABEL
- if (schemeField.type == org.apache.thrift.protocol.TType.I32) {
- struct.l3label = iprot.readI32();
- struct.setL3labelIsSet(true);
- } else {
- org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
- }
- break;
- case 10: // L2LABEL
- if (schemeField.type == org.apache.thrift.protocol.TType.I32) {
- struct.l2label = iprot.readI32();
- struct.setL2labelIsSet(true);
- } else {
- org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
- }
- break;
- case 11: // ROUTERMAC
- if (schemeField.type == org.apache.thrift.protocol.TType.STRING) {
- struct.routermac = iprot.readString();
- struct.setRoutermacIsSet(true);
- } else {
- org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
- }
- break;
- case 12: // AFI
- if (schemeField.type == org.apache.thrift.protocol.TType.I32) {
- struct.afi = af_afi.findByValue(iprot.readI32());
- struct.setAfiIsSet(true);
- } else {
- org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
- }
- break;
- default:
- org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
- }
- iprot.readFieldEnd();
- }
- iprot.readStructEnd();
-
- // check for required fields of primitive type, which can't be checked in the validate method
- struct.validate();
- }
-
- public void write(org.apache.thrift.protocol.TProtocol oprot, onUpdatePushRoute_args struct) throws org.apache.thrift.TException {
- struct.validate();
-
- oprot.writeStructBegin(STRUCT_DESC);
- if (struct.p_type != null) {
- oprot.writeFieldBegin(P_TYPE_FIELD_DESC);
- oprot.writeI32(struct.p_type.getValue());
- oprot.writeFieldEnd();
- }
- if (struct.rd != null) {
- oprot.writeFieldBegin(RD_FIELD_DESC);
- oprot.writeString(struct.rd);
- oprot.writeFieldEnd();
- }
- if (struct.prefix != null) {
- oprot.writeFieldBegin(PREFIX_FIELD_DESC);
- oprot.writeString(struct.prefix);
- oprot.writeFieldEnd();
- }
- oprot.writeFieldBegin(PREFIXLEN_FIELD_DESC);
- oprot.writeI32(struct.prefixlen);
- oprot.writeFieldEnd();
- if (struct.nexthop != null) {
- oprot.writeFieldBegin(NEXTHOP_FIELD_DESC);
- oprot.writeString(struct.nexthop);
- oprot.writeFieldEnd();
- }
- oprot.writeFieldBegin(ETHTAG_FIELD_DESC);
- oprot.writeI32(struct.ethtag);
- oprot.writeFieldEnd();
- if (struct.esi != null) {
- oprot.writeFieldBegin(ESI_FIELD_DESC);
- oprot.writeString(struct.esi);
- oprot.writeFieldEnd();
- }
- if (struct.macaddress != null) {
- oprot.writeFieldBegin(MACADDRESS_FIELD_DESC);
- oprot.writeString(struct.macaddress);
- oprot.writeFieldEnd();
- }
- oprot.writeFieldBegin(L3LABEL_FIELD_DESC);
- oprot.writeI32(struct.l3label);
- oprot.writeFieldEnd();
- oprot.writeFieldBegin(L2LABEL_FIELD_DESC);
- oprot.writeI32(struct.l2label);
- oprot.writeFieldEnd();
- if (struct.routermac != null) {
- oprot.writeFieldBegin(ROUTERMAC_FIELD_DESC);
- oprot.writeString(struct.routermac);
- oprot.writeFieldEnd();
- }
- if (struct.afi != null) {
- oprot.writeFieldBegin(AFI_FIELD_DESC);
- oprot.writeI32(struct.afi.getValue());
- oprot.writeFieldEnd();
- }
- oprot.writeFieldStop();
- oprot.writeStructEnd();
- }
-
- }
-
- private static class onUpdatePushRoute_argsTupleSchemeFactory implements SchemeFactory {
- public onUpdatePushRoute_argsTupleScheme getScheme() {
- return new onUpdatePushRoute_argsTupleScheme();
- }
- }
-
- private static class onUpdatePushRoute_argsTupleScheme extends TupleScheme<onUpdatePushRoute_args> {
-
- @Override
- public void write(org.apache.thrift.protocol.TProtocol prot, onUpdatePushRoute_args struct) throws org.apache.thrift.TException {
- TTupleProtocol oprot = (TTupleProtocol) prot;
- BitSet optionals = new BitSet();
- if (struct.isSetP_type()) {
- optionals.set(0);
- }
- if (struct.isSetRd()) {
- optionals.set(1);
- }
- if (struct.isSetPrefix()) {
- optionals.set(2);
- }
- if (struct.isSetPrefixlen()) {
- optionals.set(3);
- }
- if (struct.isSetNexthop()) {
- optionals.set(4);
- }
- if (struct.isSetEthtag()) {
- optionals.set(5);
- }
- if (struct.isSetEsi()) {
- optionals.set(6);
- }
- if (struct.isSetMacaddress()) {
- optionals.set(7);
- }
- if (struct.isSetL3label()) {
- optionals.set(8);
- }
- if (struct.isSetL2label()) {
- optionals.set(9);
- }
- if (struct.isSetRoutermac()) {
- optionals.set(10);
- }
- if (struct.isSetAfi()) {
- optionals.set(11);
- }
- oprot.writeBitSet(optionals, 12);
- if (struct.isSetP_type()) {
- oprot.writeI32(struct.p_type.getValue());
- }
- if (struct.isSetRd()) {
- oprot.writeString(struct.rd);
- }
- if (struct.isSetPrefix()) {
- oprot.writeString(struct.prefix);
- }
- if (struct.isSetPrefixlen()) {
- oprot.writeI32(struct.prefixlen);
- }
- if (struct.isSetNexthop()) {
- oprot.writeString(struct.nexthop);
- }
- if (struct.isSetEthtag()) {
- oprot.writeI32(struct.ethtag);
- }
- if (struct.isSetEsi()) {
- oprot.writeString(struct.esi);
- }
- if (struct.isSetMacaddress()) {
- oprot.writeString(struct.macaddress);
- }
- if (struct.isSetL3label()) {
- oprot.writeI32(struct.l3label);
- }
- if (struct.isSetL2label()) {
- oprot.writeI32(struct.l2label);
- }
- if (struct.isSetRoutermac()) {
- oprot.writeString(struct.routermac);
- }
- if (struct.isSetAfi()) {
- oprot.writeI32(struct.afi.getValue());
- }
- }
-
- @Override
- public void read(org.apache.thrift.protocol.TProtocol prot, onUpdatePushRoute_args struct) throws org.apache.thrift.TException {
- TTupleProtocol iprot = (TTupleProtocol) prot;
- BitSet incoming = iprot.readBitSet(12);
- if (incoming.get(0)) {
- struct.p_type = protocol_type.findByValue(iprot.readI32());
- struct.setP_typeIsSet(true);
- }
- if (incoming.get(1)) {
- struct.rd = iprot.readString();
- struct.setRdIsSet(true);
- }
- if (incoming.get(2)) {
- struct.prefix = iprot.readString();
- struct.setPrefixIsSet(true);
- }
- if (incoming.get(3)) {
- struct.prefixlen = iprot.readI32();
- struct.setPrefixlenIsSet(true);
- }
- if (incoming.get(4)) {
- struct.nexthop = iprot.readString();
- struct.setNexthopIsSet(true);
- }
- if (incoming.get(5)) {
- struct.ethtag = iprot.readI32();
- struct.setEthtagIsSet(true);
- }
- if (incoming.get(6)) {
- struct.esi = iprot.readString();
- struct.setEsiIsSet(true);
- }
- if (incoming.get(7)) {
- struct.macaddress = iprot.readString();
- struct.setMacaddressIsSet(true);
- }
- if (incoming.get(8)) {
- struct.l3label = iprot.readI32();
- struct.setL3labelIsSet(true);
- }
- if (incoming.get(9)) {
- struct.l2label = iprot.readI32();
- struct.setL2labelIsSet(true);
- }
- if (incoming.get(10)) {
- struct.routermac = iprot.readString();
- struct.setRoutermacIsSet(true);
- }
- if (incoming.get(11)) {
- struct.afi = af_afi.findByValue(iprot.readI32());
- struct.setAfiIsSet(true);
- }
- }
- }
-
- }
-
- public static class onUpdateWithdrawRoute_args implements org.apache.thrift.TBase<onUpdateWithdrawRoute_args, onUpdateWithdrawRoute_args._Fields>, java.io.Serializable, Cloneable, Comparable<onUpdateWithdrawRoute_args> {
- private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("onUpdateWithdrawRoute_args");
-
- private static final org.apache.thrift.protocol.TField P_TYPE_FIELD_DESC = new org.apache.thrift.protocol.TField("p_type", org.apache.thrift.protocol.TType.I32, (short)1);
- private static final org.apache.thrift.protocol.TField RD_FIELD_DESC = new org.apache.thrift.protocol.TField("rd", org.apache.thrift.protocol.TType.STRING, (short)2);
- private static final org.apache.thrift.protocol.TField PREFIX_FIELD_DESC = new org.apache.thrift.protocol.TField("prefix", org.apache.thrift.protocol.TType.STRING, (short)3);
- private static final org.apache.thrift.protocol.TField PREFIXLEN_FIELD_DESC = new org.apache.thrift.protocol.TField("prefixlen", org.apache.thrift.protocol.TType.I32, (short)4);
- private static final org.apache.thrift.protocol.TField NEXTHOP_FIELD_DESC = new org.apache.thrift.protocol.TField("nexthop", org.apache.thrift.protocol.TType.STRING, (short)5);
- private static final org.apache.thrift.protocol.TField ETHTAG_FIELD_DESC = new org.apache.thrift.protocol.TField("ethtag", org.apache.thrift.protocol.TType.I32, (short)6);
- private static final org.apache.thrift.protocol.TField ESI_FIELD_DESC = new org.apache.thrift.protocol.TField("esi", org.apache.thrift.protocol.TType.STRING, (short)7);
- private static final org.apache.thrift.protocol.TField MACADDRESS_FIELD_DESC = new org.apache.thrift.protocol.TField("macaddress", org.apache.thrift.protocol.TType.STRING, (short)8);
- private static final org.apache.thrift.protocol.TField L3LABEL_FIELD_DESC = new org.apache.thrift.protocol.TField("l3label", org.apache.thrift.protocol.TType.I32, (short)9);
- private static final org.apache.thrift.protocol.TField L2LABEL_FIELD_DESC = new org.apache.thrift.protocol.TField("l2label", org.apache.thrift.protocol.TType.I32, (short)10);
- private static final org.apache.thrift.protocol.TField AFI_FIELD_DESC = new org.apache.thrift.protocol.TField("afi", org.apache.thrift.protocol.TType.I32, (short)11);
-
- private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
- static {
- schemes.put(StandardScheme.class, new onUpdateWithdrawRoute_argsStandardSchemeFactory());
- schemes.put(TupleScheme.class, new onUpdateWithdrawRoute_argsTupleSchemeFactory());
- }
-
- /**
- *
- * @see protocol_type
- */
- public protocol_type p_type; // required
- public String rd; // required
- public String prefix; // required
- public int prefixlen; // required
- public String nexthop; // required
- public int ethtag; // required
- public String esi; // required
- public String macaddress; // required
- public int l3label; // required
- public int l2label; // required
- /**
- *
- * @see af_afi
- */
- public af_afi afi; // required
-
- /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
- public enum _Fields implements org.apache.thrift.TFieldIdEnum {
- /**
- *
- * @see protocol_type
- */
- P_TYPE((short)1, "p_type"),
- RD((short)2, "rd"),
- PREFIX((short)3, "prefix"),
- PREFIXLEN((short)4, "prefixlen"),
- NEXTHOP((short)5, "nexthop"),
- ETHTAG((short)6, "ethtag"),
- ESI((short)7, "esi"),
- MACADDRESS((short)8, "macaddress"),
- L3LABEL((short)9, "l3label"),
- L2LABEL((short)10, "l2label"),
- /**
- *
- * @see af_afi
- */
- AFI((short)11, "afi");
-
- private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
-
- static {
- for (_Fields field : EnumSet.allOf(_Fields.class)) {
- byName.put(field.getFieldName(), field);
- }
- }
-
- /**
- * Find the _Fields constant that matches fieldId, or null if its not found.
- */
- public static _Fields findByThriftId(int fieldId) {
- switch(fieldId) {
- case 1: // P_TYPE
- return P_TYPE;
- case 2: // RD
- return RD;
- case 3: // PREFIX
- return PREFIX;
- case 4: // PREFIXLEN
- return PREFIXLEN;
- case 5: // NEXTHOP
- return NEXTHOP;
- case 6: // ETHTAG
- return ETHTAG;
- case 7: // ESI
- return ESI;
- case 8: // MACADDRESS
- return MACADDRESS;
- case 9: // L3LABEL
- return L3LABEL;
- case 10: // L2LABEL
- return L2LABEL;
- case 11: // AFI
- return AFI;
- default:
- return null;
- }
- }
-
- /**
- * Find the _Fields constant that matches fieldId, throwing an exception
- * if it is not found.
- */
- public static _Fields findByThriftIdOrThrow(int fieldId) {
- _Fields fields = findByThriftId(fieldId);
- if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
- return fields;
- }
-
- /**
- * Find the _Fields constant that matches name, or null if its not found.
- */
- public static _Fields findByName(String name) {
- return byName.get(name);
- }
-
- private final short _thriftId;
- private final String _fieldName;
-
- _Fields(short thriftId, String fieldName) {
- _thriftId = thriftId;
- _fieldName = fieldName;
- }
-
- public short getThriftFieldId() {
- return _thriftId;
- }
-
- public String getFieldName() {
- return _fieldName;
- }
- }
-
- // isset id assignments
- private static final int __PREFIXLEN_ISSET_ID = 0;
- private static final int __ETHTAG_ISSET_ID = 1;
- private static final int __L3LABEL_ISSET_ID = 2;
- private static final int __L2LABEL_ISSET_ID = 3;
- private byte __isset_bitfield = 0;
- public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
- static {
- Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
- tmpMap.put(_Fields.P_TYPE, new org.apache.thrift.meta_data.FieldMetaData("p_type", org.apache.thrift.TFieldRequirementType.DEFAULT,
- new org.apache.thrift.meta_data.EnumMetaData(org.apache.thrift.protocol.TType.ENUM, protocol_type.class)));
- tmpMap.put(_Fields.RD, new org.apache.thrift.meta_data.FieldMetaData("rd", org.apache.thrift.TFieldRequirementType.DEFAULT,
- new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
- tmpMap.put(_Fields.PREFIX, new org.apache.thrift.meta_data.FieldMetaData("prefix", org.apache.thrift.TFieldRequirementType.DEFAULT,
- new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
- tmpMap.put(_Fields.PREFIXLEN, new org.apache.thrift.meta_data.FieldMetaData("prefixlen", org.apache.thrift.TFieldRequirementType.DEFAULT,
- new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I32)));
- tmpMap.put(_Fields.NEXTHOP, new org.apache.thrift.meta_data.FieldMetaData("nexthop", org.apache.thrift.TFieldRequirementType.DEFAULT,
- new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
- tmpMap.put(_Fields.ETHTAG, new org.apache.thrift.meta_data.FieldMetaData("ethtag", org.apache.thrift.TFieldRequirementType.DEFAULT,
- new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I32)));
- tmpMap.put(_Fields.ESI, new org.apache.thrift.meta_data.FieldMetaData("esi", org.apache.thrift.TFieldRequirementType.DEFAULT,
- new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
- tmpMap.put(_Fields.MACADDRESS, new org.apache.thrift.meta_data.FieldMetaData("macaddress", org.apache.thrift.TFieldRequirementType.DEFAULT,
- new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
- tmpMap.put(_Fields.L3LABEL, new org.apache.thrift.meta_data.FieldMetaData("l3label", org.apache.thrift.TFieldRequirementType.DEFAULT,
- new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I32)));
- tmpMap.put(_Fields.L2LABEL, new org.apache.thrift.meta_data.FieldMetaData("l2label", org.apache.thrift.TFieldRequirementType.DEFAULT,
- new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I32)));
- tmpMap.put(_Fields.AFI, new org.apache.thrift.meta_data.FieldMetaData("afi", org.apache.thrift.TFieldRequirementType.DEFAULT,
- new org.apache.thrift.meta_data.EnumMetaData(org.apache.thrift.protocol.TType.ENUM, af_afi.class)));
- metaDataMap = Collections.unmodifiableMap(tmpMap);
- org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(onUpdateWithdrawRoute_args.class, metaDataMap);
- }
-
- public onUpdateWithdrawRoute_args() {
- }
-
- public onUpdateWithdrawRoute_args(
- protocol_type p_type,
- String rd,
- String prefix,
- int prefixlen,
- String nexthop,
- int ethtag,
- String esi,
- String macaddress,
- int l3label,
- int l2label,
- af_afi afi)
- {
- this();
- this.p_type = p_type;
- this.rd = rd;
- this.prefix = prefix;
- this.prefixlen = prefixlen;
- setPrefixlenIsSet(true);
- this.nexthop = nexthop;
- this.ethtag = ethtag;
- setEthtagIsSet(true);
- this.esi = esi;
- this.macaddress = macaddress;
- this.l3label = l3label;
- setL3labelIsSet(true);
- this.l2label = l2label;
- setL2labelIsSet(true);
- this.afi = afi;
- }
-
- /**
- * Performs a deep copy on <i>other</i>.
- */
- public onUpdateWithdrawRoute_args(onUpdateWithdrawRoute_args other) {
- __isset_bitfield = other.__isset_bitfield;
- if (other.isSetP_type()) {
- this.p_type = other.p_type;
- }
- if (other.isSetRd()) {
- this.rd = other.rd;
- }
- if (other.isSetPrefix()) {
- this.prefix = other.prefix;
- }
- this.prefixlen = other.prefixlen;
- if (other.isSetNexthop()) {
- this.nexthop = other.nexthop;
- }
- this.ethtag = other.ethtag;
- if (other.isSetEsi()) {
- this.esi = other.esi;
- }
- if (other.isSetMacaddress()) {
- this.macaddress = other.macaddress;
- }
- this.l3label = other.l3label;
- this.l2label = other.l2label;
- if (other.isSetAfi()) {
- this.afi = other.afi;
- }
- }
-
- public onUpdateWithdrawRoute_args deepCopy() {
- return new onUpdateWithdrawRoute_args(this);
- }
-
- @Override
- public void clear() {
- this.p_type = null;
- this.rd = null;
- this.prefix = null;
- setPrefixlenIsSet(false);
- this.prefixlen = 0;
- this.nexthop = null;
- setEthtagIsSet(false);
- this.ethtag = 0;
- this.esi = null;
- this.macaddress = null;
- setL3labelIsSet(false);
- this.l3label = 0;
- setL2labelIsSet(false);
- this.l2label = 0;
- this.afi = null;
- }
-
- /**
- *
- * @see protocol_type
- */
- public protocol_type getP_type() {
- return this.p_type;
- }
-
- /**
- *
- * @see protocol_type
- */
- public onUpdateWithdrawRoute_args setP_type(protocol_type p_type) {
- this.p_type = p_type;
- return this;
- }
-
- public void unsetP_type() {
- this.p_type = null;
- }
-
- /** Returns true if field p_type is set (has been assigned a value) and false otherwise */
- public boolean isSetP_type() {
- return this.p_type != null;
- }
-
- public void setP_typeIsSet(boolean value) {
- if (!value) {
- this.p_type = null;
- }
- }
-
- public String getRd() {
- return this.rd;
- }
-
- public onUpdateWithdrawRoute_args setRd(String rd) {
- this.rd = rd;
- return this;
- }
-
- public void unsetRd() {
- this.rd = null;
- }
-
- /** Returns true if field rd is set (has been assigned a value) and false otherwise */
- public boolean isSetRd() {
- return this.rd != null;
- }
-
- public void setRdIsSet(boolean value) {
- if (!value) {
- this.rd = null;
- }
- }
-
- public String getPrefix() {
- return this.prefix;
- }
-
- public onUpdateWithdrawRoute_args setPrefix(String prefix) {
- this.prefix = prefix;
- return this;
- }
-
- public void unsetPrefix() {
- this.prefix = null;
- }
-
- /** Returns true if field prefix is set (has been assigned a value) and false otherwise */
- public boolean isSetPrefix() {
- return this.prefix != null;
- }
-
- public void setPrefixIsSet(boolean value) {
- if (!value) {
- this.prefix = null;
- }
- }
-
- public int getPrefixlen() {
- return this.prefixlen;
- }
-
- public onUpdateWithdrawRoute_args setPrefixlen(int prefixlen) {
- this.prefixlen = prefixlen;
- setPrefixlenIsSet(true);
- return this;
- }
-
- public void unsetPrefixlen() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __PREFIXLEN_ISSET_ID);
- }
-
- /** Returns true if field prefixlen is set (has been assigned a value) and false otherwise */
- public boolean isSetPrefixlen() {
- return EncodingUtils.testBit(__isset_bitfield, __PREFIXLEN_ISSET_ID);
- }
-
- public void setPrefixlenIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __PREFIXLEN_ISSET_ID, value);
- }
-
- public String getNexthop() {
- return this.nexthop;
- }
-
- public onUpdateWithdrawRoute_args setNexthop(String nexthop) {
- this.nexthop = nexthop;
- return this;
- }
-
- public void unsetNexthop() {
- this.nexthop = null;
- }
-
- /** Returns true if field nexthop is set (has been assigned a value) and false otherwise */
- public boolean isSetNexthop() {
- return this.nexthop != null;
- }
-
- public void setNexthopIsSet(boolean value) {
- if (!value) {
- this.nexthop = null;
- }
- }
-
- public int getEthtag() {
- return this.ethtag;
- }
-
- public onUpdateWithdrawRoute_args setEthtag(int ethtag) {
- this.ethtag = ethtag;
- setEthtagIsSet(true);
- return this;
- }
-
- public void unsetEthtag() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __ETHTAG_ISSET_ID);
- }
-
- /** Returns true if field ethtag is set (has been assigned a value) and false otherwise */
- public boolean isSetEthtag() {
- return EncodingUtils.testBit(__isset_bitfield, __ETHTAG_ISSET_ID);
- }
-
- public void setEthtagIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __ETHTAG_ISSET_ID, value);
- }
-
- public String getEsi() {
- return this.esi;
- }
-
- public onUpdateWithdrawRoute_args setEsi(String esi) {
- this.esi = esi;
- return this;
- }
-
- public void unsetEsi() {
- this.esi = null;
- }
-
- /** Returns true if field esi is set (has been assigned a value) and false otherwise */
- public boolean isSetEsi() {
- return this.esi != null;
- }
-
- public void setEsiIsSet(boolean value) {
- if (!value) {
- this.esi = null;
- }
- }
-
- public String getMacaddress() {
- return this.macaddress;
- }
-
- public onUpdateWithdrawRoute_args setMacaddress(String macaddress) {
- this.macaddress = macaddress;
- return this;
- }
-
- public void unsetMacaddress() {
- this.macaddress = null;
- }
-
- /** Returns true if field macaddress is set (has been assigned a value) and false otherwise */
- public boolean isSetMacaddress() {
- return this.macaddress != null;
- }
-
- public void setMacaddressIsSet(boolean value) {
- if (!value) {
- this.macaddress = null;
- }
- }
-
- public int getL3label() {
- return this.l3label;
- }
-
- public onUpdateWithdrawRoute_args setL3label(int l3label) {
- this.l3label = l3label;
- setL3labelIsSet(true);
- return this;
- }
-
- public void unsetL3label() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __L3LABEL_ISSET_ID);
- }
-
- /** Returns true if field l3label is set (has been assigned a value) and false otherwise */
- public boolean isSetL3label() {
- return EncodingUtils.testBit(__isset_bitfield, __L3LABEL_ISSET_ID);
- }
-
- public void setL3labelIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __L3LABEL_ISSET_ID, value);
- }
-
- public int getL2label() {
- return this.l2label;
- }
-
- public onUpdateWithdrawRoute_args setL2label(int l2label) {
- this.l2label = l2label;
- setL2labelIsSet(true);
- return this;
- }
-
- public void unsetL2label() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __L2LABEL_ISSET_ID);
- }
-
- /** Returns true if field l2label is set (has been assigned a value) and false otherwise */
- public boolean isSetL2label() {
- return EncodingUtils.testBit(__isset_bitfield, __L2LABEL_ISSET_ID);
- }
-
- public void setL2labelIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __L2LABEL_ISSET_ID, value);
- }
-
- /**
- *
- * @see af_afi
- */
- public af_afi getAfi() {
- return this.afi;
- }
-
- /**
- *
- * @see af_afi
- */
- public onUpdateWithdrawRoute_args setAfi(af_afi afi) {
- this.afi = afi;
- return this;
- }
-
- public void unsetAfi() {
- this.afi = null;
- }
-
- /** Returns true if field afi is set (has been assigned a value) and false otherwise */
- public boolean isSetAfi() {
- return this.afi != null;
- }
-
- public void setAfiIsSet(boolean value) {
- if (!value) {
- this.afi = null;
- }
- }
-
- public void setFieldValue(_Fields field, Object value) {
- switch (field) {
- case P_TYPE:
- if (value == null) {
- unsetP_type();
- } else {
- setP_type((protocol_type)value);
- }
- break;
-
- case RD:
- if (value == null) {
- unsetRd();
- } else {
- setRd((String)value);
- }
- break;
-
- case PREFIX:
- if (value == null) {
- unsetPrefix();
- } else {
- setPrefix((String)value);
- }
- break;
-
- case PREFIXLEN:
- if (value == null) {
- unsetPrefixlen();
- } else {
- setPrefixlen((Integer)value);
- }
- break;
-
- case NEXTHOP:
- if (value == null) {
- unsetNexthop();
- } else {
- setNexthop((String)value);
- }
- break;
-
- case ETHTAG:
- if (value == null) {
- unsetEthtag();
- } else {
- setEthtag((Integer)value);
- }
- break;
-
- case ESI:
- if (value == null) {
- unsetEsi();
- } else {
- setEsi((String)value);
- }
- break;
-
- case MACADDRESS:
- if (value == null) {
- unsetMacaddress();
- } else {
- setMacaddress((String)value);
- }
- break;
-
- case L3LABEL:
- if (value == null) {
- unsetL3label();
- } else {
- setL3label((Integer)value);
- }
- break;
-
- case L2LABEL:
- if (value == null) {
- unsetL2label();
- } else {
- setL2label((Integer)value);
- }
- break;
-
- case AFI:
- if (value == null) {
- unsetAfi();
- } else {
- setAfi((af_afi)value);
- }
- break;
-
- }
- }
-
- public Object getFieldValue(_Fields field) {
- switch (field) {
- case P_TYPE:
- return getP_type();
-
- case RD:
- return getRd();
-
- case PREFIX:
- return getPrefix();
-
- case PREFIXLEN:
- return Integer.valueOf(getPrefixlen());
-
- case NEXTHOP:
- return getNexthop();
-
- case ETHTAG:
- return Integer.valueOf(getEthtag());
-
- case ESI:
- return getEsi();
-
- case MACADDRESS:
- return getMacaddress();
-
- case L3LABEL:
- return Integer.valueOf(getL3label());
-
- case L2LABEL:
- return Integer.valueOf(getL2label());
-
- case AFI:
- return getAfi();
-
- }
- throw new IllegalStateException();
- }
-
- /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
- public boolean isSet(_Fields field) {
- if (field == null) {
- throw new IllegalArgumentException();
- }
-
- switch (field) {
- case P_TYPE:
- return isSetP_type();
- case RD:
- return isSetRd();
- case PREFIX:
- return isSetPrefix();
- case PREFIXLEN:
- return isSetPrefixlen();
- case NEXTHOP:
- return isSetNexthop();
- case ETHTAG:
- return isSetEthtag();
- case ESI:
- return isSetEsi();
- case MACADDRESS:
- return isSetMacaddress();
- case L3LABEL:
- return isSetL3label();
- case L2LABEL:
- return isSetL2label();
- case AFI:
- return isSetAfi();
- }
- throw new IllegalStateException();
- }
-
- @Override
- public boolean equals(Object that) {
- if (that == null)
- return false;
- if (that instanceof onUpdateWithdrawRoute_args)
- return this.equals((onUpdateWithdrawRoute_args)that);
- return false;
- }
-
- public boolean equals(onUpdateWithdrawRoute_args that) {
- if (that == null)
- return false;
-
- boolean this_present_p_type = true && this.isSetP_type();
- boolean that_present_p_type = true && that.isSetP_type();
- if (this_present_p_type || that_present_p_type) {
- if (!(this_present_p_type && that_present_p_type))
- return false;
- if (!this.p_type.equals(that.p_type))
- return false;
- }
-
- boolean this_present_rd = true && this.isSetRd();
- boolean that_present_rd = true && that.isSetRd();
- if (this_present_rd || that_present_rd) {
- if (!(this_present_rd && that_present_rd))
- return false;
- if (!this.rd.equals(that.rd))
- return false;
- }
-
- boolean this_present_prefix = true && this.isSetPrefix();
- boolean that_present_prefix = true && that.isSetPrefix();
- if (this_present_prefix || that_present_prefix) {
- if (!(this_present_prefix && that_present_prefix))
- return false;
- if (!this.prefix.equals(that.prefix))
- return false;
- }
-
- boolean this_present_prefixlen = true;
- boolean that_present_prefixlen = true;
- if (this_present_prefixlen || that_present_prefixlen) {
- if (!(this_present_prefixlen && that_present_prefixlen))
- return false;
- if (this.prefixlen != that.prefixlen)
- return false;
- }
-
- boolean this_present_nexthop = true && this.isSetNexthop();
- boolean that_present_nexthop = true && that.isSetNexthop();
- if (this_present_nexthop || that_present_nexthop) {
- if (!(this_present_nexthop && that_present_nexthop))
- return false;
- if (!this.nexthop.equals(that.nexthop))
- return false;
- }
-
- boolean this_present_ethtag = true;
- boolean that_present_ethtag = true;
- if (this_present_ethtag || that_present_ethtag) {
- if (!(this_present_ethtag && that_present_ethtag))
- return false;
- if (this.ethtag != that.ethtag)
- return false;
- }
-
- boolean this_present_esi = true && this.isSetEsi();
- boolean that_present_esi = true && that.isSetEsi();
- if (this_present_esi || that_present_esi) {
- if (!(this_present_esi && that_present_esi))
- return false;
- if (!this.esi.equals(that.esi))
- return false;
- }
-
- boolean this_present_macaddress = true && this.isSetMacaddress();
- boolean that_present_macaddress = true && that.isSetMacaddress();
- if (this_present_macaddress || that_present_macaddress) {
- if (!(this_present_macaddress && that_present_macaddress))
- return false;
- if (!this.macaddress.equals(that.macaddress))
- return false;
- }
-
- boolean this_present_l3label = true;
- boolean that_present_l3label = true;
- if (this_present_l3label || that_present_l3label) {
- if (!(this_present_l3label && that_present_l3label))
- return false;
- if (this.l3label != that.l3label)
- return false;
- }
-
- boolean this_present_l2label = true;
- boolean that_present_l2label = true;
- if (this_present_l2label || that_present_l2label) {
- if (!(this_present_l2label && that_present_l2label))
- return false;
- if (this.l2label != that.l2label)
- return false;
- }
-
- boolean this_present_afi = true && this.isSetAfi();
- boolean that_present_afi = true && that.isSetAfi();
- if (this_present_afi || that_present_afi) {
- if (!(this_present_afi && that_present_afi))
- return false;
- if (!this.afi.equals(that.afi))
- return false;
- }
-
- return true;
- }
-
- @Override
- public int hashCode() {
- List<Object> list = new ArrayList<Object>();
- boolean present_p_type = true && (isSetP_type());
- list.add(present_p_type);
- if (present_p_type)
- list.add(p_type.getValue());
- boolean present_rd = true && (isSetRd());
- list.add(present_rd);
- if (present_rd)
- list.add(rd);
- boolean present_prefix = true && (isSetPrefix());
- list.add(present_prefix);
- if (present_prefix)
- list.add(prefix);
- boolean present_prefixlen = true;
- list.add(present_prefixlen);
- if (present_prefixlen)
- list.add(prefixlen);
- boolean present_nexthop = true && (isSetNexthop());
- list.add(present_nexthop);
- if (present_nexthop)
- list.add(nexthop);
- boolean present_ethtag = true;
- list.add(present_ethtag);
- if (present_ethtag)
- list.add(ethtag);
- boolean present_esi = true && (isSetEsi());
- list.add(present_esi);
- if (present_esi)
- list.add(esi);
- boolean present_macaddress = true && (isSetMacaddress());
- list.add(present_macaddress);
- if (present_macaddress)
- list.add(macaddress);
- boolean present_l3label = true;
- list.add(present_l3label);
- if (present_l3label)
- list.add(l3label);
- boolean present_l2label = true;
- list.add(present_l2label);
- if (present_l2label)
- list.add(l2label);
- boolean present_afi = true && (isSetAfi());
- list.add(present_afi);
- if (present_afi)
- list.add(afi.getValue());
- return list.hashCode();
- }
-
- @Override
- public int compareTo(onUpdateWithdrawRoute_args other) {
- if (!getClass().equals(other.getClass())) {
- return getClass().getName().compareTo(other.getClass().getName());
- }
-
- int lastComparison = 0;
-
- lastComparison = Boolean.valueOf(isSetP_type()).compareTo(other.isSetP_type());
- if (lastComparison != 0) {
- return lastComparison;
- }
- if (isSetP_type()) {
- lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.p_type, other.p_type);
- if (lastComparison != 0) {
- return lastComparison;
- }
- }
- lastComparison = Boolean.valueOf(isSetRd()).compareTo(other.isSetRd());
- if (lastComparison != 0) {
- return lastComparison;
- }
- if (isSetRd()) {
- lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.rd, other.rd);
- if (lastComparison != 0) {
- return lastComparison;
- }
- }
- lastComparison = Boolean.valueOf(isSetPrefix()).compareTo(other.isSetPrefix());
- if (lastComparison != 0) {
- return lastComparison;
- }
- if (isSetPrefix()) {
- lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.prefix, other.prefix);
- if (lastComparison != 0) {
- return lastComparison;
- }
- }
- lastComparison = Boolean.valueOf(isSetPrefixlen()).compareTo(other.isSetPrefixlen());
- if (lastComparison != 0) {
- return lastComparison;
- }
- if (isSetPrefixlen()) {
- lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.prefixlen, other.prefixlen);
- if (lastComparison != 0) {
- return lastComparison;
- }
- }
- lastComparison = Boolean.valueOf(isSetNexthop()).compareTo(other.isSetNexthop());
- if (lastComparison != 0) {
- return lastComparison;
- }
- if (isSetNexthop()) {
- lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.nexthop, other.nexthop);
- if (lastComparison != 0) {
- return lastComparison;
- }
- }
- lastComparison = Boolean.valueOf(isSetEthtag()).compareTo(other.isSetEthtag());
- if (lastComparison != 0) {
- return lastComparison;
- }
- if (isSetEthtag()) {
- lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.ethtag, other.ethtag);
- if (lastComparison != 0) {
- return lastComparison;
- }
- }
- lastComparison = Boolean.valueOf(isSetEsi()).compareTo(other.isSetEsi());
- if (lastComparison != 0) {
- return lastComparison;
- }
- if (isSetEsi()) {
- lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.esi, other.esi);
- if (lastComparison != 0) {
- return lastComparison;
- }
- }
- lastComparison = Boolean.valueOf(isSetMacaddress()).compareTo(other.isSetMacaddress());
- if (lastComparison != 0) {
- return lastComparison;
- }
- if (isSetMacaddress()) {
- lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.macaddress, other.macaddress);
- if (lastComparison != 0) {
- return lastComparison;
- }
- }
- lastComparison = Boolean.valueOf(isSetL3label()).compareTo(other.isSetL3label());
- if (lastComparison != 0) {
- return lastComparison;
- }
- if (isSetL3label()) {
- lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.l3label, other.l3label);
- if (lastComparison != 0) {
- return lastComparison;
- }
- }
- lastComparison = Boolean.valueOf(isSetL2label()).compareTo(other.isSetL2label());
- if (lastComparison != 0) {
- return lastComparison;
- }
- if (isSetL2label()) {
- lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.l2label, other.l2label);
- if (lastComparison != 0) {
- return lastComparison;
- }
- }
- lastComparison = Boolean.valueOf(isSetAfi()).compareTo(other.isSetAfi());
- if (lastComparison != 0) {
- return lastComparison;
- }
- if (isSetAfi()) {
- lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.afi, other.afi);
- if (lastComparison != 0) {
- return lastComparison;
- }
- }
- return 0;
- }
-
- public _Fields fieldForId(int fieldId) {
- return _Fields.findByThriftId(fieldId);
- }
-
- public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
- schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
- }
-
- public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
- schemes.get(oprot.getScheme()).getScheme().write(oprot, this);
- }
-
- @Override
- public String toString() {
- StringBuilder sb = new StringBuilder("onUpdateWithdrawRoute_args(");
- boolean first = true;
-
- sb.append("p_type:");
- if (this.p_type == null) {
- sb.append("null");
- } else {
- sb.append(this.p_type);
- }
- first = false;
- if (!first) sb.append(", ");
- sb.append("rd:");
- if (this.rd == null) {
- sb.append("null");
- } else {
- sb.append(this.rd);
- }
- first = false;
- if (!first) sb.append(", ");
- sb.append("prefix:");
- if (this.prefix == null) {
- sb.append("null");
- } else {
- sb.append(this.prefix);
- }
- first = false;
- if (!first) sb.append(", ");
- sb.append("prefixlen:");
- sb.append(this.prefixlen);
- first = false;
- if (!first) sb.append(", ");
- sb.append("nexthop:");
- if (this.nexthop == null) {
- sb.append("null");
- } else {
- sb.append(this.nexthop);
- }
- first = false;
- if (!first) sb.append(", ");
- sb.append("ethtag:");
- sb.append(this.ethtag);
- first = false;
- if (!first) sb.append(", ");
- sb.append("esi:");
- if (this.esi == null) {
- sb.append("null");
- } else {
- sb.append(this.esi);
- }
- first = false;
- if (!first) sb.append(", ");
- sb.append("macaddress:");
- if (this.macaddress == null) {
- sb.append("null");
- } else {
- sb.append(this.macaddress);
- }
- first = false;
- if (!first) sb.append(", ");
- sb.append("l3label:");
- sb.append(this.l3label);
- first = false;
- if (!first) sb.append(", ");
- sb.append("l2label:");
- sb.append(this.l2label);
- first = false;
- if (!first) sb.append(", ");
- sb.append("afi:");
- if (this.afi == null) {
- sb.append("null");
- } else {
- sb.append(this.afi);
- }
- first = false;
- sb.append(")");
- return sb.toString();
- }
-
- public void validate() throws org.apache.thrift.TException {
- // check for required fields
- // check for sub-struct validity
- }
-
- private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
- try {
- write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
- } catch (org.apache.thrift.TException te) {
- throw new java.io.IOException(te);
- }
- }
-
- private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
- try {
- // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
- __isset_bitfield = 0;
- read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
- } catch (org.apache.thrift.TException te) {
- throw new java.io.IOException(te);
- }
- }
-
- private static class onUpdateWithdrawRoute_argsStandardSchemeFactory implements SchemeFactory {
- public onUpdateWithdrawRoute_argsStandardScheme getScheme() {
- return new onUpdateWithdrawRoute_argsStandardScheme();
- }
- }
-
- private static class onUpdateWithdrawRoute_argsStandardScheme extends StandardScheme<onUpdateWithdrawRoute_args> {
-
- public void read(org.apache.thrift.protocol.TProtocol iprot, onUpdateWithdrawRoute_args struct) throws org.apache.thrift.TException {
- org.apache.thrift.protocol.TField schemeField;
- iprot.readStructBegin();
- while (true)
- {
- schemeField = iprot.readFieldBegin();
- if (schemeField.type == org.apache.thrift.protocol.TType.STOP) {
- break;
- }
- switch (schemeField.id) {
- case 1: // P_TYPE
- if (schemeField.type == org.apache.thrift.protocol.TType.I32) {
- struct.p_type = protocol_type.findByValue(iprot.readI32());
- struct.setP_typeIsSet(true);
- } else {
- org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
- }
- break;
- case 2: // RD
- if (schemeField.type == org.apache.thrift.protocol.TType.STRING) {
- struct.rd = iprot.readString();
- struct.setRdIsSet(true);
- } else {
- org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
- }
- break;
- case 3: // PREFIX
- if (schemeField.type == org.apache.thrift.protocol.TType.STRING) {
- struct.prefix = iprot.readString();
- struct.setPrefixIsSet(true);
- } else {
- org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
- }
- break;
- case 4: // PREFIXLEN
- if (schemeField.type == org.apache.thrift.protocol.TType.I32) {
- struct.prefixlen = iprot.readI32();
- struct.setPrefixlenIsSet(true);
- } else {
- org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
- }
- break;
- case 5: // NEXTHOP
- if (schemeField.type == org.apache.thrift.protocol.TType.STRING) {
- struct.nexthop = iprot.readString();
- struct.setNexthopIsSet(true);
- } else {
- org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
- }
- break;
- case 6: // ETHTAG
- if (schemeField.type == org.apache.thrift.protocol.TType.I32) {
- struct.ethtag = iprot.readI32();
- struct.setEthtagIsSet(true);
- } else {
- org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
- }
- break;
- case 7: // ESI
- if (schemeField.type == org.apache.thrift.protocol.TType.STRING) {
- struct.esi = iprot.readString();
- struct.setEsiIsSet(true);
- } else {
- org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
- }
- break;
- case 8: // MACADDRESS
- if (schemeField.type == org.apache.thrift.protocol.TType.STRING) {
- struct.macaddress = iprot.readString();
- struct.setMacaddressIsSet(true);
- } else {
- org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
- }
- break;
- case 9: // L3LABEL
- if (schemeField.type == org.apache.thrift.protocol.TType.I32) {
- struct.l3label = iprot.readI32();
- struct.setL3labelIsSet(true);
- } else {
- org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
- }
- break;
- case 10: // L2LABEL
- if (schemeField.type == org.apache.thrift.protocol.TType.I32) {
- struct.l2label = iprot.readI32();
- struct.setL2labelIsSet(true);
- } else {
- org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
- }
- break;
- case 11: // AFI
- if (schemeField.type == org.apache.thrift.protocol.TType.I32) {
- struct.afi = af_afi.findByValue(iprot.readI32());
- struct.setAfiIsSet(true);
- } else {
- org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
- }
- break;
- default:
- org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
- }
- iprot.readFieldEnd();
- }
- iprot.readStructEnd();
-
- // check for required fields of primitive type, which can't be checked in the validate method
- struct.validate();
- }
-
- public void write(org.apache.thrift.protocol.TProtocol oprot, onUpdateWithdrawRoute_args struct) throws org.apache.thrift.TException {
- struct.validate();
-
- oprot.writeStructBegin(STRUCT_DESC);
- if (struct.p_type != null) {
- oprot.writeFieldBegin(P_TYPE_FIELD_DESC);
- oprot.writeI32(struct.p_type.getValue());
- oprot.writeFieldEnd();
- }
- if (struct.rd != null) {
- oprot.writeFieldBegin(RD_FIELD_DESC);
- oprot.writeString(struct.rd);
- oprot.writeFieldEnd();
- }
- if (struct.prefix != null) {
- oprot.writeFieldBegin(PREFIX_FIELD_DESC);
- oprot.writeString(struct.prefix);
- oprot.writeFieldEnd();
- }
- oprot.writeFieldBegin(PREFIXLEN_FIELD_DESC);
- oprot.writeI32(struct.prefixlen);
- oprot.writeFieldEnd();
- if (struct.nexthop != null) {
- oprot.writeFieldBegin(NEXTHOP_FIELD_DESC);
- oprot.writeString(struct.nexthop);
- oprot.writeFieldEnd();
- }
- oprot.writeFieldBegin(ETHTAG_FIELD_DESC);
- oprot.writeI32(struct.ethtag);
- oprot.writeFieldEnd();
- if (struct.esi != null) {
- oprot.writeFieldBegin(ESI_FIELD_DESC);
- oprot.writeString(struct.esi);
- oprot.writeFieldEnd();
- }
- if (struct.macaddress != null) {
- oprot.writeFieldBegin(MACADDRESS_FIELD_DESC);
- oprot.writeString(struct.macaddress);
- oprot.writeFieldEnd();
- }
- oprot.writeFieldBegin(L3LABEL_FIELD_DESC);
- oprot.writeI32(struct.l3label);
- oprot.writeFieldEnd();
- oprot.writeFieldBegin(L2LABEL_FIELD_DESC);
- oprot.writeI32(struct.l2label);
- oprot.writeFieldEnd();
- if (struct.afi != null) {
- oprot.writeFieldBegin(AFI_FIELD_DESC);
- oprot.writeI32(struct.afi.getValue());
- oprot.writeFieldEnd();
- }
- oprot.writeFieldStop();
- oprot.writeStructEnd();
- }
-
- }
-
- private static class onUpdateWithdrawRoute_argsTupleSchemeFactory implements SchemeFactory {
- public onUpdateWithdrawRoute_argsTupleScheme getScheme() {
- return new onUpdateWithdrawRoute_argsTupleScheme();
- }
- }
-
- private static class onUpdateWithdrawRoute_argsTupleScheme extends TupleScheme<onUpdateWithdrawRoute_args> {
-
- @Override
- public void write(org.apache.thrift.protocol.TProtocol prot, onUpdateWithdrawRoute_args struct) throws org.apache.thrift.TException {
- TTupleProtocol oprot = (TTupleProtocol) prot;
- BitSet optionals = new BitSet();
- if (struct.isSetP_type()) {
- optionals.set(0);
- }
- if (struct.isSetRd()) {
- optionals.set(1);
- }
- if (struct.isSetPrefix()) {
- optionals.set(2);
- }
- if (struct.isSetPrefixlen()) {
- optionals.set(3);
- }
- if (struct.isSetNexthop()) {
- optionals.set(4);
- }
- if (struct.isSetEthtag()) {
- optionals.set(5);
- }
- if (struct.isSetEsi()) {
- optionals.set(6);
- }
- if (struct.isSetMacaddress()) {
- optionals.set(7);
- }
- if (struct.isSetL3label()) {
- optionals.set(8);
- }
- if (struct.isSetL2label()) {
- optionals.set(9);
- }
- if (struct.isSetAfi()) {
- optionals.set(10);
- }
- oprot.writeBitSet(optionals, 11);
- if (struct.isSetP_type()) {
- oprot.writeI32(struct.p_type.getValue());
- }
- if (struct.isSetRd()) {
- oprot.writeString(struct.rd);
- }
- if (struct.isSetPrefix()) {
- oprot.writeString(struct.prefix);
- }
- if (struct.isSetPrefixlen()) {
- oprot.writeI32(struct.prefixlen);
- }
- if (struct.isSetNexthop()) {
- oprot.writeString(struct.nexthop);
- }
- if (struct.isSetEthtag()) {
- oprot.writeI32(struct.ethtag);
- }
- if (struct.isSetEsi()) {
- oprot.writeString(struct.esi);
- }
- if (struct.isSetMacaddress()) {
- oprot.writeString(struct.macaddress);
- }
- if (struct.isSetL3label()) {
- oprot.writeI32(struct.l3label);
- }
- if (struct.isSetL2label()) {
- oprot.writeI32(struct.l2label);
- }
- if (struct.isSetAfi()) {
- oprot.writeI32(struct.afi.getValue());
- }
- }
-
- @Override
- public void read(org.apache.thrift.protocol.TProtocol prot, onUpdateWithdrawRoute_args struct) throws org.apache.thrift.TException {
- TTupleProtocol iprot = (TTupleProtocol) prot;
- BitSet incoming = iprot.readBitSet(11);
- if (incoming.get(0)) {
- struct.p_type = protocol_type.findByValue(iprot.readI32());
- struct.setP_typeIsSet(true);
- }
- if (incoming.get(1)) {
- struct.rd = iprot.readString();
- struct.setRdIsSet(true);
- }
- if (incoming.get(2)) {
- struct.prefix = iprot.readString();
- struct.setPrefixIsSet(true);
- }
- if (incoming.get(3)) {
- struct.prefixlen = iprot.readI32();
- struct.setPrefixlenIsSet(true);
- }
- if (incoming.get(4)) {
- struct.nexthop = iprot.readString();
- struct.setNexthopIsSet(true);
- }
- if (incoming.get(5)) {
- struct.ethtag = iprot.readI32();
- struct.setEthtagIsSet(true);
- }
- if (incoming.get(6)) {
- struct.esi = iprot.readString();
- struct.setEsiIsSet(true);
- }
- if (incoming.get(7)) {
- struct.macaddress = iprot.readString();
- struct.setMacaddressIsSet(true);
- }
- if (incoming.get(8)) {
- struct.l3label = iprot.readI32();
- struct.setL3labelIsSet(true);
- }
- if (incoming.get(9)) {
- struct.l2label = iprot.readI32();
- struct.setL2labelIsSet(true);
- }
- if (incoming.get(10)) {
- struct.afi = af_afi.findByValue(iprot.readI32());
- struct.setAfiIsSet(true);
- }
- }
- }
-
- }
-
- public static class onStartConfigResyncNotification_args implements org.apache.thrift.TBase<onStartConfigResyncNotification_args, onStartConfigResyncNotification_args._Fields>, java.io.Serializable, Cloneable, Comparable<onStartConfigResyncNotification_args> {
- private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("onStartConfigResyncNotification_args");
-
-
- private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
- static {
- schemes.put(StandardScheme.class, new onStartConfigResyncNotification_argsStandardSchemeFactory());
- schemes.put(TupleScheme.class, new onStartConfigResyncNotification_argsTupleSchemeFactory());
- }
-
-
- /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
- public enum _Fields implements org.apache.thrift.TFieldIdEnum {
-;
-
- private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
-
- static {
- for (_Fields field : EnumSet.allOf(_Fields.class)) {
- byName.put(field.getFieldName(), field);
- }
- }
-
- /**
- * Find the _Fields constant that matches fieldId, or null if its not found.
- */
- public static _Fields findByThriftId(int fieldId) {
- switch(fieldId) {
- default:
- return null;
- }
- }
-
- /**
- * Find the _Fields constant that matches fieldId, throwing an exception
- * if it is not found.
- */
- public static _Fields findByThriftIdOrThrow(int fieldId) {
- _Fields fields = findByThriftId(fieldId);
- if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
- return fields;
- }
-
- /**
- * Find the _Fields constant that matches name, or null if its not found.
- */
- public static _Fields findByName(String name) {
- return byName.get(name);
- }
-
- private final short _thriftId;
- private final String _fieldName;
-
- _Fields(short thriftId, String fieldName) {
- _thriftId = thriftId;
- _fieldName = fieldName;
- }
-
- public short getThriftFieldId() {
- return _thriftId;
- }
-
- public String getFieldName() {
- return _fieldName;
- }
- }
- public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
- static {
- Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
- metaDataMap = Collections.unmodifiableMap(tmpMap);
- org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(onStartConfigResyncNotification_args.class, metaDataMap);
- }
-
- public onStartConfigResyncNotification_args() {
- }
-
- /**
- * Performs a deep copy on <i>other</i>.
- */
- public onStartConfigResyncNotification_args(onStartConfigResyncNotification_args other) {
- }
-
- public onStartConfigResyncNotification_args deepCopy() {
- return new onStartConfigResyncNotification_args(this);
- }
-
- @Override
- public void clear() {
- }
-
- public void setFieldValue(_Fields field, Object value) {
- switch (field) {
- }
- }
-
- public Object getFieldValue(_Fields field) {
- switch (field) {
- }
- throw new IllegalStateException();
- }
-
- /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
- public boolean isSet(_Fields field) {
- if (field == null) {
- throw new IllegalArgumentException();
- }
-
- switch (field) {
- }
- throw new IllegalStateException();
- }
-
- @Override
- public boolean equals(Object that) {
- if (that == null)
- return false;
- if (that instanceof onStartConfigResyncNotification_args)
- return this.equals((onStartConfigResyncNotification_args)that);
- return false;
- }
-
- public boolean equals(onStartConfigResyncNotification_args that) {
- if (that == null)
- return false;
-
- return true;
- }
-
- @Override
- public int hashCode() {
- List<Object> list = new ArrayList<Object>();
-
- return list.hashCode();
- }
-
- @Override
- public int compareTo(onStartConfigResyncNotification_args other) {
- if (!getClass().equals(other.getClass())) {
- return getClass().getName().compareTo(other.getClass().getName());
- }
-
- int lastComparison = 0;
-
- return 0;
- }
-
- public _Fields fieldForId(int fieldId) {
- return _Fields.findByThriftId(fieldId);
- }
-
- public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
- schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
- }
-
- public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
- schemes.get(oprot.getScheme()).getScheme().write(oprot, this);
- }
-
- @Override
- public String toString() {
- StringBuilder sb = new StringBuilder("onStartConfigResyncNotification_args(");
- boolean first = true;
-
- sb.append(")");
- return sb.toString();
- }
-
- public void validate() throws org.apache.thrift.TException {
- // check for required fields
- // check for sub-struct validity
- }
-
- private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
- try {
- write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
- } catch (org.apache.thrift.TException te) {
- throw new java.io.IOException(te);
- }
- }
-
- private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
- try {
- read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
- } catch (org.apache.thrift.TException te) {
- throw new java.io.IOException(te);
- }
- }
-
- private static class onStartConfigResyncNotification_argsStandardSchemeFactory implements SchemeFactory {
- public onStartConfigResyncNotification_argsStandardScheme getScheme() {
- return new onStartConfigResyncNotification_argsStandardScheme();
- }
- }
-
- private static class onStartConfigResyncNotification_argsStandardScheme extends StandardScheme<onStartConfigResyncNotification_args> {
-
- public void read(org.apache.thrift.protocol.TProtocol iprot, onStartConfigResyncNotification_args struct) throws org.apache.thrift.TException {
- org.apache.thrift.protocol.TField schemeField;
- iprot.readStructBegin();
- while (true)
- {
- schemeField = iprot.readFieldBegin();
- if (schemeField.type == org.apache.thrift.protocol.TType.STOP) {
- break;
- }
- switch (schemeField.id) {
- default:
- org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
- }
- iprot.readFieldEnd();
- }
- iprot.readStructEnd();
-
- // check for required fields of primitive type, which can't be checked in the validate method
- struct.validate();
- }
-
- public void write(org.apache.thrift.protocol.TProtocol oprot, onStartConfigResyncNotification_args struct) throws org.apache.thrift.TException {
- struct.validate();
-
- oprot.writeStructBegin(STRUCT_DESC);
- oprot.writeFieldStop();
- oprot.writeStructEnd();
- }
-
- }
-
- private static class onStartConfigResyncNotification_argsTupleSchemeFactory implements SchemeFactory {
- public onStartConfigResyncNotification_argsTupleScheme getScheme() {
- return new onStartConfigResyncNotification_argsTupleScheme();
- }
- }
-
- private static class onStartConfigResyncNotification_argsTupleScheme extends TupleScheme<onStartConfigResyncNotification_args> {
-
- @Override
- public void write(org.apache.thrift.protocol.TProtocol prot, onStartConfigResyncNotification_args struct) throws org.apache.thrift.TException {
- TTupleProtocol oprot = (TTupleProtocol) prot;
- }
-
- @Override
- public void read(org.apache.thrift.protocol.TProtocol prot, onStartConfigResyncNotification_args struct) throws org.apache.thrift.TException {
- TTupleProtocol iprot = (TTupleProtocol) prot;
- }
- }
-
- }
-
- public static class onNotificationSendEvent_args implements org.apache.thrift.TBase<onNotificationSendEvent_args, onNotificationSendEvent_args._Fields>, java.io.Serializable, Cloneable, Comparable<onNotificationSendEvent_args> {
- private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("onNotificationSendEvent_args");
-
- private static final org.apache.thrift.protocol.TField PREFIX_FIELD_DESC = new org.apache.thrift.protocol.TField("prefix", org.apache.thrift.protocol.TType.STRING, (short)1);
- private static final org.apache.thrift.protocol.TField ERR_CODE_FIELD_DESC = new org.apache.thrift.protocol.TField("errCode", org.apache.thrift.protocol.TType.BYTE, (short)2);
- private static final org.apache.thrift.protocol.TField ERR_SUBCODE_FIELD_DESC = new org.apache.thrift.protocol.TField("errSubcode", org.apache.thrift.protocol.TType.BYTE, (short)3);
-
- private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
- static {
- schemes.put(StandardScheme.class, new onNotificationSendEvent_argsStandardSchemeFactory());
- schemes.put(TupleScheme.class, new onNotificationSendEvent_argsTupleSchemeFactory());
- }
-
- public String prefix; // required
- public byte errCode; // required
- public byte errSubcode; // required
-
- /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
- public enum _Fields implements org.apache.thrift.TFieldIdEnum {
- PREFIX((short)1, "prefix"),
- ERR_CODE((short)2, "errCode"),
- ERR_SUBCODE((short)3, "errSubcode");
-
- private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
-
- static {
- for (_Fields field : EnumSet.allOf(_Fields.class)) {
- byName.put(field.getFieldName(), field);
- }
- }
-
- /**
- * Find the _Fields constant that matches fieldId, or null if its not found.
- */
- public static _Fields findByThriftId(int fieldId) {
- switch(fieldId) {
- case 1: // PREFIX
- return PREFIX;
- case 2: // ERR_CODE
- return ERR_CODE;
- case 3: // ERR_SUBCODE
- return ERR_SUBCODE;
- default:
- return null;
- }
- }
-
- /**
- * Find the _Fields constant that matches fieldId, throwing an exception
- * if it is not found.
- */
- public static _Fields findByThriftIdOrThrow(int fieldId) {
- _Fields fields = findByThriftId(fieldId);
- if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
- return fields;
- }
-
- /**
- * Find the _Fields constant that matches name, or null if its not found.
- */
- public static _Fields findByName(String name) {
- return byName.get(name);
- }
-
- private final short _thriftId;
- private final String _fieldName;
-
- _Fields(short thriftId, String fieldName) {
- _thriftId = thriftId;
- _fieldName = fieldName;
- }
-
- public short getThriftFieldId() {
- return _thriftId;
- }
-
- public String getFieldName() {
- return _fieldName;
- }
- }
-
- // isset id assignments
- private static final int __ERRCODE_ISSET_ID = 0;
- private static final int __ERRSUBCODE_ISSET_ID = 1;
- private byte __isset_bitfield = 0;
- public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
- static {
- Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
- tmpMap.put(_Fields.PREFIX, new org.apache.thrift.meta_data.FieldMetaData("prefix", org.apache.thrift.TFieldRequirementType.DEFAULT,
- new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
- tmpMap.put(_Fields.ERR_CODE, new org.apache.thrift.meta_data.FieldMetaData("errCode", org.apache.thrift.TFieldRequirementType.DEFAULT,
- new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.BYTE)));
- tmpMap.put(_Fields.ERR_SUBCODE, new org.apache.thrift.meta_data.FieldMetaData("errSubcode", org.apache.thrift.TFieldRequirementType.DEFAULT,
- new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.BYTE)));
- metaDataMap = Collections.unmodifiableMap(tmpMap);
- org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(onNotificationSendEvent_args.class, metaDataMap);
- }
-
- public onNotificationSendEvent_args() {
- }
-
- public onNotificationSendEvent_args(
- String prefix,
- byte errCode,
- byte errSubcode)
- {
- this();
- this.prefix = prefix;
- this.errCode = errCode;
- setErrCodeIsSet(true);
- this.errSubcode = errSubcode;
- setErrSubcodeIsSet(true);
- }
-
- /**
- * Performs a deep copy on <i>other</i>.
- */
- public onNotificationSendEvent_args(onNotificationSendEvent_args other) {
- __isset_bitfield = other.__isset_bitfield;
- if (other.isSetPrefix()) {
- this.prefix = other.prefix;
- }
- this.errCode = other.errCode;
- this.errSubcode = other.errSubcode;
- }
-
- public onNotificationSendEvent_args deepCopy() {
- return new onNotificationSendEvent_args(this);
- }
-
- @Override
- public void clear() {
- this.prefix = null;
- setErrCodeIsSet(false);
- this.errCode = 0;
- setErrSubcodeIsSet(false);
- this.errSubcode = 0;
- }
-
- public String getPrefix() {
- return this.prefix;
- }
-
- public onNotificationSendEvent_args setPrefix(String prefix) {
- this.prefix = prefix;
- return this;
- }
-
- public void unsetPrefix() {
- this.prefix = null;
- }
-
- /** Returns true if field prefix is set (has been assigned a value) and false otherwise */
- public boolean isSetPrefix() {
- return this.prefix != null;
- }
-
- public void setPrefixIsSet(boolean value) {
- if (!value) {
- this.prefix = null;
- }
- }
-
- public byte getErrCode() {
- return this.errCode;
- }
-
- public onNotificationSendEvent_args setErrCode(byte errCode) {
- this.errCode = errCode;
- setErrCodeIsSet(true);
- return this;
- }
-
- public void unsetErrCode() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __ERRCODE_ISSET_ID);
- }
-
- /** Returns true if field errCode is set (has been assigned a value) and false otherwise */
- public boolean isSetErrCode() {
- return EncodingUtils.testBit(__isset_bitfield, __ERRCODE_ISSET_ID);
- }
-
- public void setErrCodeIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __ERRCODE_ISSET_ID, value);
- }
-
- public byte getErrSubcode() {
- return this.errSubcode;
- }
-
- public onNotificationSendEvent_args setErrSubcode(byte errSubcode) {
- this.errSubcode = errSubcode;
- setErrSubcodeIsSet(true);
- return this;
- }
-
- public void unsetErrSubcode() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __ERRSUBCODE_ISSET_ID);
- }
-
- /** Returns true if field errSubcode is set (has been assigned a value) and false otherwise */
- public boolean isSetErrSubcode() {
- return EncodingUtils.testBit(__isset_bitfield, __ERRSUBCODE_ISSET_ID);
- }
-
- public void setErrSubcodeIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __ERRSUBCODE_ISSET_ID, value);
- }
-
- public void setFieldValue(_Fields field, Object value) {
- switch (field) {
- case PREFIX:
- if (value == null) {
- unsetPrefix();
- } else {
- setPrefix((String)value);
- }
- break;
-
- case ERR_CODE:
- if (value == null) {
- unsetErrCode();
- } else {
- setErrCode((Byte)value);
- }
- break;
-
- case ERR_SUBCODE:
- if (value == null) {
- unsetErrSubcode();
- } else {
- setErrSubcode((Byte)value);
- }
- break;
-
- }
- }
-
- public Object getFieldValue(_Fields field) {
- switch (field) {
- case PREFIX:
- return getPrefix();
-
- case ERR_CODE:
- return Byte.valueOf(getErrCode());
-
- case ERR_SUBCODE:
- return Byte.valueOf(getErrSubcode());
-
- }
- throw new IllegalStateException();
- }
-
- /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
- public boolean isSet(_Fields field) {
- if (field == null) {
- throw new IllegalArgumentException();
- }
-
- switch (field) {
- case PREFIX:
- return isSetPrefix();
- case ERR_CODE:
- return isSetErrCode();
- case ERR_SUBCODE:
- return isSetErrSubcode();
- }
- throw new IllegalStateException();
- }
-
- @Override
- public boolean equals(Object that) {
- if (that == null)
- return false;
- if (that instanceof onNotificationSendEvent_args)
- return this.equals((onNotificationSendEvent_args)that);
- return false;
- }
-
- public boolean equals(onNotificationSendEvent_args that) {
- if (that == null)
- return false;
-
- boolean this_present_prefix = true && this.isSetPrefix();
- boolean that_present_prefix = true && that.isSetPrefix();
- if (this_present_prefix || that_present_prefix) {
- if (!(this_present_prefix && that_present_prefix))
- return false;
- if (!this.prefix.equals(that.prefix))
- return false;
- }
-
- boolean this_present_errCode = true;
- boolean that_present_errCode = true;
- if (this_present_errCode || that_present_errCode) {
- if (!(this_present_errCode && that_present_errCode))
- return false;
- if (this.errCode != that.errCode)
- return false;
- }
-
- boolean this_present_errSubcode = true;
- boolean that_present_errSubcode = true;
- if (this_present_errSubcode || that_present_errSubcode) {
- if (!(this_present_errSubcode && that_present_errSubcode))
- return false;
- if (this.errSubcode != that.errSubcode)
- return false;
- }
-
- return true;
- }
-
- @Override
- public int hashCode() {
- List<Object> list = new ArrayList<Object>();
-
- boolean present_prefix = true && (isSetPrefix());
- list.add(present_prefix);
- if (present_prefix)
- list.add(prefix);
- boolean present_errCode = true;
- list.add(present_errCode);
- if (present_errCode)
- list.add(errCode);
- boolean present_errSubcode = true;
- list.add(present_errSubcode);
- if (present_errSubcode)
- list.add(errSubcode);
- return list.hashCode();
- }
-
- @Override
- public int compareTo(onNotificationSendEvent_args other) {
- if (!getClass().equals(other.getClass())) {
- return getClass().getName().compareTo(other.getClass().getName());
- }
-
- int lastComparison = 0;
-
- lastComparison = Boolean.valueOf(isSetPrefix()).compareTo(other.isSetPrefix());
- if (lastComparison != 0) {
- return lastComparison;
- }
- if (isSetPrefix()) {
- lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.prefix, other.prefix);
- if (lastComparison != 0) {
- return lastComparison;
- }
- }
- lastComparison = Boolean.valueOf(isSetErrCode()).compareTo(other.isSetErrCode());
- if (lastComparison != 0) {
- return lastComparison;
- }
- if (isSetErrCode()) {
- lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.errCode, other.errCode);
- if (lastComparison != 0) {
- return lastComparison;
- }
- }
- lastComparison = Boolean.valueOf(isSetErrSubcode()).compareTo(other.isSetErrSubcode());
- if (lastComparison != 0) {
- return lastComparison;
- }
- if (isSetErrSubcode()) {
- lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.errSubcode, other.errSubcode);
- if (lastComparison != 0) {
- return lastComparison;
- }
- }
- return 0;
- }
-
- public _Fields fieldForId(int fieldId) {
- return _Fields.findByThriftId(fieldId);
- }
-
- public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
- schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
- }
-
- public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
- schemes.get(oprot.getScheme()).getScheme().write(oprot, this);
- }
-
- @Override
- public String toString() {
- StringBuilder sb = new StringBuilder("onNotificationSendEvent_args(");
- boolean first = true;
-
- sb.append("prefix:");
- if (this.prefix == null) {
- sb.append("null");
- } else {
- sb.append(this.prefix);
- }
- first = false;
- if (!first) sb.append(", ");
- sb.append("errCode:");
- sb.append(this.errCode);
- first = false;
- if (!first) sb.append(", ");
- sb.append("errSubcode:");
- sb.append(this.errSubcode);
- first = false;
- sb.append(")");
- return sb.toString();
- }
-
- public void validate() throws org.apache.thrift.TException {
- // check for required fields
- // check for sub-struct validity
- }
-
- private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
- try {
- write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
- } catch (org.apache.thrift.TException te) {
- throw new java.io.IOException(te);
- }
- }
-
- private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
- try {
- // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
- __isset_bitfield = 0;
- read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
- } catch (org.apache.thrift.TException te) {
- throw new java.io.IOException(te);
- }
- }
-
- private static class onNotificationSendEvent_argsStandardSchemeFactory implements SchemeFactory {
- public onNotificationSendEvent_argsStandardScheme getScheme() {
- return new onNotificationSendEvent_argsStandardScheme();
- }
- }
-
- private static class onNotificationSendEvent_argsStandardScheme extends StandardScheme<onNotificationSendEvent_args> {
-
- public void read(org.apache.thrift.protocol.TProtocol iprot, onNotificationSendEvent_args struct) throws org.apache.thrift.TException {
- org.apache.thrift.protocol.TField schemeField;
- iprot.readStructBegin();
- while (true)
- {
- schemeField = iprot.readFieldBegin();
- if (schemeField.type == org.apache.thrift.protocol.TType.STOP) {
- break;
- }
- switch (schemeField.id) {
- case 1: // PREFIX
- if (schemeField.type == org.apache.thrift.protocol.TType.STRING) {
- struct.prefix = iprot.readString();
- struct.setPrefixIsSet(true);
- } else {
- org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
- }
- break;
- case 2: // ERR_CODE
- if (schemeField.type == org.apache.thrift.protocol.TType.BYTE) {
- struct.errCode = iprot.readByte();
- struct.setErrCodeIsSet(true);
- } else {
- org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
- }
- break;
- case 3: // ERR_SUBCODE
- if (schemeField.type == org.apache.thrift.protocol.TType.BYTE) {
- struct.errSubcode = iprot.readByte();
- struct.setErrSubcodeIsSet(true);
- } else {
- org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
- }
- break;
- default:
- org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
- }
- iprot.readFieldEnd();
- }
- iprot.readStructEnd();
-
- // check for required fields of primitive type, which can't be checked in the validate method
- struct.validate();
- }
-
- public void write(org.apache.thrift.protocol.TProtocol oprot, onNotificationSendEvent_args struct) throws org.apache.thrift.TException {
- struct.validate();
-
- oprot.writeStructBegin(STRUCT_DESC);
- if (struct.prefix != null) {
- oprot.writeFieldBegin(PREFIX_FIELD_DESC);
- oprot.writeString(struct.prefix);
- oprot.writeFieldEnd();
- }
- oprot.writeFieldBegin(ERR_CODE_FIELD_DESC);
- oprot.writeByte(struct.errCode);
- oprot.writeFieldEnd();
- oprot.writeFieldBegin(ERR_SUBCODE_FIELD_DESC);
- oprot.writeByte(struct.errSubcode);
- oprot.writeFieldEnd();
- oprot.writeFieldStop();
- oprot.writeStructEnd();
- }
-
- }
-
- private static class onNotificationSendEvent_argsTupleSchemeFactory implements SchemeFactory {
- public onNotificationSendEvent_argsTupleScheme getScheme() {
- return new onNotificationSendEvent_argsTupleScheme();
- }
- }
-
- private static class onNotificationSendEvent_argsTupleScheme extends TupleScheme<onNotificationSendEvent_args> {
-
- @Override
- public void write(org.apache.thrift.protocol.TProtocol prot, onNotificationSendEvent_args struct) throws org.apache.thrift.TException {
- TTupleProtocol oprot = (TTupleProtocol) prot;
- BitSet optionals = new BitSet();
- if (struct.isSetPrefix()) {
- optionals.set(0);
- }
- if (struct.isSetErrCode()) {
- optionals.set(1);
- }
- if (struct.isSetErrSubcode()) {
- optionals.set(2);
- }
- oprot.writeBitSet(optionals, 3);
- if (struct.isSetPrefix()) {
- oprot.writeString(struct.prefix);
- }
- if (struct.isSetErrCode()) {
- oprot.writeByte(struct.errCode);
- }
- if (struct.isSetErrSubcode()) {
- oprot.writeByte(struct.errSubcode);
- }
- }
-
- @Override
- public void read(org.apache.thrift.protocol.TProtocol prot, onNotificationSendEvent_args struct) throws org.apache.thrift.TException {
- TTupleProtocol iprot = (TTupleProtocol) prot;
- BitSet incoming = iprot.readBitSet(3);
- if (incoming.get(0)) {
- struct.prefix = iprot.readString();
- struct.setPrefixIsSet(true);
- }
- if (incoming.get(1)) {
- struct.errCode = iprot.readByte();
- struct.setErrCodeIsSet(true);
- }
- if (incoming.get(2)) {
- struct.errSubcode = iprot.readByte();
- struct.setErrSubcodeIsSet(true);
- }
- }
- }
-
- }
-
-}
+/**\r
+ * Autogenerated by Thrift Compiler (0.9.3)\r
+ *\r
+ * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING\r
+ * @generated\r
+ */\r
+package org.opendaylight.netvirt.bgpmanager.thrift.gen;\r
+\r
+import org.apache.thrift.scheme.IScheme;\r
+import org.apache.thrift.scheme.SchemeFactory;\r
+import org.apache.thrift.scheme.StandardScheme;\r
+\r
+import org.apache.thrift.scheme.TupleScheme;\r
+import org.apache.thrift.protocol.TTupleProtocol;\r
+import org.apache.thrift.protocol.TProtocolException;\r
+import org.apache.thrift.EncodingUtils;\r
+import org.apache.thrift.TException;\r
+import org.apache.thrift.async.AsyncMethodCallback;\r
+import org.apache.thrift.server.AbstractNonblockingServer.*;\r
+import java.util.List;\r
+import java.util.ArrayList;\r
+import java.util.Map;\r
+import java.util.HashMap;\r
+import java.util.EnumMap;\r
+import java.util.Set;\r
+import java.util.HashSet;\r
+import java.util.EnumSet;\r
+import java.util.Collections;\r
+import java.util.BitSet;\r
+import java.nio.ByteBuffer;\r
+import java.util.Arrays;\r
+import javax.annotation.Generated;\r
+import org.slf4j.Logger;\r
+import org.slf4j.LoggerFactory;\r
+\r
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"})\r
+@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)", date = "2018-04-09")\r
+public class BgpUpdater {\r
+\r
+ public interface Iface {\r
+\r
+ public void onUpdatePushRoute(protocol_type p_type, String rd, String prefix, int prefixlen, String nexthop, long ethtag, String esi, String macaddress, int l3label, int l2label, String routermac, af_afi afi) throws org.apache.thrift.TException;\r
+\r
+ public void onUpdateWithdrawRoute(protocol_type p_type, String rd, String prefix, int prefixlen, String nexthop, long ethtag, String esi, String macaddress, int l3label, int l2label, af_afi afi) throws org.apache.thrift.TException;\r
+\r
+ public void onStartConfigResyncNotification() throws org.apache.thrift.TException;\r
+\r
+ public void onNotificationSendEvent(String prefix, byte errCode, byte errSubcode) throws org.apache.thrift.TException;\r
+\r
+ public void peerDown(String ipAddress, long asNumber) throws org.apache.thrift.TException;\r
+\r
+ public void peerUp(String ipAddress, long asNumber) throws org.apache.thrift.TException;\r
+\r
+ }\r
+\r
+ public interface AsyncIface {\r
+\r
+ public void onUpdatePushRoute(protocol_type p_type, String rd, String prefix, int prefixlen, String nexthop, long ethtag, String esi, String macaddress, int l3label, int l2label, String routermac, af_afi afi, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;\r
+\r
+ public void onUpdateWithdrawRoute(protocol_type p_type, String rd, String prefix, int prefixlen, String nexthop, long ethtag, String esi, String macaddress, int l3label, int l2label, af_afi afi, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;\r
+\r
+ public void onStartConfigResyncNotification(org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;\r
+\r
+ public void onNotificationSendEvent(String prefix, byte errCode, byte errSubcode, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;\r
+\r
+ public void peerDown(String ipAddress, long asNumber, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;\r
+\r
+ public void peerUp(String ipAddress, long asNumber, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;\r
+\r
+ }\r
+\r
+ public static class Client extends org.apache.thrift.TServiceClient implements Iface {\r
+ public static class Factory implements org.apache.thrift.TServiceClientFactory<Client> {\r
+ public Factory() {}\r
+ public Client getClient(org.apache.thrift.protocol.TProtocol prot) {\r
+ return new Client(prot);\r
+ }\r
+ public Client getClient(org.apache.thrift.protocol.TProtocol iprot, org.apache.thrift.protocol.TProtocol oprot) {\r
+ return new Client(iprot, oprot);\r
+ }\r
+ }\r
+\r
+ public Client(org.apache.thrift.protocol.TProtocol prot)\r
+ {\r
+ super(prot, prot);\r
+ }\r
+\r
+ public Client(org.apache.thrift.protocol.TProtocol iprot, org.apache.thrift.protocol.TProtocol oprot) {\r
+ super(iprot, oprot);\r
+ }\r
+\r
+ public void onUpdatePushRoute(protocol_type p_type, String rd, String prefix, int prefixlen, String nexthop, long ethtag, String esi, String macaddress, int l3label, int l2label, String routermac, af_afi afi) throws org.apache.thrift.TException\r
+ {\r
+ send_onUpdatePushRoute(p_type, rd, prefix, prefixlen, nexthop, ethtag, esi, macaddress, l3label, l2label, routermac, afi);\r
+ }\r
+\r
+ public void send_onUpdatePushRoute(protocol_type p_type, String rd, String prefix, int prefixlen, String nexthop, long ethtag, String esi, String macaddress, int l3label, int l2label, String routermac, af_afi afi) throws org.apache.thrift.TException\r
+ {\r
+ onUpdatePushRoute_args args = new onUpdatePushRoute_args();\r
+ args.setP_type(p_type);\r
+ args.setRd(rd);\r
+ args.setPrefix(prefix);\r
+ args.setPrefixlen(prefixlen);\r
+ args.setNexthop(nexthop);\r
+ args.setEthtag(ethtag);\r
+ args.setEsi(esi);\r
+ args.setMacaddress(macaddress);\r
+ args.setL3label(l3label);\r
+ args.setL2label(l2label);\r
+ args.setRoutermac(routermac);\r
+ args.setAfi(afi);\r
+ sendBaseOneway("onUpdatePushRoute", args);\r
+ }\r
+\r
+ public void onUpdateWithdrawRoute(protocol_type p_type, String rd, String prefix, int prefixlen, String nexthop, long ethtag, String esi, String macaddress, int l3label, int l2label, af_afi afi) throws org.apache.thrift.TException\r
+ {\r
+ send_onUpdateWithdrawRoute(p_type, rd, prefix, prefixlen, nexthop, ethtag, esi, macaddress, l3label, l2label, afi);\r
+ }\r
+\r
+ public void send_onUpdateWithdrawRoute(protocol_type p_type, String rd, String prefix, int prefixlen, String nexthop, long ethtag, String esi, String macaddress, int l3label, int l2label, af_afi afi) throws org.apache.thrift.TException\r
+ {\r
+ onUpdateWithdrawRoute_args args = new onUpdateWithdrawRoute_args();\r
+ args.setP_type(p_type);\r
+ args.setRd(rd);\r
+ args.setPrefix(prefix);\r
+ args.setPrefixlen(prefixlen);\r
+ args.setNexthop(nexthop);\r
+ args.setEthtag(ethtag);\r
+ args.setEsi(esi);\r
+ args.setMacaddress(macaddress);\r
+ args.setL3label(l3label);\r
+ args.setL2label(l2label);\r
+ args.setAfi(afi);\r
+ sendBaseOneway("onUpdateWithdrawRoute", args);\r
+ }\r
+\r
+ public void onStartConfigResyncNotification() throws org.apache.thrift.TException\r
+ {\r
+ send_onStartConfigResyncNotification();\r
+ }\r
+\r
+ public void send_onStartConfigResyncNotification() throws org.apache.thrift.TException\r
+ {\r
+ onStartConfigResyncNotification_args args = new onStartConfigResyncNotification_args();\r
+ sendBaseOneway("onStartConfigResyncNotification", args);\r
+ }\r
+\r
+ public void onNotificationSendEvent(String prefix, byte errCode, byte errSubcode) throws org.apache.thrift.TException\r
+ {\r
+ send_onNotificationSendEvent(prefix, errCode, errSubcode);\r
+ }\r
+\r
+ public void send_onNotificationSendEvent(String prefix, byte errCode, byte errSubcode) throws org.apache.thrift.TException\r
+ {\r
+ onNotificationSendEvent_args args = new onNotificationSendEvent_args();\r
+ args.setPrefix(prefix);\r
+ args.setErrCode(errCode);\r
+ args.setErrSubcode(errSubcode);\r
+ sendBaseOneway("onNotificationSendEvent", args);\r
+ }\r
+\r
+ public void peerDown(String ipAddress, long asNumber) throws org.apache.thrift.TException\r
+ {\r
+ send_peerDown(ipAddress, asNumber);\r
+ }\r
+\r
+ public void send_peerDown(String ipAddress, long asNumber) throws org.apache.thrift.TException\r
+ {\r
+ peerDown_args args = new peerDown_args();\r
+ args.setIpAddress(ipAddress);\r
+ args.setAsNumber(asNumber);\r
+ sendBaseOneway("peerDown", args);\r
+ }\r
+\r
+ public void peerUp(String ipAddress, long asNumber) throws org.apache.thrift.TException\r
+ {\r
+ send_peerUp(ipAddress, asNumber);\r
+ }\r
+\r
+ public void send_peerUp(String ipAddress, long asNumber) throws org.apache.thrift.TException\r
+ {\r
+ peerUp_args args = new peerUp_args();\r
+ args.setIpAddress(ipAddress);\r
+ args.setAsNumber(asNumber);\r
+ sendBaseOneway("peerUp", args);\r
+ }\r
+\r
+ }\r
+ public static class AsyncClient extends org.apache.thrift.async.TAsyncClient implements AsyncIface {\r
+ public static class Factory implements org.apache.thrift.async.TAsyncClientFactory<AsyncClient> {\r
+ private org.apache.thrift.async.TAsyncClientManager clientManager;\r
+ private org.apache.thrift.protocol.TProtocolFactory protocolFactory;\r
+ public Factory(org.apache.thrift.async.TAsyncClientManager clientManager, org.apache.thrift.protocol.TProtocolFactory protocolFactory) {\r
+ this.clientManager = clientManager;\r
+ this.protocolFactory = protocolFactory;\r
+ }\r
+ public AsyncClient getAsyncClient(org.apache.thrift.transport.TNonblockingTransport transport) {\r
+ return new AsyncClient(protocolFactory, clientManager, transport);\r
+ }\r
+ }\r
+\r
+ public AsyncClient(org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.async.TAsyncClientManager clientManager, org.apache.thrift.transport.TNonblockingTransport transport) {\r
+ super(protocolFactory, clientManager, transport);\r
+ }\r
+\r
+ public void onUpdatePushRoute(protocol_type p_type, String rd, String prefix, int prefixlen, String nexthop, long ethtag, String esi, String macaddress, int l3label, int l2label, String routermac, af_afi afi, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {\r
+ checkReady();\r
+ onUpdatePushRoute_call method_call = new onUpdatePushRoute_call(p_type, rd, prefix, prefixlen, nexthop, ethtag, esi, macaddress, l3label, l2label, routermac, afi, resultHandler, this, ___protocolFactory, ___transport);\r
+ this.___currentMethod = method_call;\r
+ ___manager.call(method_call);\r
+ }\r
+\r
+ public static class onUpdatePushRoute_call extends org.apache.thrift.async.TAsyncMethodCall {\r
+ private protocol_type p_type;\r
+ private String rd;\r
+ private String prefix;\r
+ private int prefixlen;\r
+ private String nexthop;\r
+ private long ethtag;\r
+ private String esi;\r
+ private String macaddress;\r
+ private int l3label;\r
+ private int l2label;\r
+ private String routermac;\r
+ private af_afi afi;\r
+ public onUpdatePushRoute_call(protocol_type p_type, String rd, String prefix, int prefixlen, String nexthop, long ethtag, String esi, String macaddress, int l3label, int l2label, String routermac, af_afi afi, org.apache.thrift.async.AsyncMethodCallback resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {\r
+ super(client, protocolFactory, transport, resultHandler, true);\r
+ this.p_type = p_type;\r
+ this.rd = rd;\r
+ this.prefix = prefix;\r
+ this.prefixlen = prefixlen;\r
+ this.nexthop = nexthop;\r
+ this.ethtag = ethtag;\r
+ this.esi = esi;\r
+ this.macaddress = macaddress;\r
+ this.l3label = l3label;\r
+ this.l2label = l2label;\r
+ this.routermac = routermac;\r
+ this.afi = afi;\r
+ }\r
+\r
+ public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {\r
+ prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("onUpdatePushRoute", org.apache.thrift.protocol.TMessageType.ONEWAY, 0));\r
+ onUpdatePushRoute_args args = new onUpdatePushRoute_args();\r
+ args.setP_type(p_type);\r
+ args.setRd(rd);\r
+ args.setPrefix(prefix);\r
+ args.setPrefixlen(prefixlen);\r
+ args.setNexthop(nexthop);\r
+ args.setEthtag(ethtag);\r
+ args.setEsi(esi);\r
+ args.setMacaddress(macaddress);\r
+ args.setL3label(l3label);\r
+ args.setL2label(l2label);\r
+ args.setRoutermac(routermac);\r
+ args.setAfi(afi);\r
+ args.write(prot);\r
+ prot.writeMessageEnd();\r
+ }\r
+\r
+ public void getResult() throws org.apache.thrift.TException {\r
+ if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {\r
+ throw new IllegalStateException("Method call not finished!");\r
+ }\r
+ org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());\r
+ org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);\r
+ }\r
+ }\r
+\r
+ public void onUpdateWithdrawRoute(protocol_type p_type, String rd, String prefix, int prefixlen, String nexthop, long ethtag, String esi, String macaddress, int l3label, int l2label, af_afi afi, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {\r
+ checkReady();\r
+ onUpdateWithdrawRoute_call method_call = new onUpdateWithdrawRoute_call(p_type, rd, prefix, prefixlen, nexthop, ethtag, esi, macaddress, l3label, l2label, afi, resultHandler, this, ___protocolFactory, ___transport);\r
+ this.___currentMethod = method_call;\r
+ ___manager.call(method_call);\r
+ }\r
+\r
+ public static class onUpdateWithdrawRoute_call extends org.apache.thrift.async.TAsyncMethodCall {\r
+ private protocol_type p_type;\r
+ private String rd;\r
+ private String prefix;\r
+ private int prefixlen;\r
+ private String nexthop;\r
+ private long ethtag;\r
+ private String esi;\r
+ private String macaddress;\r
+ private int l3label;\r
+ private int l2label;\r
+ private af_afi afi;\r
+ public onUpdateWithdrawRoute_call(protocol_type p_type, String rd, String prefix, int prefixlen, String nexthop, long ethtag, String esi, String macaddress, int l3label, int l2label, af_afi afi, org.apache.thrift.async.AsyncMethodCallback resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {\r
+ super(client, protocolFactory, transport, resultHandler, true);\r
+ this.p_type = p_type;\r
+ this.rd = rd;\r
+ this.prefix = prefix;\r
+ this.prefixlen = prefixlen;\r
+ this.nexthop = nexthop;\r
+ this.ethtag = ethtag;\r
+ this.esi = esi;\r
+ this.macaddress = macaddress;\r
+ this.l3label = l3label;\r
+ this.l2label = l2label;\r
+ this.afi = afi;\r
+ }\r
+\r
+ public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {\r
+ prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("onUpdateWithdrawRoute", org.apache.thrift.protocol.TMessageType.ONEWAY, 0));\r
+ onUpdateWithdrawRoute_args args = new onUpdateWithdrawRoute_args();\r
+ args.setP_type(p_type);\r
+ args.setRd(rd);\r
+ args.setPrefix(prefix);\r
+ args.setPrefixlen(prefixlen);\r
+ args.setNexthop(nexthop);\r
+ args.setEthtag(ethtag);\r
+ args.setEsi(esi);\r
+ args.setMacaddress(macaddress);\r
+ args.setL3label(l3label);\r
+ args.setL2label(l2label);\r
+ args.setAfi(afi);\r
+ args.write(prot);\r
+ prot.writeMessageEnd();\r
+ }\r
+\r
+ public void getResult() throws org.apache.thrift.TException {\r
+ if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {\r
+ throw new IllegalStateException("Method call not finished!");\r
+ }\r
+ org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());\r
+ org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);\r
+ }\r
+ }\r
+\r
+ public void onStartConfigResyncNotification(org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {\r
+ checkReady();\r
+ onStartConfigResyncNotification_call method_call = new onStartConfigResyncNotification_call(resultHandler, this, ___protocolFactory, ___transport);\r
+ this.___currentMethod = method_call;\r
+ ___manager.call(method_call);\r
+ }\r
+\r
+ public static class onStartConfigResyncNotification_call extends org.apache.thrift.async.TAsyncMethodCall {\r
+ public onStartConfigResyncNotification_call(org.apache.thrift.async.AsyncMethodCallback resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {\r
+ super(client, protocolFactory, transport, resultHandler, true);\r
+ }\r
+\r
+ public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {\r
+ prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("onStartConfigResyncNotification", org.apache.thrift.protocol.TMessageType.ONEWAY, 0));\r
+ onStartConfigResyncNotification_args args = new onStartConfigResyncNotification_args();\r
+ args.write(prot);\r
+ prot.writeMessageEnd();\r
+ }\r
+\r
+ public void getResult() throws org.apache.thrift.TException {\r
+ if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {\r
+ throw new IllegalStateException("Method call not finished!");\r
+ }\r
+ org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());\r
+ org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);\r
+ }\r
+ }\r
+\r
+ public void onNotificationSendEvent(String prefix, byte errCode, byte errSubcode, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {\r
+ checkReady();\r
+ onNotificationSendEvent_call method_call = new onNotificationSendEvent_call(prefix, errCode, errSubcode, resultHandler, this, ___protocolFactory, ___transport);\r
+ this.___currentMethod = method_call;\r
+ ___manager.call(method_call);\r
+ }\r
+\r
+ public static class onNotificationSendEvent_call extends org.apache.thrift.async.TAsyncMethodCall {\r
+ private String prefix;\r
+ private byte errCode;\r
+ private byte errSubcode;\r
+ public onNotificationSendEvent_call(String prefix, byte errCode, byte errSubcode, org.apache.thrift.async.AsyncMethodCallback resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {\r
+ super(client, protocolFactory, transport, resultHandler, true);\r
+ this.prefix = prefix;\r
+ this.errCode = errCode;\r
+ this.errSubcode = errSubcode;\r
+ }\r
+\r
+ public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {\r
+ prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("onNotificationSendEvent", org.apache.thrift.protocol.TMessageType.ONEWAY, 0));\r
+ onNotificationSendEvent_args args = new onNotificationSendEvent_args();\r
+ args.setPrefix(prefix);\r
+ args.setErrCode(errCode);\r
+ args.setErrSubcode(errSubcode);\r
+ args.write(prot);\r
+ prot.writeMessageEnd();\r
+ }\r
+\r
+ public void getResult() throws org.apache.thrift.TException {\r
+ if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {\r
+ throw new IllegalStateException("Method call not finished!");\r
+ }\r
+ org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());\r
+ org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);\r
+ }\r
+ }\r
+\r
+ public void peerDown(String ipAddress, long asNumber, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {\r
+ checkReady();\r
+ peerDown_call method_call = new peerDown_call(ipAddress, asNumber, resultHandler, this, ___protocolFactory, ___transport);\r
+ this.___currentMethod = method_call;\r
+ ___manager.call(method_call);\r
+ }\r
+\r
+ public static class peerDown_call extends org.apache.thrift.async.TAsyncMethodCall {\r
+ private String ipAddress;\r
+ private long asNumber;\r
+ public peerDown_call(String ipAddress, long asNumber, org.apache.thrift.async.AsyncMethodCallback resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {\r
+ super(client, protocolFactory, transport, resultHandler, true);\r
+ this.ipAddress = ipAddress;\r
+ this.asNumber = asNumber;\r
+ }\r
+\r
+ public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {\r
+ prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("peerDown", org.apache.thrift.protocol.TMessageType.ONEWAY, 0));\r
+ peerDown_args args = new peerDown_args();\r
+ args.setIpAddress(ipAddress);\r
+ args.setAsNumber(asNumber);\r
+ args.write(prot);\r
+ prot.writeMessageEnd();\r
+ }\r
+\r
+ public void getResult() throws org.apache.thrift.TException {\r
+ if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {\r
+ throw new IllegalStateException("Method call not finished!");\r
+ }\r
+ org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());\r
+ org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);\r
+ }\r
+ }\r
+\r
+ public void peerUp(String ipAddress, long asNumber, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {\r
+ checkReady();\r
+ peerUp_call method_call = new peerUp_call(ipAddress, asNumber, resultHandler, this, ___protocolFactory, ___transport);\r
+ this.___currentMethod = method_call;\r
+ ___manager.call(method_call);\r
+ }\r
+\r
+ public static class peerUp_call extends org.apache.thrift.async.TAsyncMethodCall {\r
+ private String ipAddress;\r
+ private long asNumber;\r
+ public peerUp_call(String ipAddress, long asNumber, org.apache.thrift.async.AsyncMethodCallback resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {\r
+ super(client, protocolFactory, transport, resultHandler, true);\r
+ this.ipAddress = ipAddress;\r
+ this.asNumber = asNumber;\r
+ }\r
+\r
+ public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {\r
+ prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("peerUp", org.apache.thrift.protocol.TMessageType.ONEWAY, 0));\r
+ peerUp_args args = new peerUp_args();\r
+ args.setIpAddress(ipAddress);\r
+ args.setAsNumber(asNumber);\r
+ args.write(prot);\r
+ prot.writeMessageEnd();\r
+ }\r
+\r
+ public void getResult() throws org.apache.thrift.TException {\r
+ if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {\r
+ throw new IllegalStateException("Method call not finished!");\r
+ }\r
+ org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());\r
+ org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);\r
+ }\r
+ }\r
+\r
+ }\r
+\r
+ public static class Processor<I extends Iface> extends org.apache.thrift.TBaseProcessor<I> implements org.apache.thrift.TProcessor {\r
+ private static final Logger LOGGER = LoggerFactory.getLogger(Processor.class.getName());\r
+ public Processor(I iface) {\r
+ super(iface, getProcessMap(new HashMap<String, org.apache.thrift.ProcessFunction<I, ? extends org.apache.thrift.TBase>>()));\r
+ }\r
+\r
+ protected Processor(I iface, Map<String, org.apache.thrift.ProcessFunction<I, ? extends org.apache.thrift.TBase>> processMap) {\r
+ super(iface, getProcessMap(processMap));\r
+ }\r
+\r
+ private static <I extends Iface> Map<String, org.apache.thrift.ProcessFunction<I, ? extends org.apache.thrift.TBase>> getProcessMap(Map<String, org.apache.thrift.ProcessFunction<I, ? extends org.apache.thrift.TBase>> processMap) {\r
+ processMap.put("onUpdatePushRoute", new onUpdatePushRoute());\r
+ processMap.put("onUpdateWithdrawRoute", new onUpdateWithdrawRoute());\r
+ processMap.put("onStartConfigResyncNotification", new onStartConfigResyncNotification());\r
+ processMap.put("onNotificationSendEvent", new onNotificationSendEvent());\r
+ processMap.put("peerDown", new peerDown());\r
+ processMap.put("peerUp", new peerUp());\r
+ return processMap;\r
+ }\r
+\r
+ public static class onUpdatePushRoute<I extends Iface> extends org.apache.thrift.ProcessFunction<I, onUpdatePushRoute_args> {\r
+ public onUpdatePushRoute() {\r
+ super("onUpdatePushRoute");\r
+ }\r
+\r
+ public onUpdatePushRoute_args getEmptyArgsInstance() {\r
+ return new onUpdatePushRoute_args();\r
+ }\r
+\r
+ protected boolean isOneway() {\r
+ return true;\r
+ }\r
+\r
+ public org.apache.thrift.TBase getResult(I iface, onUpdatePushRoute_args args) throws org.apache.thrift.TException {\r
+ iface.onUpdatePushRoute(args.p_type, args.rd, args.prefix, args.prefixlen, args.nexthop, args.ethtag, args.esi, args.macaddress, args.l3label, args.l2label, args.routermac, args.afi);\r
+ return null;\r
+ }\r
+ }\r
+\r
+ public static class onUpdateWithdrawRoute<I extends Iface> extends org.apache.thrift.ProcessFunction<I, onUpdateWithdrawRoute_args> {\r
+ public onUpdateWithdrawRoute() {\r
+ super("onUpdateWithdrawRoute");\r
+ }\r
+\r
+ public onUpdateWithdrawRoute_args getEmptyArgsInstance() {\r
+ return new onUpdateWithdrawRoute_args();\r
+ }\r
+\r
+ protected boolean isOneway() {\r
+ return true;\r
+ }\r
+\r
+ public org.apache.thrift.TBase getResult(I iface, onUpdateWithdrawRoute_args args) throws org.apache.thrift.TException {\r
+ iface.onUpdateWithdrawRoute(args.p_type, args.rd, args.prefix, args.prefixlen, args.nexthop, args.ethtag, args.esi, args.macaddress, args.l3label, args.l2label, args.afi);\r
+ return null;\r
+ }\r
+ }\r
+\r
+ public static class onStartConfigResyncNotification<I extends Iface> extends org.apache.thrift.ProcessFunction<I, onStartConfigResyncNotification_args> {\r
+ public onStartConfigResyncNotification() {\r
+ super("onStartConfigResyncNotification");\r
+ }\r
+\r
+ public onStartConfigResyncNotification_args getEmptyArgsInstance() {\r
+ return new onStartConfigResyncNotification_args();\r
+ }\r
+\r
+ protected boolean isOneway() {\r
+ return true;\r
+ }\r
+\r
+ public org.apache.thrift.TBase getResult(I iface, onStartConfigResyncNotification_args args) throws org.apache.thrift.TException {\r
+ iface.onStartConfigResyncNotification();\r
+ return null;\r
+ }\r
+ }\r
+\r
+ public static class onNotificationSendEvent<I extends Iface> extends org.apache.thrift.ProcessFunction<I, onNotificationSendEvent_args> {\r
+ public onNotificationSendEvent() {\r
+ super("onNotificationSendEvent");\r
+ }\r
+\r
+ public onNotificationSendEvent_args getEmptyArgsInstance() {\r
+ return new onNotificationSendEvent_args();\r
+ }\r
+\r
+ protected boolean isOneway() {\r
+ return true;\r
+ }\r
+\r
+ public org.apache.thrift.TBase getResult(I iface, onNotificationSendEvent_args args) throws org.apache.thrift.TException {\r
+ iface.onNotificationSendEvent(args.prefix, args.errCode, args.errSubcode);\r
+ return null;\r
+ }\r
+ }\r
+\r
+ public static class peerDown<I extends Iface> extends org.apache.thrift.ProcessFunction<I, peerDown_args> {\r
+ public peerDown() {\r
+ super("peerDown");\r
+ }\r
+\r
+ public peerDown_args getEmptyArgsInstance() {\r
+ return new peerDown_args();\r
+ }\r
+\r
+ protected boolean isOneway() {\r
+ return true;\r
+ }\r
+\r
+ public org.apache.thrift.TBase getResult(I iface, peerDown_args args) throws org.apache.thrift.TException {\r
+ iface.peerDown(args.ipAddress, args.asNumber);\r
+ return null;\r
+ }\r
+ }\r
+\r
+ public static class peerUp<I extends Iface> extends org.apache.thrift.ProcessFunction<I, peerUp_args> {\r
+ public peerUp() {\r
+ super("peerUp");\r
+ }\r
+\r
+ public peerUp_args getEmptyArgsInstance() {\r
+ return new peerUp_args();\r
+ }\r
+\r
+ protected boolean isOneway() {\r
+ return true;\r
+ }\r
+\r
+ public org.apache.thrift.TBase getResult(I iface, peerUp_args args) throws org.apache.thrift.TException {\r
+ iface.peerUp(args.ipAddress, args.asNumber);\r
+ return null;\r
+ }\r
+ }\r
+\r
+ }\r
+\r
+ public static class AsyncProcessor<I extends AsyncIface> extends org.apache.thrift.TBaseAsyncProcessor<I> {\r
+ private static final Logger LOGGER = LoggerFactory.getLogger(AsyncProcessor.class.getName());\r
+ public AsyncProcessor(I iface) {\r
+ super(iface, getProcessMap(new HashMap<String, org.apache.thrift.AsyncProcessFunction<I, ? extends org.apache.thrift.TBase, ?>>()));\r
+ }\r
+\r
+ protected AsyncProcessor(I iface, Map<String, org.apache.thrift.AsyncProcessFunction<I, ? extends org.apache.thrift.TBase, ?>> processMap) {\r
+ super(iface, getProcessMap(processMap));\r
+ }\r
+\r
+ private static <I extends AsyncIface> Map<String, org.apache.thrift.AsyncProcessFunction<I, ? extends org.apache.thrift.TBase,?>> getProcessMap(Map<String, org.apache.thrift.AsyncProcessFunction<I, ? extends org.apache.thrift.TBase, ?>> processMap) {\r
+ processMap.put("onUpdatePushRoute", new onUpdatePushRoute());\r
+ processMap.put("onUpdateWithdrawRoute", new onUpdateWithdrawRoute());\r
+ processMap.put("onStartConfigResyncNotification", new onStartConfigResyncNotification());\r
+ processMap.put("onNotificationSendEvent", new onNotificationSendEvent());\r
+ processMap.put("peerDown", new peerDown());\r
+ processMap.put("peerUp", new peerUp());\r
+ return processMap;\r
+ }\r
+\r
+ public static class onUpdatePushRoute<I extends AsyncIface> extends org.apache.thrift.AsyncProcessFunction<I, onUpdatePushRoute_args, Void> {\r
+ public onUpdatePushRoute() {\r
+ super("onUpdatePushRoute");\r
+ }\r
+\r
+ public onUpdatePushRoute_args getEmptyArgsInstance() {\r
+ return new onUpdatePushRoute_args();\r
+ }\r
+\r
+ public AsyncMethodCallback<Void> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {\r
+ final org.apache.thrift.AsyncProcessFunction fcall = this;\r
+ return new AsyncMethodCallback<Void>() {\r
+ public void onComplete(Void o) {\r
+ }\r
+ public void onError(Exception e) {\r
+ }\r
+ };\r
+ }\r
+\r
+ protected boolean isOneway() {\r
+ return true;\r
+ }\r
+\r
+ public void start(I iface, onUpdatePushRoute_args args, org.apache.thrift.async.AsyncMethodCallback<Void> resultHandler) throws TException {\r
+ iface.onUpdatePushRoute(args.p_type, args.rd, args.prefix, args.prefixlen, args.nexthop, args.ethtag, args.esi, args.macaddress, args.l3label, args.l2label, args.routermac, args.afi,resultHandler);\r
+ }\r
+ }\r
+\r
+ public static class onUpdateWithdrawRoute<I extends AsyncIface> extends org.apache.thrift.AsyncProcessFunction<I, onUpdateWithdrawRoute_args, Void> {\r
+ public onUpdateWithdrawRoute() {\r
+ super("onUpdateWithdrawRoute");\r
+ }\r
+\r
+ public onUpdateWithdrawRoute_args getEmptyArgsInstance() {\r
+ return new onUpdateWithdrawRoute_args();\r
+ }\r
+\r
+ public AsyncMethodCallback<Void> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {\r
+ final org.apache.thrift.AsyncProcessFunction fcall = this;\r
+ return new AsyncMethodCallback<Void>() {\r
+ public void onComplete(Void o) {\r
+ }\r
+ public void onError(Exception e) {\r
+ }\r
+ };\r
+ }\r
+\r
+ protected boolean isOneway() {\r
+ return true;\r
+ }\r
+\r
+ public void start(I iface, onUpdateWithdrawRoute_args args, org.apache.thrift.async.AsyncMethodCallback<Void> resultHandler) throws TException {\r
+ iface.onUpdateWithdrawRoute(args.p_type, args.rd, args.prefix, args.prefixlen, args.nexthop, args.ethtag, args.esi, args.macaddress, args.l3label, args.l2label, args.afi,resultHandler);\r
+ }\r
+ }\r
+\r
+ public static class onStartConfigResyncNotification<I extends AsyncIface> extends org.apache.thrift.AsyncProcessFunction<I, onStartConfigResyncNotification_args, Void> {\r
+ public onStartConfigResyncNotification() {\r
+ super("onStartConfigResyncNotification");\r
+ }\r
+\r
+ public onStartConfigResyncNotification_args getEmptyArgsInstance() {\r
+ return new onStartConfigResyncNotification_args();\r
+ }\r
+\r
+ public AsyncMethodCallback<Void> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {\r
+ final org.apache.thrift.AsyncProcessFunction fcall = this;\r
+ return new AsyncMethodCallback<Void>() {\r
+ public void onComplete(Void o) {\r
+ }\r
+ public void onError(Exception e) {\r
+ }\r
+ };\r
+ }\r
+\r
+ protected boolean isOneway() {\r
+ return true;\r
+ }\r
+\r
+ public void start(I iface, onStartConfigResyncNotification_args args, org.apache.thrift.async.AsyncMethodCallback<Void> resultHandler) throws TException {\r
+ iface.onStartConfigResyncNotification(resultHandler);\r
+ }\r
+ }\r
+\r
+ public static class onNotificationSendEvent<I extends AsyncIface> extends org.apache.thrift.AsyncProcessFunction<I, onNotificationSendEvent_args, Void> {\r
+ public onNotificationSendEvent() {\r
+ super("onNotificationSendEvent");\r
+ }\r
+\r
+ public onNotificationSendEvent_args getEmptyArgsInstance() {\r
+ return new onNotificationSendEvent_args();\r
+ }\r
+\r
+ public AsyncMethodCallback<Void> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {\r
+ final org.apache.thrift.AsyncProcessFunction fcall = this;\r
+ return new AsyncMethodCallback<Void>() {\r
+ public void onComplete(Void o) {\r
+ }\r
+ public void onError(Exception e) {\r
+ }\r
+ };\r
+ }\r
+\r
+ protected boolean isOneway() {\r
+ return true;\r
+ }\r
+\r
+ public void start(I iface, onNotificationSendEvent_args args, org.apache.thrift.async.AsyncMethodCallback<Void> resultHandler) throws TException {\r
+ iface.onNotificationSendEvent(args.prefix, args.errCode, args.errSubcode,resultHandler);\r
+ }\r
+ }\r
+\r
+ public static class peerDown<I extends AsyncIface> extends org.apache.thrift.AsyncProcessFunction<I, peerDown_args, Void> {\r
+ public peerDown() {\r
+ super("peerDown");\r
+ }\r
+\r
+ public peerDown_args getEmptyArgsInstance() {\r
+ return new peerDown_args();\r
+ }\r
+\r
+ public AsyncMethodCallback<Void> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {\r
+ final org.apache.thrift.AsyncProcessFunction fcall = this;\r
+ return new AsyncMethodCallback<Void>() {\r
+ public void onComplete(Void o) {\r
+ }\r
+ public void onError(Exception e) {\r
+ }\r
+ };\r
+ }\r
+\r
+ protected boolean isOneway() {\r
+ return true;\r
+ }\r
+\r
+ public void start(I iface, peerDown_args args, org.apache.thrift.async.AsyncMethodCallback<Void> resultHandler) throws TException {\r
+ iface.peerDown(args.ipAddress, args.asNumber,resultHandler);\r
+ }\r
+ }\r
+\r
+ public static class peerUp<I extends AsyncIface> extends org.apache.thrift.AsyncProcessFunction<I, peerUp_args, Void> {\r
+ public peerUp() {\r
+ super("peerUp");\r
+ }\r
+\r
+ public peerUp_args getEmptyArgsInstance() {\r
+ return new peerUp_args();\r
+ }\r
+\r
+ public AsyncMethodCallback<Void> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {\r
+ final org.apache.thrift.AsyncProcessFunction fcall = this;\r
+ return new AsyncMethodCallback<Void>() {\r
+ public void onComplete(Void o) {\r
+ }\r
+ public void onError(Exception e) {\r
+ }\r
+ };\r
+ }\r
+\r
+ protected boolean isOneway() {\r
+ return true;\r
+ }\r
+\r
+ public void start(I iface, peerUp_args args, org.apache.thrift.async.AsyncMethodCallback<Void> resultHandler) throws TException {\r
+ iface.peerUp(args.ipAddress, args.asNumber,resultHandler);\r
+ }\r
+ }\r
+\r
+ }\r
+\r
+ public static class onUpdatePushRoute_args implements org.apache.thrift.TBase<onUpdatePushRoute_args, onUpdatePushRoute_args._Fields>, java.io.Serializable, Cloneable, Comparable<onUpdatePushRoute_args> {\r
+ private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("onUpdatePushRoute_args");\r
+\r
+ private static final org.apache.thrift.protocol.TField P_TYPE_FIELD_DESC = new org.apache.thrift.protocol.TField("p_type", org.apache.thrift.protocol.TType.I32, (short)1);\r
+ private static final org.apache.thrift.protocol.TField RD_FIELD_DESC = new org.apache.thrift.protocol.TField("rd", org.apache.thrift.protocol.TType.STRING, (short)2);\r
+ private static final org.apache.thrift.protocol.TField PREFIX_FIELD_DESC = new org.apache.thrift.protocol.TField("prefix", org.apache.thrift.protocol.TType.STRING, (short)3);\r
+ private static final org.apache.thrift.protocol.TField PREFIXLEN_FIELD_DESC = new org.apache.thrift.protocol.TField("prefixlen", org.apache.thrift.protocol.TType.I32, (short)4);\r
+ private static final org.apache.thrift.protocol.TField NEXTHOP_FIELD_DESC = new org.apache.thrift.protocol.TField("nexthop", org.apache.thrift.protocol.TType.STRING, (short)5);\r
+ private static final org.apache.thrift.protocol.TField ETHTAG_FIELD_DESC = new org.apache.thrift.protocol.TField("ethtag", org.apache.thrift.protocol.TType.I64, (short)6);\r
+ private static final org.apache.thrift.protocol.TField ESI_FIELD_DESC = new org.apache.thrift.protocol.TField("esi", org.apache.thrift.protocol.TType.STRING, (short)7);\r
+ private static final org.apache.thrift.protocol.TField MACADDRESS_FIELD_DESC = new org.apache.thrift.protocol.TField("macaddress", org.apache.thrift.protocol.TType.STRING, (short)8);\r
+ private static final org.apache.thrift.protocol.TField L3LABEL_FIELD_DESC = new org.apache.thrift.protocol.TField("l3label", org.apache.thrift.protocol.TType.I32, (short)9);\r
+ private static final org.apache.thrift.protocol.TField L2LABEL_FIELD_DESC = new org.apache.thrift.protocol.TField("l2label", org.apache.thrift.protocol.TType.I32, (short)10);\r
+ private static final org.apache.thrift.protocol.TField ROUTERMAC_FIELD_DESC = new org.apache.thrift.protocol.TField("routermac", org.apache.thrift.protocol.TType.STRING, (short)11);\r
+ private static final org.apache.thrift.protocol.TField AFI_FIELD_DESC = new org.apache.thrift.protocol.TField("afi", org.apache.thrift.protocol.TType.I32, (short)12);\r
+\r
+ private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();\r
+ static {\r
+ schemes.put(StandardScheme.class, new onUpdatePushRoute_argsStandardSchemeFactory());\r
+ schemes.put(TupleScheme.class, new onUpdatePushRoute_argsTupleSchemeFactory());\r
+ }\r
+\r
+ /**\r
+ *\r
+ * @see protocol_type\r
+ */\r
+ public protocol_type p_type; // required\r
+ public String rd; // required\r
+ public String prefix; // required\r
+ public int prefixlen; // required\r
+ public String nexthop; // required\r
+ public long ethtag; // required\r
+ public String esi; // required\r
+ public String macaddress; // required\r
+ public int l3label; // required\r
+ public int l2label; // required\r
+ public String routermac; // required\r
+ /**\r
+ *\r
+ * @see af_afi\r
+ */\r
+ public af_afi afi; // required\r
+\r
+ /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */\r
+ public enum _Fields implements org.apache.thrift.TFieldIdEnum {\r
+ /**\r
+ *\r
+ * @see protocol_type\r
+ */\r
+ P_TYPE((short)1, "p_type"),\r
+ RD((short)2, "rd"),\r
+ PREFIX((short)3, "prefix"),\r
+ PREFIXLEN((short)4, "prefixlen"),\r
+ NEXTHOP((short)5, "nexthop"),\r
+ ETHTAG((short)6, "ethtag"),\r
+ ESI((short)7, "esi"),\r
+ MACADDRESS((short)8, "macaddress"),\r
+ L3LABEL((short)9, "l3label"),\r
+ L2LABEL((short)10, "l2label"),\r
+ ROUTERMAC((short)11, "routermac"),\r
+ /**\r
+ *\r
+ * @see af_afi\r
+ */\r
+ AFI((short)12, "afi");\r
+\r
+ private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();\r
+\r
+ static {\r
+ for (_Fields field : EnumSet.allOf(_Fields.class)) {\r
+ byName.put(field.getFieldName(), field);\r
+ }\r
+ }\r
+\r
+ /**\r
+ * Find the _Fields constant that matches fieldId, or null if its not found.\r
+ */\r
+ public static _Fields findByThriftId(int fieldId) {\r
+ switch(fieldId) {\r
+ case 1: // P_TYPE\r
+ return P_TYPE;\r
+ case 2: // RD\r
+ return RD;\r
+ case 3: // PREFIX\r
+ return PREFIX;\r
+ case 4: // PREFIXLEN\r
+ return PREFIXLEN;\r
+ case 5: // NEXTHOP\r
+ return NEXTHOP;\r
+ case 6: // ETHTAG\r
+ return ETHTAG;\r
+ case 7: // ESI\r
+ return ESI;\r
+ case 8: // MACADDRESS\r
+ return MACADDRESS;\r
+ case 9: // L3LABEL\r
+ return L3LABEL;\r
+ case 10: // L2LABEL\r
+ return L2LABEL;\r
+ case 11: // ROUTERMAC\r
+ return ROUTERMAC;\r
+ case 12: // AFI\r
+ return AFI;\r
+ default:\r
+ return null;\r
+ }\r
+ }\r
+\r
+ /**\r
+ * Find the _Fields constant that matches fieldId, throwing an exception\r
+ * if it is not found.\r
+ */\r
+ public static _Fields findByThriftIdOrThrow(int fieldId) {\r
+ _Fields fields = findByThriftId(fieldId);\r
+ if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");\r
+ return fields;\r
+ }\r
+\r
+ /**\r
+ * Find the _Fields constant that matches name, or null if its not found.\r
+ */\r
+ public static _Fields findByName(String name) {\r
+ return byName.get(name);\r
+ }\r
+\r
+ private final short _thriftId;\r
+ private final String _fieldName;\r
+\r
+ _Fields(short thriftId, String fieldName) {\r
+ _thriftId = thriftId;\r
+ _fieldName = fieldName;\r
+ }\r
+\r
+ public short getThriftFieldId() {\r
+ return _thriftId;\r
+ }\r
+\r
+ public String getFieldName() {\r
+ return _fieldName;\r
+ }\r
+ }\r
+\r
+ // isset id assignments\r
+ private static final int __PREFIXLEN_ISSET_ID = 0;\r
+ private static final int __ETHTAG_ISSET_ID = 1;\r
+ private static final int __L3LABEL_ISSET_ID = 2;\r
+ private static final int __L2LABEL_ISSET_ID = 3;\r
+ private byte __isset_bitfield = 0;\r
+ public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;\r
+ static {\r
+ Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);\r
+ tmpMap.put(_Fields.P_TYPE, new org.apache.thrift.meta_data.FieldMetaData("p_type", org.apache.thrift.TFieldRequirementType.DEFAULT,\r
+ new org.apache.thrift.meta_data.EnumMetaData(org.apache.thrift.protocol.TType.ENUM, protocol_type.class)));\r
+ tmpMap.put(_Fields.RD, new org.apache.thrift.meta_data.FieldMetaData("rd", org.apache.thrift.TFieldRequirementType.DEFAULT,\r
+ new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));\r
+ tmpMap.put(_Fields.PREFIX, new org.apache.thrift.meta_data.FieldMetaData("prefix", org.apache.thrift.TFieldRequirementType.DEFAULT,\r
+ new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));\r
+ tmpMap.put(_Fields.PREFIXLEN, new org.apache.thrift.meta_data.FieldMetaData("prefixlen", org.apache.thrift.TFieldRequirementType.DEFAULT,\r
+ new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I32)));\r
+ tmpMap.put(_Fields.NEXTHOP, new org.apache.thrift.meta_data.FieldMetaData("nexthop", org.apache.thrift.TFieldRequirementType.DEFAULT,\r
+ new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));\r
+ tmpMap.put(_Fields.ETHTAG, new org.apache.thrift.meta_data.FieldMetaData("ethtag", org.apache.thrift.TFieldRequirementType.DEFAULT,\r
+ new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));\r
+ tmpMap.put(_Fields.ESI, new org.apache.thrift.meta_data.FieldMetaData("esi", org.apache.thrift.TFieldRequirementType.DEFAULT,\r
+ new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));\r
+ tmpMap.put(_Fields.MACADDRESS, new org.apache.thrift.meta_data.FieldMetaData("macaddress", org.apache.thrift.TFieldRequirementType.DEFAULT,\r
+ new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));\r
+ tmpMap.put(_Fields.L3LABEL, new org.apache.thrift.meta_data.FieldMetaData("l3label", org.apache.thrift.TFieldRequirementType.DEFAULT,\r
+ new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I32)));\r
+ tmpMap.put(_Fields.L2LABEL, new org.apache.thrift.meta_data.FieldMetaData("l2label", org.apache.thrift.TFieldRequirementType.DEFAULT,\r
+ new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I32)));\r
+ tmpMap.put(_Fields.ROUTERMAC, new org.apache.thrift.meta_data.FieldMetaData("routermac", org.apache.thrift.TFieldRequirementType.DEFAULT,\r
+ new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));\r
+ tmpMap.put(_Fields.AFI, new org.apache.thrift.meta_data.FieldMetaData("afi", org.apache.thrift.TFieldRequirementType.DEFAULT,\r
+ new org.apache.thrift.meta_data.EnumMetaData(org.apache.thrift.protocol.TType.ENUM, af_afi.class)));\r
+ metaDataMap = Collections.unmodifiableMap(tmpMap);\r
+ org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(onUpdatePushRoute_args.class, metaDataMap);\r
+ }\r
+\r
+ public onUpdatePushRoute_args() {\r
+ }\r
+\r
+ public onUpdatePushRoute_args(\r
+ protocol_type p_type,\r
+ String rd,\r
+ String prefix,\r
+ int prefixlen,\r
+ String nexthop,\r
+ long ethtag,\r
+ String esi,\r
+ String macaddress,\r
+ int l3label,\r
+ int l2label,\r
+ String routermac,\r
+ af_afi afi)\r
+ {\r
+ this();\r
+ this.p_type = p_type;\r
+ this.rd = rd;\r
+ this.prefix = prefix;\r
+ this.prefixlen = prefixlen;\r
+ setPrefixlenIsSet(true);\r
+ this.nexthop = nexthop;\r
+ this.ethtag = ethtag;\r
+ setEthtagIsSet(true);\r
+ this.esi = esi;\r
+ this.macaddress = macaddress;\r
+ this.l3label = l3label;\r
+ setL3labelIsSet(true);\r
+ this.l2label = l2label;\r
+ setL2labelIsSet(true);\r
+ this.routermac = routermac;\r
+ this.afi = afi;\r
+ }\r
+\r
+ /**\r
+ * Performs a deep copy on <i>other</i>.\r
+ */\r
+ public onUpdatePushRoute_args(onUpdatePushRoute_args other) {\r
+ __isset_bitfield = other.__isset_bitfield;\r
+ if (other.isSetP_type()) {\r
+ this.p_type = other.p_type;\r
+ }\r
+ if (other.isSetRd()) {\r
+ this.rd = other.rd;\r
+ }\r
+ if (other.isSetPrefix()) {\r
+ this.prefix = other.prefix;\r
+ }\r
+ this.prefixlen = other.prefixlen;\r
+ if (other.isSetNexthop()) {\r
+ this.nexthop = other.nexthop;\r
+ }\r
+ this.ethtag = other.ethtag;\r
+ if (other.isSetEsi()) {\r
+ this.esi = other.esi;\r
+ }\r
+ if (other.isSetMacaddress()) {\r
+ this.macaddress = other.macaddress;\r
+ }\r
+ this.l3label = other.l3label;\r
+ this.l2label = other.l2label;\r
+ if (other.isSetRoutermac()) {\r
+ this.routermac = other.routermac;\r
+ }\r
+ if (other.isSetAfi()) {\r
+ this.afi = other.afi;\r
+ }\r
+ }\r
+\r
+ public onUpdatePushRoute_args deepCopy() {\r
+ return new onUpdatePushRoute_args(this);\r
+ }\r
+\r
+ @Override\r
+ public void clear() {\r
+ this.p_type = null;\r
+ this.rd = null;\r
+ this.prefix = null;\r
+ setPrefixlenIsSet(false);\r
+ this.prefixlen = 0;\r
+ this.nexthop = null;\r
+ setEthtagIsSet(false);\r
+ this.ethtag = 0;\r
+ this.esi = null;\r
+ this.macaddress = null;\r
+ setL3labelIsSet(false);\r
+ this.l3label = 0;\r
+ setL2labelIsSet(false);\r
+ this.l2label = 0;\r
+ this.routermac = null;\r
+ this.afi = null;\r
+ }\r
+\r
+ /**\r
+ *\r
+ * @see protocol_type\r
+ */\r
+ public protocol_type getP_type() {\r
+ return this.p_type;\r
+ }\r
+\r
+ /**\r
+ *\r
+ * @see protocol_type\r
+ */\r
+ public onUpdatePushRoute_args setP_type(protocol_type p_type) {\r
+ this.p_type = p_type;\r
+ return this;\r
+ }\r
+\r
+ public void unsetP_type() {\r
+ this.p_type = null;\r
+ }\r
+\r
+ /** Returns true if field p_type is set (has been assigned a value) and false otherwise */\r
+ public boolean isSetP_type() {\r
+ return this.p_type != null;\r
+ }\r
+\r
+ public void setP_typeIsSet(boolean value) {\r
+ if (!value) {\r
+ this.p_type = null;\r
+ }\r
+ }\r
+\r
+ public String getRd() {\r
+ return this.rd;\r
+ }\r
+\r
+ public onUpdatePushRoute_args setRd(String rd) {\r
+ this.rd = rd;\r
+ return this;\r
+ }\r
+\r
+ public void unsetRd() {\r
+ this.rd = null;\r
+ }\r
+\r
+ /** Returns true if field rd is set (has been assigned a value) and false otherwise */\r
+ public boolean isSetRd() {\r
+ return this.rd != null;\r
+ }\r
+\r
+ public void setRdIsSet(boolean value) {\r
+ if (!value) {\r
+ this.rd = null;\r
+ }\r
+ }\r
+\r
+ public String getPrefix() {\r
+ return this.prefix;\r
+ }\r
+\r
+ public onUpdatePushRoute_args setPrefix(String prefix) {\r
+ this.prefix = prefix;\r
+ return this;\r
+ }\r
+\r
+ public void unsetPrefix() {\r
+ this.prefix = null;\r
+ }\r
+\r
+ /** Returns true if field prefix is set (has been assigned a value) and false otherwise */\r
+ public boolean isSetPrefix() {\r
+ return this.prefix != null;\r
+ }\r
+\r
+ public void setPrefixIsSet(boolean value) {\r
+ if (!value) {\r
+ this.prefix = null;\r
+ }\r
+ }\r
+\r
+ public int getPrefixlen() {\r
+ return this.prefixlen;\r
+ }\r
+\r
+ public onUpdatePushRoute_args setPrefixlen(int prefixlen) {\r
+ this.prefixlen = prefixlen;\r
+ setPrefixlenIsSet(true);\r
+ return this;\r
+ }\r
+\r
+ public void unsetPrefixlen() {\r
+ __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __PREFIXLEN_ISSET_ID);\r
+ }\r
+\r
+ /** Returns true if field prefixlen is set (has been assigned a value) and false otherwise */\r
+ public boolean isSetPrefixlen() {\r
+ return EncodingUtils.testBit(__isset_bitfield, __PREFIXLEN_ISSET_ID);\r
+ }\r
+\r
+ public void setPrefixlenIsSet(boolean value) {\r
+ __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __PREFIXLEN_ISSET_ID, value);\r
+ }\r
+\r
+ public String getNexthop() {\r
+ return this.nexthop;\r
+ }\r
+\r
+ public onUpdatePushRoute_args setNexthop(String nexthop) {\r
+ this.nexthop = nexthop;\r
+ return this;\r
+ }\r
+\r
+ public void unsetNexthop() {\r
+ this.nexthop = null;\r
+ }\r
+\r
+ /** Returns true if field nexthop is set (has been assigned a value) and false otherwise */\r
+ public boolean isSetNexthop() {\r
+ return this.nexthop != null;\r
+ }\r
+\r
+ public void setNexthopIsSet(boolean value) {\r
+ if (!value) {\r
+ this.nexthop = null;\r
+ }\r
+ }\r
+\r
+ public long getEthtag() {\r
+ return this.ethtag;\r
+ }\r
+\r
+ public onUpdatePushRoute_args setEthtag(long ethtag) {\r
+ this.ethtag = ethtag;\r
+ setEthtagIsSet(true);\r
+ return this;\r
+ }\r
+\r
+ public void unsetEthtag() {\r
+ __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __ETHTAG_ISSET_ID);\r
+ }\r
+\r
+ /** Returns true if field ethtag is set (has been assigned a value) and false otherwise */\r
+ public boolean isSetEthtag() {\r
+ return EncodingUtils.testBit(__isset_bitfield, __ETHTAG_ISSET_ID);\r
+ }\r
+\r
+ public void setEthtagIsSet(boolean value) {\r
+ __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __ETHTAG_ISSET_ID, value);\r
+ }\r
+\r
+ public String getEsi() {\r
+ return this.esi;\r
+ }\r
+\r
+ public onUpdatePushRoute_args setEsi(String esi) {\r
+ this.esi = esi;\r
+ return this;\r
+ }\r
+\r
+ public void unsetEsi() {\r
+ this.esi = null;\r
+ }\r
+\r
+ /** Returns true if field esi is set (has been assigned a value) and false otherwise */\r
+ public boolean isSetEsi() {\r
+ return this.esi != null;\r
+ }\r
+\r
+ public void setEsiIsSet(boolean value) {\r
+ if (!value) {\r
+ this.esi = null;\r
+ }\r
+ }\r
+\r
+ public String getMacaddress() {\r
+ return this.macaddress;\r
+ }\r
+\r
+ public onUpdatePushRoute_args setMacaddress(String macaddress) {\r
+ this.macaddress = macaddress;\r
+ return this;\r
+ }\r
+\r
+ public void unsetMacaddress() {\r
+ this.macaddress = null;\r
+ }\r
+\r
+ /** Returns true if field macaddress is set (has been assigned a value) and false otherwise */\r
+ public boolean isSetMacaddress() {\r
+ return this.macaddress != null;\r
+ }\r
+\r
+ public void setMacaddressIsSet(boolean value) {\r
+ if (!value) {\r
+ this.macaddress = null;\r
+ }\r
+ }\r
+\r
+ public int getL3label() {\r
+ return this.l3label;\r
+ }\r
+\r
+ public onUpdatePushRoute_args setL3label(int l3label) {\r
+ this.l3label = l3label;\r
+ setL3labelIsSet(true);\r
+ return this;\r
+ }\r
+\r
+ public void unsetL3label() {\r
+ __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __L3LABEL_ISSET_ID);\r
+ }\r
+\r
+ /** Returns true if field l3label is set (has been assigned a value) and false otherwise */\r
+ public boolean isSetL3label() {\r
+ return EncodingUtils.testBit(__isset_bitfield, __L3LABEL_ISSET_ID);\r
+ }\r
+\r
+ public void setL3labelIsSet(boolean value) {\r
+ __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __L3LABEL_ISSET_ID, value);\r
+ }\r
+\r
+ public int getL2label() {\r
+ return this.l2label;\r
+ }\r
+\r
+ public onUpdatePushRoute_args setL2label(int l2label) {\r
+ this.l2label = l2label;\r
+ setL2labelIsSet(true);\r
+ return this;\r
+ }\r
+\r
+ public void unsetL2label() {\r
+ __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __L2LABEL_ISSET_ID);\r
+ }\r
+\r
+ /** Returns true if field l2label is set (has been assigned a value) and false otherwise */\r
+ public boolean isSetL2label() {\r
+ return EncodingUtils.testBit(__isset_bitfield, __L2LABEL_ISSET_ID);\r
+ }\r
+\r
+ public void setL2labelIsSet(boolean value) {\r
+ __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __L2LABEL_ISSET_ID, value);\r
+ }\r
+\r
+ public String getRoutermac() {\r
+ return this.routermac;\r
+ }\r
+\r
+ public onUpdatePushRoute_args setRoutermac(String routermac) {\r
+ this.routermac = routermac;\r
+ return this;\r
+ }\r
+\r
+ public void unsetRoutermac() {\r
+ this.routermac = null;\r
+ }\r
+\r
+ /** Returns true if field routermac is set (has been assigned a value) and false otherwise */\r
+ public boolean isSetRoutermac() {\r
+ return this.routermac != null;\r
+ }\r
+\r
+ public void setRoutermacIsSet(boolean value) {\r
+ if (!value) {\r
+ this.routermac = null;\r
+ }\r
+ }\r
+\r
+ /**\r
+ *\r
+ * @see af_afi\r
+ */\r
+ public af_afi getAfi() {\r
+ return this.afi;\r
+ }\r
+\r
+ /**\r
+ *\r
+ * @see af_afi\r
+ */\r
+ public onUpdatePushRoute_args setAfi(af_afi afi) {\r
+ this.afi = afi;\r
+ return this;\r
+ }\r
+\r
+ public void unsetAfi() {\r
+ this.afi = null;\r
+ }\r
+\r
+ /** Returns true if field afi is set (has been assigned a value) and false otherwise */\r
+ public boolean isSetAfi() {\r
+ return this.afi != null;\r
+ }\r
+\r
+ public void setAfiIsSet(boolean value) {\r
+ if (!value) {\r
+ this.afi = null;\r
+ }\r
+ }\r
+\r
+ public void setFieldValue(_Fields field, Object value) {\r
+ switch (field) {\r
+ case P_TYPE:\r
+ if (value == null) {\r
+ unsetP_type();\r
+ } else {\r
+ setP_type((protocol_type)value);\r
+ }\r
+ break;\r
+\r
+ case RD:\r
+ if (value == null) {\r
+ unsetRd();\r
+ } else {\r
+ setRd((String)value);\r
+ }\r
+ break;\r
+\r
+ case PREFIX:\r
+ if (value == null) {\r
+ unsetPrefix();\r
+ } else {\r
+ setPrefix((String)value);\r
+ }\r
+ break;\r
+\r
+ case PREFIXLEN:\r
+ if (value == null) {\r
+ unsetPrefixlen();\r
+ } else {\r
+ setPrefixlen((Integer)value);\r
+ }\r
+ break;\r
+\r
+ case NEXTHOP:\r
+ if (value == null) {\r
+ unsetNexthop();\r
+ } else {\r
+ setNexthop((String)value);\r
+ }\r
+ break;\r
+\r
+ case ETHTAG:\r
+ if (value == null) {\r
+ unsetEthtag();\r
+ } else {\r
+ setEthtag((Long)value);\r
+ }\r
+ break;\r
+\r
+ case ESI:\r
+ if (value == null) {\r
+ unsetEsi();\r
+ } else {\r
+ setEsi((String)value);\r
+ }\r
+ break;\r
+\r
+ case MACADDRESS:\r
+ if (value == null) {\r
+ unsetMacaddress();\r
+ } else {\r
+ setMacaddress((String)value);\r
+ }\r
+ break;\r
+\r
+ case L3LABEL:\r
+ if (value == null) {\r
+ unsetL3label();\r
+ } else {\r
+ setL3label((Integer)value);\r
+ }\r
+ break;\r
+\r
+ case L2LABEL:\r
+ if (value == null) {\r
+ unsetL2label();\r
+ } else {\r
+ setL2label((Integer)value);\r
+ }\r
+ break;\r
+\r
+ case ROUTERMAC:\r
+ if (value == null) {\r
+ unsetRoutermac();\r
+ } else {\r
+ setRoutermac((String)value);\r
+ }\r
+ break;\r
+\r
+ case AFI:\r
+ if (value == null) {\r
+ unsetAfi();\r
+ } else {\r
+ setAfi((af_afi)value);\r
+ }\r
+ break;\r
+\r
+ }\r
+ }\r
+\r
+ public Object getFieldValue(_Fields field) {\r
+ switch (field) {\r
+ case P_TYPE:\r
+ return getP_type();\r
+\r
+ case RD:\r
+ return getRd();\r
+\r
+ case PREFIX:\r
+ return getPrefix();\r
+\r
+ case PREFIXLEN:\r
+ return getPrefixlen();\r
+\r
+ case NEXTHOP:\r
+ return getNexthop();\r
+\r
+ case ETHTAG:\r
+ return getEthtag();\r
+\r
+ case ESI:\r
+ return getEsi();\r
+\r
+ case MACADDRESS:\r
+ return getMacaddress();\r
+\r
+ case L3LABEL:\r
+ return getL3label();\r
+\r
+ case L2LABEL:\r
+ return getL2label();\r
+\r
+ case ROUTERMAC:\r
+ return getRoutermac();\r
+\r
+ case AFI:\r
+ return getAfi();\r
+\r
+ }\r
+ throw new IllegalStateException();\r
+ }\r
+\r
+ /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */\r
+ public boolean isSet(_Fields field) {\r
+ if (field == null) {\r
+ throw new IllegalArgumentException();\r
+ }\r
+\r
+ switch (field) {\r
+ case P_TYPE:\r
+ return isSetP_type();\r
+ case RD:\r
+ return isSetRd();\r
+ case PREFIX:\r
+ return isSetPrefix();\r
+ case PREFIXLEN:\r
+ return isSetPrefixlen();\r
+ case NEXTHOP:\r
+ return isSetNexthop();\r
+ case ETHTAG:\r
+ return isSetEthtag();\r
+ case ESI:\r
+ return isSetEsi();\r
+ case MACADDRESS:\r
+ return isSetMacaddress();\r
+ case L3LABEL:\r
+ return isSetL3label();\r
+ case L2LABEL:\r
+ return isSetL2label();\r
+ case ROUTERMAC:\r
+ return isSetRoutermac();\r
+ case AFI:\r
+ return isSetAfi();\r
+ }\r
+ throw new IllegalStateException();\r
+ }\r
+\r
+ @Override\r
+ public boolean equals(Object that) {\r
+ if (that == null)\r
+ return false;\r
+ if (that instanceof onUpdatePushRoute_args)\r
+ return this.equals((onUpdatePushRoute_args)that);\r
+ return false;\r
+ }\r
+\r
+ public boolean equals(onUpdatePushRoute_args that) {\r
+ if (that == null)\r
+ return false;\r
+\r
+ boolean this_present_p_type = true && this.isSetP_type();\r
+ boolean that_present_p_type = true && that.isSetP_type();\r
+ if (this_present_p_type || that_present_p_type) {\r
+ if (!(this_present_p_type && that_present_p_type))\r
+ return false;\r
+ if (!this.p_type.equals(that.p_type))\r
+ return false;\r
+ }\r
+\r
+ boolean this_present_rd = true && this.isSetRd();\r
+ boolean that_present_rd = true && that.isSetRd();\r
+ if (this_present_rd || that_present_rd) {\r
+ if (!(this_present_rd && that_present_rd))\r
+ return false;\r
+ if (!this.rd.equals(that.rd))\r
+ return false;\r
+ }\r
+\r
+ boolean this_present_prefix = true && this.isSetPrefix();\r
+ boolean that_present_prefix = true && that.isSetPrefix();\r
+ if (this_present_prefix || that_present_prefix) {\r
+ if (!(this_present_prefix && that_present_prefix))\r
+ return false;\r
+ if (!this.prefix.equals(that.prefix))\r
+ return false;\r
+ }\r
+\r
+ boolean this_present_prefixlen = true;\r
+ boolean that_present_prefixlen = true;\r
+ if (this_present_prefixlen || that_present_prefixlen) {\r
+ if (!(this_present_prefixlen && that_present_prefixlen))\r
+ return false;\r
+ if (this.prefixlen != that.prefixlen)\r
+ return false;\r
+ }\r
+\r
+ boolean this_present_nexthop = true && this.isSetNexthop();\r
+ boolean that_present_nexthop = true && that.isSetNexthop();\r
+ if (this_present_nexthop || that_present_nexthop) {\r
+ if (!(this_present_nexthop && that_present_nexthop))\r
+ return false;\r
+ if (!this.nexthop.equals(that.nexthop))\r
+ return false;\r
+ }\r
+\r
+ boolean this_present_ethtag = true;\r
+ boolean that_present_ethtag = true;\r
+ if (this_present_ethtag || that_present_ethtag) {\r
+ if (!(this_present_ethtag && that_present_ethtag))\r
+ return false;\r
+ if (this.ethtag != that.ethtag)\r
+ return false;\r
+ }\r
+\r
+ boolean this_present_esi = true && this.isSetEsi();\r
+ boolean that_present_esi = true && that.isSetEsi();\r
+ if (this_present_esi || that_present_esi) {\r
+ if (!(this_present_esi && that_present_esi))\r
+ return false;\r
+ if (!this.esi.equals(that.esi))\r
+ return false;\r
+ }\r
+\r
+ boolean this_present_macaddress = true && this.isSetMacaddress();\r
+ boolean that_present_macaddress = true && that.isSetMacaddress();\r
+ if (this_present_macaddress || that_present_macaddress) {\r
+ if (!(this_present_macaddress && that_present_macaddress))\r
+ return false;\r
+ if (!this.macaddress.equals(that.macaddress))\r
+ return false;\r
+ }\r
+\r
+ boolean this_present_l3label = true;\r
+ boolean that_present_l3label = true;\r
+ if (this_present_l3label || that_present_l3label) {\r
+ if (!(this_present_l3label && that_present_l3label))\r
+ return false;\r
+ if (this.l3label != that.l3label)\r
+ return false;\r
+ }\r
+\r
+ boolean this_present_l2label = true;\r
+ boolean that_present_l2label = true;\r
+ if (this_present_l2label || that_present_l2label) {\r
+ if (!(this_present_l2label && that_present_l2label))\r
+ return false;\r
+ if (this.l2label != that.l2label)\r
+ return false;\r
+ }\r
+\r
+ boolean this_present_routermac = true && this.isSetRoutermac();\r
+ boolean that_present_routermac = true && that.isSetRoutermac();\r
+ if (this_present_routermac || that_present_routermac) {\r
+ if (!(this_present_routermac && that_present_routermac))\r
+ return false;\r
+ if (!this.routermac.equals(that.routermac))\r
+ return false;\r
+ }\r
+\r
+ boolean this_present_afi = true && this.isSetAfi();\r
+ boolean that_present_afi = true && that.isSetAfi();\r
+ if (this_present_afi || that_present_afi) {\r
+ if (!(this_present_afi && that_present_afi))\r
+ return false;\r
+ if (!this.afi.equals(that.afi))\r
+ return false;\r
+ }\r
+\r
+ return true;\r
+ }\r
+\r
+ @Override\r
+ public int hashCode() {\r
+ List<Object> list = new ArrayList<Object>();\r
+\r
+ boolean present_p_type = true && (isSetP_type());\r
+ list.add(present_p_type);\r
+ if (present_p_type)\r
+ list.add(p_type.getValue());\r
+\r
+ boolean present_rd = true && (isSetRd());\r
+ list.add(present_rd);\r
+ if (present_rd)\r
+ list.add(rd);\r
+\r
+ boolean present_prefix = true && (isSetPrefix());\r
+ list.add(present_prefix);\r
+ if (present_prefix)\r
+ list.add(prefix);\r
+\r
+ boolean present_prefixlen = true;\r
+ list.add(present_prefixlen);\r
+ if (present_prefixlen)\r
+ list.add(prefixlen);\r
+\r
+ boolean present_nexthop = true && (isSetNexthop());\r
+ list.add(present_nexthop);\r
+ if (present_nexthop)\r
+ list.add(nexthop);\r
+\r
+ boolean present_ethtag = true;\r
+ list.add(present_ethtag);\r
+ if (present_ethtag)\r
+ list.add(ethtag);\r
+\r
+ boolean present_esi = true && (isSetEsi());\r
+ list.add(present_esi);\r
+ if (present_esi)\r
+ list.add(esi);\r
+\r
+ boolean present_macaddress = true && (isSetMacaddress());\r
+ list.add(present_macaddress);\r
+ if (present_macaddress)\r
+ list.add(macaddress);\r
+\r
+ boolean present_l3label = true;\r
+ list.add(present_l3label);\r
+ if (present_l3label)\r
+ list.add(l3label);\r
+\r
+ boolean present_l2label = true;\r
+ list.add(present_l2label);\r
+ if (present_l2label)\r
+ list.add(l2label);\r
+\r
+ boolean present_routermac = true && (isSetRoutermac());\r
+ list.add(present_routermac);\r
+ if (present_routermac)\r
+ list.add(routermac);\r
+\r
+ boolean present_afi = true && (isSetAfi());\r
+ list.add(present_afi);\r
+ if (present_afi)\r
+ list.add(afi.getValue());\r
+\r
+ return list.hashCode();\r
+ }\r
+\r
+ @Override\r
+ public int compareTo(onUpdatePushRoute_args other) {\r
+ if (!getClass().equals(other.getClass())) {\r
+ return getClass().getName().compareTo(other.getClass().getName());\r
+ }\r
+\r
+ int lastComparison = 0;\r
+\r
+ lastComparison = Boolean.valueOf(isSetP_type()).compareTo(other.isSetP_type());\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ if (isSetP_type()) {\r
+ lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.p_type, other.p_type);\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ }\r
+ lastComparison = Boolean.valueOf(isSetRd()).compareTo(other.isSetRd());\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ if (isSetRd()) {\r
+ lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.rd, other.rd);\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ }\r
+ lastComparison = Boolean.valueOf(isSetPrefix()).compareTo(other.isSetPrefix());\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ if (isSetPrefix()) {\r
+ lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.prefix, other.prefix);\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ }\r
+ lastComparison = Boolean.valueOf(isSetPrefixlen()).compareTo(other.isSetPrefixlen());\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ if (isSetPrefixlen()) {\r
+ lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.prefixlen, other.prefixlen);\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ }\r
+ lastComparison = Boolean.valueOf(isSetNexthop()).compareTo(other.isSetNexthop());\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ if (isSetNexthop()) {\r
+ lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.nexthop, other.nexthop);\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ }\r
+ lastComparison = Boolean.valueOf(isSetEthtag()).compareTo(other.isSetEthtag());\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ if (isSetEthtag()) {\r
+ lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.ethtag, other.ethtag);\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ }\r
+ lastComparison = Boolean.valueOf(isSetEsi()).compareTo(other.isSetEsi());\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ if (isSetEsi()) {\r
+ lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.esi, other.esi);\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ }\r
+ lastComparison = Boolean.valueOf(isSetMacaddress()).compareTo(other.isSetMacaddress());\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ if (isSetMacaddress()) {\r
+ lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.macaddress, other.macaddress);\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ }\r
+ lastComparison = Boolean.valueOf(isSetL3label()).compareTo(other.isSetL3label());\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ if (isSetL3label()) {\r
+ lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.l3label, other.l3label);\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ }\r
+ lastComparison = Boolean.valueOf(isSetL2label()).compareTo(other.isSetL2label());\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ if (isSetL2label()) {\r
+ lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.l2label, other.l2label);\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ }\r
+ lastComparison = Boolean.valueOf(isSetRoutermac()).compareTo(other.isSetRoutermac());\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ if (isSetRoutermac()) {\r
+ lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.routermac, other.routermac);\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ }\r
+ lastComparison = Boolean.valueOf(isSetAfi()).compareTo(other.isSetAfi());\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ if (isSetAfi()) {\r
+ lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.afi, other.afi);\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ }\r
+ return 0;\r
+ }\r
+\r
+ public _Fields fieldForId(int fieldId) {\r
+ return _Fields.findByThriftId(fieldId);\r
+ }\r
+\r
+ public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {\r
+ schemes.get(iprot.getScheme()).getScheme().read(iprot, this);\r
+ }\r
+\r
+ public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {\r
+ schemes.get(oprot.getScheme()).getScheme().write(oprot, this);\r
+ }\r
+\r
+ @Override\r
+ public String toString() {\r
+ StringBuilder sb = new StringBuilder("onUpdatePushRoute_args(");\r
+ boolean first = true;\r
+\r
+ sb.append("p_type:");\r
+ if (this.p_type == null) {\r
+ sb.append("null");\r
+ } else {\r
+ sb.append(this.p_type);\r
+ }\r
+ first = false;\r
+ if (!first) sb.append(", ");\r
+ sb.append("rd:");\r
+ if (this.rd == null) {\r
+ sb.append("null");\r
+ } else {\r
+ sb.append(this.rd);\r
+ }\r
+ first = false;\r
+ if (!first) sb.append(", ");\r
+ sb.append("prefix:");\r
+ if (this.prefix == null) {\r
+ sb.append("null");\r
+ } else {\r
+ sb.append(this.prefix);\r
+ }\r
+ first = false;\r
+ if (!first) sb.append(", ");\r
+ sb.append("prefixlen:");\r
+ sb.append(this.prefixlen);\r
+ first = false;\r
+ if (!first) sb.append(", ");\r
+ sb.append("nexthop:");\r
+ if (this.nexthop == null) {\r
+ sb.append("null");\r
+ } else {\r
+ sb.append(this.nexthop);\r
+ }\r
+ first = false;\r
+ if (!first) sb.append(", ");\r
+ sb.append("ethtag:");\r
+ sb.append(this.ethtag);\r
+ first = false;\r
+ if (!first) sb.append(", ");\r
+ sb.append("esi:");\r
+ if (this.esi == null) {\r
+ sb.append("null");\r
+ } else {\r
+ sb.append(this.esi);\r
+ }\r
+ first = false;\r
+ if (!first) sb.append(", ");\r
+ sb.append("macaddress:");\r
+ if (this.macaddress == null) {\r
+ sb.append("null");\r
+ } else {\r
+ sb.append(this.macaddress);\r
+ }\r
+ first = false;\r
+ if (!first) sb.append(", ");\r
+ sb.append("l3label:");\r
+ sb.append(this.l3label);\r
+ first = false;\r
+ if (!first) sb.append(", ");\r
+ sb.append("l2label:");\r
+ sb.append(this.l2label);\r
+ first = false;\r
+ if (!first) sb.append(", ");\r
+ sb.append("routermac:");\r
+ if (this.routermac == null) {\r
+ sb.append("null");\r
+ } else {\r
+ sb.append(this.routermac);\r
+ }\r
+ first = false;\r
+ if (!first) sb.append(", ");\r
+ sb.append("afi:");\r
+ if (this.afi == null) {\r
+ sb.append("null");\r
+ } else {\r
+ sb.append(this.afi);\r
+ }\r
+ first = false;\r
+ sb.append(")");\r
+ return sb.toString();\r
+ }\r
+\r
+ public void validate() throws org.apache.thrift.TException {\r
+ // check for required fields\r
+ // check for sub-struct validity\r
+ }\r
+\r
+ private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {\r
+ try {\r
+ write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));\r
+ } catch (org.apache.thrift.TException te) {\r
+ throw new java.io.IOException(te);\r
+ }\r
+ }\r
+\r
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {\r
+ try {\r
+ // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.\r
+ __isset_bitfield = 0;\r
+ read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));\r
+ } catch (org.apache.thrift.TException te) {\r
+ throw new java.io.IOException(te);\r
+ }\r
+ }\r
+\r
+ private static class onUpdatePushRoute_argsStandardSchemeFactory implements SchemeFactory {\r
+ public onUpdatePushRoute_argsStandardScheme getScheme() {\r
+ return new onUpdatePushRoute_argsStandardScheme();\r
+ }\r
+ }\r
+\r
+ private static class onUpdatePushRoute_argsStandardScheme extends StandardScheme<onUpdatePushRoute_args> {\r
+\r
+ public void read(org.apache.thrift.protocol.TProtocol iprot, onUpdatePushRoute_args struct) throws org.apache.thrift.TException {\r
+ org.apache.thrift.protocol.TField schemeField;\r
+ iprot.readStructBegin();\r
+ while (true)\r
+ {\r
+ schemeField = iprot.readFieldBegin();\r
+ if (schemeField.type == org.apache.thrift.protocol.TType.STOP) {\r
+ break;\r
+ }\r
+ switch (schemeField.id) {\r
+ case 1: // P_TYPE\r
+ if (schemeField.type == org.apache.thrift.protocol.TType.I32) {\r
+ struct.p_type = protocol_type.findByValue(iprot.readI32());\r
+ struct.setP_typeIsSet(true);\r
+ } else {\r
+ org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);\r
+ }\r
+ break;\r
+ case 2: // RD\r
+ if (schemeField.type == org.apache.thrift.protocol.TType.STRING) {\r
+ struct.rd = iprot.readString();\r
+ struct.setRdIsSet(true);\r
+ } else {\r
+ org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);\r
+ }\r
+ break;\r
+ case 3: // PREFIX\r
+ if (schemeField.type == org.apache.thrift.protocol.TType.STRING) {\r
+ struct.prefix = iprot.readString();\r
+ struct.setPrefixIsSet(true);\r
+ } else {\r
+ org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);\r
+ }\r
+ break;\r
+ case 4: // PREFIXLEN\r
+ if (schemeField.type == org.apache.thrift.protocol.TType.I32) {\r
+ struct.prefixlen = iprot.readI32();\r
+ struct.setPrefixlenIsSet(true);\r
+ } else {\r
+ org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);\r
+ }\r
+ break;\r
+ case 5: // NEXTHOP\r
+ if (schemeField.type == org.apache.thrift.protocol.TType.STRING) {\r
+ struct.nexthop = iprot.readString();\r
+ struct.setNexthopIsSet(true);\r
+ } else {\r
+ org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);\r
+ }\r
+ break;\r
+ case 6: // ETHTAG\r
+ if (schemeField.type == org.apache.thrift.protocol.TType.I64) {\r
+ struct.ethtag = iprot.readI64();\r
+ struct.setEthtagIsSet(true);\r
+ } else {\r
+ org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);\r
+ }\r
+ break;\r
+ case 7: // ESI\r
+ if (schemeField.type == org.apache.thrift.protocol.TType.STRING) {\r
+ struct.esi = iprot.readString();\r
+ struct.setEsiIsSet(true);\r
+ } else {\r
+ org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);\r
+ }\r
+ break;\r
+ case 8: // MACADDRESS\r
+ if (schemeField.type == org.apache.thrift.protocol.TType.STRING) {\r
+ struct.macaddress = iprot.readString();\r
+ struct.setMacaddressIsSet(true);\r
+ } else {\r
+ org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);\r
+ }\r
+ break;\r
+ case 9: // L3LABEL\r
+ if (schemeField.type == org.apache.thrift.protocol.TType.I32) {\r
+ struct.l3label = iprot.readI32();\r
+ struct.setL3labelIsSet(true);\r
+ } else {\r
+ org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);\r
+ }\r
+ break;\r
+ case 10: // L2LABEL\r
+ if (schemeField.type == org.apache.thrift.protocol.TType.I32) {\r
+ struct.l2label = iprot.readI32();\r
+ struct.setL2labelIsSet(true);\r
+ } else {\r
+ org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);\r
+ }\r
+ break;\r
+ case 11: // ROUTERMAC\r
+ if (schemeField.type == org.apache.thrift.protocol.TType.STRING) {\r
+ struct.routermac = iprot.readString();\r
+ struct.setRoutermacIsSet(true);\r
+ } else {\r
+ org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);\r
+ }\r
+ break;\r
+ case 12: // AFI\r
+ if (schemeField.type == org.apache.thrift.protocol.TType.I32) {\r
+ struct.afi = af_afi.findByValue(iprot.readI32());\r
+ struct.setAfiIsSet(true);\r
+ } else {\r
+ org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);\r
+ }\r
+ break;\r
+ default:\r
+ org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);\r
+ }\r
+ iprot.readFieldEnd();\r
+ }\r
+ iprot.readStructEnd();\r
+\r
+ // check for required fields of primitive type, which can't be checked in the validate method\r
+ struct.validate();\r
+ }\r
+\r
+ public void write(org.apache.thrift.protocol.TProtocol oprot, onUpdatePushRoute_args struct) throws org.apache.thrift.TException {\r
+ struct.validate();\r
+\r
+ oprot.writeStructBegin(STRUCT_DESC);\r
+ if (struct.p_type != null) {\r
+ oprot.writeFieldBegin(P_TYPE_FIELD_DESC);\r
+ oprot.writeI32(struct.p_type.getValue());\r
+ oprot.writeFieldEnd();\r
+ }\r
+ if (struct.rd != null) {\r
+ oprot.writeFieldBegin(RD_FIELD_DESC);\r
+ oprot.writeString(struct.rd);\r
+ oprot.writeFieldEnd();\r
+ }\r
+ if (struct.prefix != null) {\r
+ oprot.writeFieldBegin(PREFIX_FIELD_DESC);\r
+ oprot.writeString(struct.prefix);\r
+ oprot.writeFieldEnd();\r
+ }\r
+ oprot.writeFieldBegin(PREFIXLEN_FIELD_DESC);\r
+ oprot.writeI32(struct.prefixlen);\r
+ oprot.writeFieldEnd();\r
+ if (struct.nexthop != null) {\r
+ oprot.writeFieldBegin(NEXTHOP_FIELD_DESC);\r
+ oprot.writeString(struct.nexthop);\r
+ oprot.writeFieldEnd();\r
+ }\r
+ oprot.writeFieldBegin(ETHTAG_FIELD_DESC);\r
+ oprot.writeI64(struct.ethtag);\r
+ oprot.writeFieldEnd();\r
+ if (struct.esi != null) {\r
+ oprot.writeFieldBegin(ESI_FIELD_DESC);\r
+ oprot.writeString(struct.esi);\r
+ oprot.writeFieldEnd();\r
+ }\r
+ if (struct.macaddress != null) {\r
+ oprot.writeFieldBegin(MACADDRESS_FIELD_DESC);\r
+ oprot.writeString(struct.macaddress);\r
+ oprot.writeFieldEnd();\r
+ }\r
+ oprot.writeFieldBegin(L3LABEL_FIELD_DESC);\r
+ oprot.writeI32(struct.l3label);\r
+ oprot.writeFieldEnd();\r
+ oprot.writeFieldBegin(L2LABEL_FIELD_DESC);\r
+ oprot.writeI32(struct.l2label);\r
+ oprot.writeFieldEnd();\r
+ if (struct.routermac != null) {\r
+ oprot.writeFieldBegin(ROUTERMAC_FIELD_DESC);\r
+ oprot.writeString(struct.routermac);\r
+ oprot.writeFieldEnd();\r
+ }\r
+ if (struct.afi != null) {\r
+ oprot.writeFieldBegin(AFI_FIELD_DESC);\r
+ oprot.writeI32(struct.afi.getValue());\r
+ oprot.writeFieldEnd();\r
+ }\r
+ oprot.writeFieldStop();\r
+ oprot.writeStructEnd();\r
+ }\r
+\r
+ }\r
+\r
+ private static class onUpdatePushRoute_argsTupleSchemeFactory implements SchemeFactory {\r
+ public onUpdatePushRoute_argsTupleScheme getScheme() {\r
+ return new onUpdatePushRoute_argsTupleScheme();\r
+ }\r
+ }\r
+\r
+ private static class onUpdatePushRoute_argsTupleScheme extends TupleScheme<onUpdatePushRoute_args> {\r
+\r
+ @Override\r
+ public void write(org.apache.thrift.protocol.TProtocol prot, onUpdatePushRoute_args struct) throws org.apache.thrift.TException {\r
+ TTupleProtocol oprot = (TTupleProtocol) prot;\r
+ BitSet optionals = new BitSet();\r
+ if (struct.isSetP_type()) {\r
+ optionals.set(0);\r
+ }\r
+ if (struct.isSetRd()) {\r
+ optionals.set(1);\r
+ }\r
+ if (struct.isSetPrefix()) {\r
+ optionals.set(2);\r
+ }\r
+ if (struct.isSetPrefixlen()) {\r
+ optionals.set(3);\r
+ }\r
+ if (struct.isSetNexthop()) {\r
+ optionals.set(4);\r
+ }\r
+ if (struct.isSetEthtag()) {\r
+ optionals.set(5);\r
+ }\r
+ if (struct.isSetEsi()) {\r
+ optionals.set(6);\r
+ }\r
+ if (struct.isSetMacaddress()) {\r
+ optionals.set(7);\r
+ }\r
+ if (struct.isSetL3label()) {\r
+ optionals.set(8);\r
+ }\r
+ if (struct.isSetL2label()) {\r
+ optionals.set(9);\r
+ }\r
+ if (struct.isSetRoutermac()) {\r
+ optionals.set(10);\r
+ }\r
+ if (struct.isSetAfi()) {\r
+ optionals.set(11);\r
+ }\r
+ oprot.writeBitSet(optionals, 12);\r
+ if (struct.isSetP_type()) {\r
+ oprot.writeI32(struct.p_type.getValue());\r
+ }\r
+ if (struct.isSetRd()) {\r
+ oprot.writeString(struct.rd);\r
+ }\r
+ if (struct.isSetPrefix()) {\r
+ oprot.writeString(struct.prefix);\r
+ }\r
+ if (struct.isSetPrefixlen()) {\r
+ oprot.writeI32(struct.prefixlen);\r
+ }\r
+ if (struct.isSetNexthop()) {\r
+ oprot.writeString(struct.nexthop);\r
+ }\r
+ if (struct.isSetEthtag()) {\r
+ oprot.writeI64(struct.ethtag);\r
+ }\r
+ if (struct.isSetEsi()) {\r
+ oprot.writeString(struct.esi);\r
+ }\r
+ if (struct.isSetMacaddress()) {\r
+ oprot.writeString(struct.macaddress);\r
+ }\r
+ if (struct.isSetL3label()) {\r
+ oprot.writeI32(struct.l3label);\r
+ }\r
+ if (struct.isSetL2label()) {\r
+ oprot.writeI32(struct.l2label);\r
+ }\r
+ if (struct.isSetRoutermac()) {\r
+ oprot.writeString(struct.routermac);\r
+ }\r
+ if (struct.isSetAfi()) {\r
+ oprot.writeI32(struct.afi.getValue());\r
+ }\r
+ }\r
+\r
+ @Override\r
+ public void read(org.apache.thrift.protocol.TProtocol prot, onUpdatePushRoute_args struct) throws org.apache.thrift.TException {\r
+ TTupleProtocol iprot = (TTupleProtocol) prot;\r
+ BitSet incoming = iprot.readBitSet(12);\r
+ if (incoming.get(0)) {\r
+ struct.p_type = protocol_type.findByValue(iprot.readI32());\r
+ struct.setP_typeIsSet(true);\r
+ }\r
+ if (incoming.get(1)) {\r
+ struct.rd = iprot.readString();\r
+ struct.setRdIsSet(true);\r
+ }\r
+ if (incoming.get(2)) {\r
+ struct.prefix = iprot.readString();\r
+ struct.setPrefixIsSet(true);\r
+ }\r
+ if (incoming.get(3)) {\r
+ struct.prefixlen = iprot.readI32();\r
+ struct.setPrefixlenIsSet(true);\r
+ }\r
+ if (incoming.get(4)) {\r
+ struct.nexthop = iprot.readString();\r
+ struct.setNexthopIsSet(true);\r
+ }\r
+ if (incoming.get(5)) {\r
+ struct.ethtag = iprot.readI64();\r
+ struct.setEthtagIsSet(true);\r
+ }\r
+ if (incoming.get(6)) {\r
+ struct.esi = iprot.readString();\r
+ struct.setEsiIsSet(true);\r
+ }\r
+ if (incoming.get(7)) {\r
+ struct.macaddress = iprot.readString();\r
+ struct.setMacaddressIsSet(true);\r
+ }\r
+ if (incoming.get(8)) {\r
+ struct.l3label = iprot.readI32();\r
+ struct.setL3labelIsSet(true);\r
+ }\r
+ if (incoming.get(9)) {\r
+ struct.l2label = iprot.readI32();\r
+ struct.setL2labelIsSet(true);\r
+ }\r
+ if (incoming.get(10)) {\r
+ struct.routermac = iprot.readString();\r
+ struct.setRoutermacIsSet(true);\r
+ }\r
+ if (incoming.get(11)) {\r
+ struct.afi = af_afi.findByValue(iprot.readI32());\r
+ struct.setAfiIsSet(true);\r
+ }\r
+ }\r
+ }\r
+\r
+ }\r
+\r
+ public static class onUpdateWithdrawRoute_args implements org.apache.thrift.TBase<onUpdateWithdrawRoute_args, onUpdateWithdrawRoute_args._Fields>, java.io.Serializable, Cloneable, Comparable<onUpdateWithdrawRoute_args> {\r
+ private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("onUpdateWithdrawRoute_args");\r
+\r
+ private static final org.apache.thrift.protocol.TField P_TYPE_FIELD_DESC = new org.apache.thrift.protocol.TField("p_type", org.apache.thrift.protocol.TType.I32, (short)1);\r
+ private static final org.apache.thrift.protocol.TField RD_FIELD_DESC = new org.apache.thrift.protocol.TField("rd", org.apache.thrift.protocol.TType.STRING, (short)2);\r
+ private static final org.apache.thrift.protocol.TField PREFIX_FIELD_DESC = new org.apache.thrift.protocol.TField("prefix", org.apache.thrift.protocol.TType.STRING, (short)3);\r
+ private static final org.apache.thrift.protocol.TField PREFIXLEN_FIELD_DESC = new org.apache.thrift.protocol.TField("prefixlen", org.apache.thrift.protocol.TType.I32, (short)4);\r
+ private static final org.apache.thrift.protocol.TField NEXTHOP_FIELD_DESC = new org.apache.thrift.protocol.TField("nexthop", org.apache.thrift.protocol.TType.STRING, (short)5);\r
+ private static final org.apache.thrift.protocol.TField ETHTAG_FIELD_DESC = new org.apache.thrift.protocol.TField("ethtag", org.apache.thrift.protocol.TType.I64, (short)6);\r
+ private static final org.apache.thrift.protocol.TField ESI_FIELD_DESC = new org.apache.thrift.protocol.TField("esi", org.apache.thrift.protocol.TType.STRING, (short)7);\r
+ private static final org.apache.thrift.protocol.TField MACADDRESS_FIELD_DESC = new org.apache.thrift.protocol.TField("macaddress", org.apache.thrift.protocol.TType.STRING, (short)8);\r
+ private static final org.apache.thrift.protocol.TField L3LABEL_FIELD_DESC = new org.apache.thrift.protocol.TField("l3label", org.apache.thrift.protocol.TType.I32, (short)9);\r
+ private static final org.apache.thrift.protocol.TField L2LABEL_FIELD_DESC = new org.apache.thrift.protocol.TField("l2label", org.apache.thrift.protocol.TType.I32, (short)10);\r
+ private static final org.apache.thrift.protocol.TField AFI_FIELD_DESC = new org.apache.thrift.protocol.TField("afi", org.apache.thrift.protocol.TType.I32, (short)11);\r
+\r
+ private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();\r
+ static {\r
+ schemes.put(StandardScheme.class, new onUpdateWithdrawRoute_argsStandardSchemeFactory());\r
+ schemes.put(TupleScheme.class, new onUpdateWithdrawRoute_argsTupleSchemeFactory());\r
+ }\r
+\r
+ /**\r
+ *\r
+ * @see protocol_type\r
+ */\r
+ public protocol_type p_type; // required\r
+ public String rd; // required\r
+ public String prefix; // required\r
+ public int prefixlen; // required\r
+ public String nexthop; // required\r
+ public long ethtag; // required\r
+ public String esi; // required\r
+ public String macaddress; // required\r
+ public int l3label; // required\r
+ public int l2label; // required\r
+ /**\r
+ *\r
+ * @see af_afi\r
+ */\r
+ public af_afi afi; // required\r
+\r
+ /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */\r
+ public enum _Fields implements org.apache.thrift.TFieldIdEnum {\r
+ /**\r
+ *\r
+ * @see protocol_type\r
+ */\r
+ P_TYPE((short)1, "p_type"),\r
+ RD((short)2, "rd"),\r
+ PREFIX((short)3, "prefix"),\r
+ PREFIXLEN((short)4, "prefixlen"),\r
+ NEXTHOP((short)5, "nexthop"),\r
+ ETHTAG((short)6, "ethtag"),\r
+ ESI((short)7, "esi"),\r
+ MACADDRESS((short)8, "macaddress"),\r
+ L3LABEL((short)9, "l3label"),\r
+ L2LABEL((short)10, "l2label"),\r
+ /**\r
+ *\r
+ * @see af_afi\r
+ */\r
+ AFI((short)11, "afi");\r
+\r
+ private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();\r
+\r
+ static {\r
+ for (_Fields field : EnumSet.allOf(_Fields.class)) {\r
+ byName.put(field.getFieldName(), field);\r
+ }\r
+ }\r
+\r
+ /**\r
+ * Find the _Fields constant that matches fieldId, or null if its not found.\r
+ */\r
+ public static _Fields findByThriftId(int fieldId) {\r
+ switch(fieldId) {\r
+ case 1: // P_TYPE\r
+ return P_TYPE;\r
+ case 2: // RD\r
+ return RD;\r
+ case 3: // PREFIX\r
+ return PREFIX;\r
+ case 4: // PREFIXLEN\r
+ return PREFIXLEN;\r
+ case 5: // NEXTHOP\r
+ return NEXTHOP;\r
+ case 6: // ETHTAG\r
+ return ETHTAG;\r
+ case 7: // ESI\r
+ return ESI;\r
+ case 8: // MACADDRESS\r
+ return MACADDRESS;\r
+ case 9: // L3LABEL\r
+ return L3LABEL;\r
+ case 10: // L2LABEL\r
+ return L2LABEL;\r
+ case 11: // AFI\r
+ return AFI;\r
+ default:\r
+ return null;\r
+ }\r
+ }\r
+\r
+ /**\r
+ * Find the _Fields constant that matches fieldId, throwing an exception\r
+ * if it is not found.\r
+ */\r
+ public static _Fields findByThriftIdOrThrow(int fieldId) {\r
+ _Fields fields = findByThriftId(fieldId);\r
+ if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");\r
+ return fields;\r
+ }\r
+\r
+ /**\r
+ * Find the _Fields constant that matches name, or null if its not found.\r
+ */\r
+ public static _Fields findByName(String name) {\r
+ return byName.get(name);\r
+ }\r
+\r
+ private final short _thriftId;\r
+ private final String _fieldName;\r
+\r
+ _Fields(short thriftId, String fieldName) {\r
+ _thriftId = thriftId;\r
+ _fieldName = fieldName;\r
+ }\r
+\r
+ public short getThriftFieldId() {\r
+ return _thriftId;\r
+ }\r
+\r
+ public String getFieldName() {\r
+ return _fieldName;\r
+ }\r
+ }\r
+\r
+ // isset id assignments\r
+ private static final int __PREFIXLEN_ISSET_ID = 0;\r
+ private static final int __ETHTAG_ISSET_ID = 1;\r
+ private static final int __L3LABEL_ISSET_ID = 2;\r
+ private static final int __L2LABEL_ISSET_ID = 3;\r
+ private byte __isset_bitfield = 0;\r
+ public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;\r
+ static {\r
+ Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);\r
+ tmpMap.put(_Fields.P_TYPE, new org.apache.thrift.meta_data.FieldMetaData("p_type", org.apache.thrift.TFieldRequirementType.DEFAULT,\r
+ new org.apache.thrift.meta_data.EnumMetaData(org.apache.thrift.protocol.TType.ENUM, protocol_type.class)));\r
+ tmpMap.put(_Fields.RD, new org.apache.thrift.meta_data.FieldMetaData("rd", org.apache.thrift.TFieldRequirementType.DEFAULT,\r
+ new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));\r
+ tmpMap.put(_Fields.PREFIX, new org.apache.thrift.meta_data.FieldMetaData("prefix", org.apache.thrift.TFieldRequirementType.DEFAULT,\r
+ new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));\r
+ tmpMap.put(_Fields.PREFIXLEN, new org.apache.thrift.meta_data.FieldMetaData("prefixlen", org.apache.thrift.TFieldRequirementType.DEFAULT,\r
+ new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I32)));\r
+ tmpMap.put(_Fields.NEXTHOP, new org.apache.thrift.meta_data.FieldMetaData("nexthop", org.apache.thrift.TFieldRequirementType.DEFAULT,\r
+ new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));\r
+ tmpMap.put(_Fields.ETHTAG, new org.apache.thrift.meta_data.FieldMetaData("ethtag", org.apache.thrift.TFieldRequirementType.DEFAULT,\r
+ new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));\r
+ tmpMap.put(_Fields.ESI, new org.apache.thrift.meta_data.FieldMetaData("esi", org.apache.thrift.TFieldRequirementType.DEFAULT,\r
+ new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));\r
+ tmpMap.put(_Fields.MACADDRESS, new org.apache.thrift.meta_data.FieldMetaData("macaddress", org.apache.thrift.TFieldRequirementType.DEFAULT,\r
+ new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));\r
+ tmpMap.put(_Fields.L3LABEL, new org.apache.thrift.meta_data.FieldMetaData("l3label", org.apache.thrift.TFieldRequirementType.DEFAULT,\r
+ new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I32)));\r
+ tmpMap.put(_Fields.L2LABEL, new org.apache.thrift.meta_data.FieldMetaData("l2label", org.apache.thrift.TFieldRequirementType.DEFAULT,\r
+ new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I32)));\r
+ tmpMap.put(_Fields.AFI, new org.apache.thrift.meta_data.FieldMetaData("afi", org.apache.thrift.TFieldRequirementType.DEFAULT,\r
+ new org.apache.thrift.meta_data.EnumMetaData(org.apache.thrift.protocol.TType.ENUM, af_afi.class)));\r
+ metaDataMap = Collections.unmodifiableMap(tmpMap);\r
+ org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(onUpdateWithdrawRoute_args.class, metaDataMap);\r
+ }\r
+\r
+ public onUpdateWithdrawRoute_args() {\r
+ }\r
+\r
+ public onUpdateWithdrawRoute_args(\r
+ protocol_type p_type,\r
+ String rd,\r
+ String prefix,\r
+ int prefixlen,\r
+ String nexthop,\r
+ long ethtag,\r
+ String esi,\r
+ String macaddress,\r
+ int l3label,\r
+ int l2label,\r
+ af_afi afi)\r
+ {\r
+ this();\r
+ this.p_type = p_type;\r
+ this.rd = rd;\r
+ this.prefix = prefix;\r
+ this.prefixlen = prefixlen;\r
+ setPrefixlenIsSet(true);\r
+ this.nexthop = nexthop;\r
+ this.ethtag = ethtag;\r
+ setEthtagIsSet(true);\r
+ this.esi = esi;\r
+ this.macaddress = macaddress;\r
+ this.l3label = l3label;\r
+ setL3labelIsSet(true);\r
+ this.l2label = l2label;\r
+ setL2labelIsSet(true);\r
+ this.afi = afi;\r
+ }\r
+\r
+ /**\r
+ * Performs a deep copy on <i>other</i>.\r
+ */\r
+ public onUpdateWithdrawRoute_args(onUpdateWithdrawRoute_args other) {\r
+ __isset_bitfield = other.__isset_bitfield;\r
+ if (other.isSetP_type()) {\r
+ this.p_type = other.p_type;\r
+ }\r
+ if (other.isSetRd()) {\r
+ this.rd = other.rd;\r
+ }\r
+ if (other.isSetPrefix()) {\r
+ this.prefix = other.prefix;\r
+ }\r
+ this.prefixlen = other.prefixlen;\r
+ if (other.isSetNexthop()) {\r
+ this.nexthop = other.nexthop;\r
+ }\r
+ this.ethtag = other.ethtag;\r
+ if (other.isSetEsi()) {\r
+ this.esi = other.esi;\r
+ }\r
+ if (other.isSetMacaddress()) {\r
+ this.macaddress = other.macaddress;\r
+ }\r
+ this.l3label = other.l3label;\r
+ this.l2label = other.l2label;\r
+ if (other.isSetAfi()) {\r
+ this.afi = other.afi;\r
+ }\r
+ }\r
+\r
+ public onUpdateWithdrawRoute_args deepCopy() {\r
+ return new onUpdateWithdrawRoute_args(this);\r
+ }\r
+\r
+ @Override\r
+ public void clear() {\r
+ this.p_type = null;\r
+ this.rd = null;\r
+ this.prefix = null;\r
+ setPrefixlenIsSet(false);\r
+ this.prefixlen = 0;\r
+ this.nexthop = null;\r
+ setEthtagIsSet(false);\r
+ this.ethtag = 0;\r
+ this.esi = null;\r
+ this.macaddress = null;\r
+ setL3labelIsSet(false);\r
+ this.l3label = 0;\r
+ setL2labelIsSet(false);\r
+ this.l2label = 0;\r
+ this.afi = null;\r
+ }\r
+\r
+ /**\r
+ *\r
+ * @see protocol_type\r
+ */\r
+ public protocol_type getP_type() {\r
+ return this.p_type;\r
+ }\r
+\r
+ /**\r
+ *\r
+ * @see protocol_type\r
+ */\r
+ public onUpdateWithdrawRoute_args setP_type(protocol_type p_type) {\r
+ this.p_type = p_type;\r
+ return this;\r
+ }\r
+\r
+ public void unsetP_type() {\r
+ this.p_type = null;\r
+ }\r
+\r
+ /** Returns true if field p_type is set (has been assigned a value) and false otherwise */\r
+ public boolean isSetP_type() {\r
+ return this.p_type != null;\r
+ }\r
+\r
+ public void setP_typeIsSet(boolean value) {\r
+ if (!value) {\r
+ this.p_type = null;\r
+ }\r
+ }\r
+\r
+ public String getRd() {\r
+ return this.rd;\r
+ }\r
+\r
+ public onUpdateWithdrawRoute_args setRd(String rd) {\r
+ this.rd = rd;\r
+ return this;\r
+ }\r
+\r
+ public void unsetRd() {\r
+ this.rd = null;\r
+ }\r
+\r
+ /** Returns true if field rd is set (has been assigned a value) and false otherwise */\r
+ public boolean isSetRd() {\r
+ return this.rd != null;\r
+ }\r
+\r
+ public void setRdIsSet(boolean value) {\r
+ if (!value) {\r
+ this.rd = null;\r
+ }\r
+ }\r
+\r
+ public String getPrefix() {\r
+ return this.prefix;\r
+ }\r
+\r
+ public onUpdateWithdrawRoute_args setPrefix(String prefix) {\r
+ this.prefix = prefix;\r
+ return this;\r
+ }\r
+\r
+ public void unsetPrefix() {\r
+ this.prefix = null;\r
+ }\r
+\r
+ /** Returns true if field prefix is set (has been assigned a value) and false otherwise */\r
+ public boolean isSetPrefix() {\r
+ return this.prefix != null;\r
+ }\r
+\r
+ public void setPrefixIsSet(boolean value) {\r
+ if (!value) {\r
+ this.prefix = null;\r
+ }\r
+ }\r
+\r
+ public int getPrefixlen() {\r
+ return this.prefixlen;\r
+ }\r
+\r
+ public onUpdateWithdrawRoute_args setPrefixlen(int prefixlen) {\r
+ this.prefixlen = prefixlen;\r
+ setPrefixlenIsSet(true);\r
+ return this;\r
+ }\r
+\r
+ public void unsetPrefixlen() {\r
+ __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __PREFIXLEN_ISSET_ID);\r
+ }\r
+\r
+ /** Returns true if field prefixlen is set (has been assigned a value) and false otherwise */\r
+ public boolean isSetPrefixlen() {\r
+ return EncodingUtils.testBit(__isset_bitfield, __PREFIXLEN_ISSET_ID);\r
+ }\r
+\r
+ public void setPrefixlenIsSet(boolean value) {\r
+ __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __PREFIXLEN_ISSET_ID, value);\r
+ }\r
+\r
+ public String getNexthop() {\r
+ return this.nexthop;\r
+ }\r
+\r
+ public onUpdateWithdrawRoute_args setNexthop(String nexthop) {\r
+ this.nexthop = nexthop;\r
+ return this;\r
+ }\r
+\r
+ public void unsetNexthop() {\r
+ this.nexthop = null;\r
+ }\r
+\r
+ /** Returns true if field nexthop is set (has been assigned a value) and false otherwise */\r
+ public boolean isSetNexthop() {\r
+ return this.nexthop != null;\r
+ }\r
+\r
+ public void setNexthopIsSet(boolean value) {\r
+ if (!value) {\r
+ this.nexthop = null;\r
+ }\r
+ }\r
+\r
+ public long getEthtag() {\r
+ return this.ethtag;\r
+ }\r
+\r
+ public onUpdateWithdrawRoute_args setEthtag(long ethtag) {\r
+ this.ethtag = ethtag;\r
+ setEthtagIsSet(true);\r
+ return this;\r
+ }\r
+\r
+ public void unsetEthtag() {\r
+ __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __ETHTAG_ISSET_ID);\r
+ }\r
+\r
+ /** Returns true if field ethtag is set (has been assigned a value) and false otherwise */\r
+ public boolean isSetEthtag() {\r
+ return EncodingUtils.testBit(__isset_bitfield, __ETHTAG_ISSET_ID);\r
+ }\r
+\r
+ public void setEthtagIsSet(boolean value) {\r
+ __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __ETHTAG_ISSET_ID, value);\r
+ }\r
+\r
+ public String getEsi() {\r
+ return this.esi;\r
+ }\r
+\r
+ public onUpdateWithdrawRoute_args setEsi(String esi) {\r
+ this.esi = esi;\r
+ return this;\r
+ }\r
+\r
+ public void unsetEsi() {\r
+ this.esi = null;\r
+ }\r
+\r
+ /** Returns true if field esi is set (has been assigned a value) and false otherwise */\r
+ public boolean isSetEsi() {\r
+ return this.esi != null;\r
+ }\r
+\r
+ public void setEsiIsSet(boolean value) {\r
+ if (!value) {\r
+ this.esi = null;\r
+ }\r
+ }\r
+\r
+ public String getMacaddress() {\r
+ return this.macaddress;\r
+ }\r
+\r
+ public onUpdateWithdrawRoute_args setMacaddress(String macaddress) {\r
+ this.macaddress = macaddress;\r
+ return this;\r
+ }\r
+\r
+ public void unsetMacaddress() {\r
+ this.macaddress = null;\r
+ }\r
+\r
+ /** Returns true if field macaddress is set (has been assigned a value) and false otherwise */\r
+ public boolean isSetMacaddress() {\r
+ return this.macaddress != null;\r
+ }\r
+\r
+ public void setMacaddressIsSet(boolean value) {\r
+ if (!value) {\r
+ this.macaddress = null;\r
+ }\r
+ }\r
+\r
+ public int getL3label() {\r
+ return this.l3label;\r
+ }\r
+\r
+ public onUpdateWithdrawRoute_args setL3label(int l3label) {\r
+ this.l3label = l3label;\r
+ setL3labelIsSet(true);\r
+ return this;\r
+ }\r
+\r
+ public void unsetL3label() {\r
+ __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __L3LABEL_ISSET_ID);\r
+ }\r
+\r
+ /** Returns true if field l3label is set (has been assigned a value) and false otherwise */\r
+ public boolean isSetL3label() {\r
+ return EncodingUtils.testBit(__isset_bitfield, __L3LABEL_ISSET_ID);\r
+ }\r
+\r
+ public void setL3labelIsSet(boolean value) {\r
+ __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __L3LABEL_ISSET_ID, value);\r
+ }\r
+\r
+ public int getL2label() {\r
+ return this.l2label;\r
+ }\r
+\r
+ public onUpdateWithdrawRoute_args setL2label(int l2label) {\r
+ this.l2label = l2label;\r
+ setL2labelIsSet(true);\r
+ return this;\r
+ }\r
+\r
+ public void unsetL2label() {\r
+ __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __L2LABEL_ISSET_ID);\r
+ }\r
+\r
+ /** Returns true if field l2label is set (has been assigned a value) and false otherwise */\r
+ public boolean isSetL2label() {\r
+ return EncodingUtils.testBit(__isset_bitfield, __L2LABEL_ISSET_ID);\r
+ }\r
+\r
+ public void setL2labelIsSet(boolean value) {\r
+ __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __L2LABEL_ISSET_ID, value);\r
+ }\r
+\r
+ /**\r
+ *\r
+ * @see af_afi\r
+ */\r
+ public af_afi getAfi() {\r
+ return this.afi;\r
+ }\r
+\r
+ /**\r
+ *\r
+ * @see af_afi\r
+ */\r
+ public onUpdateWithdrawRoute_args setAfi(af_afi afi) {\r
+ this.afi = afi;\r
+ return this;\r
+ }\r
+\r
+ public void unsetAfi() {\r
+ this.afi = null;\r
+ }\r
+\r
+ /** Returns true if field afi is set (has been assigned a value) and false otherwise */\r
+ public boolean isSetAfi() {\r
+ return this.afi != null;\r
+ }\r
+\r
+ public void setAfiIsSet(boolean value) {\r
+ if (!value) {\r
+ this.afi = null;\r
+ }\r
+ }\r
+\r
+ public void setFieldValue(_Fields field, Object value) {\r
+ switch (field) {\r
+ case P_TYPE:\r
+ if (value == null) {\r
+ unsetP_type();\r
+ } else {\r
+ setP_type((protocol_type)value);\r
+ }\r
+ break;\r
+\r
+ case RD:\r
+ if (value == null) {\r
+ unsetRd();\r
+ } else {\r
+ setRd((String)value);\r
+ }\r
+ break;\r
+\r
+ case PREFIX:\r
+ if (value == null) {\r
+ unsetPrefix();\r
+ } else {\r
+ setPrefix((String)value);\r
+ }\r
+ break;\r
+\r
+ case PREFIXLEN:\r
+ if (value == null) {\r
+ unsetPrefixlen();\r
+ } else {\r
+ setPrefixlen((Integer)value);\r
+ }\r
+ break;\r
+\r
+ case NEXTHOP:\r
+ if (value == null) {\r
+ unsetNexthop();\r
+ } else {\r
+ setNexthop((String)value);\r
+ }\r
+ break;\r
+\r
+ case ETHTAG:\r
+ if (value == null) {\r
+ unsetEthtag();\r
+ } else {\r
+ setEthtag((Long)value);\r
+ }\r
+ break;\r
+\r
+ case ESI:\r
+ if (value == null) {\r
+ unsetEsi();\r
+ } else {\r
+ setEsi((String)value);\r
+ }\r
+ break;\r
+\r
+ case MACADDRESS:\r
+ if (value == null) {\r
+ unsetMacaddress();\r
+ } else {\r
+ setMacaddress((String)value);\r
+ }\r
+ break;\r
+\r
+ case L3LABEL:\r
+ if (value == null) {\r
+ unsetL3label();\r
+ } else {\r
+ setL3label((Integer)value);\r
+ }\r
+ break;\r
+\r
+ case L2LABEL:\r
+ if (value == null) {\r
+ unsetL2label();\r
+ } else {\r
+ setL2label((Integer)value);\r
+ }\r
+ break;\r
+\r
+ case AFI:\r
+ if (value == null) {\r
+ unsetAfi();\r
+ } else {\r
+ setAfi((af_afi)value);\r
+ }\r
+ break;\r
+\r
+ }\r
+ }\r
+\r
+ public Object getFieldValue(_Fields field) {\r
+ switch (field) {\r
+ case P_TYPE:\r
+ return getP_type();\r
+\r
+ case RD:\r
+ return getRd();\r
+\r
+ case PREFIX:\r
+ return getPrefix();\r
+\r
+ case PREFIXLEN:\r
+ return getPrefixlen();\r
+\r
+ case NEXTHOP:\r
+ return getNexthop();\r
+\r
+ case ETHTAG:\r
+ return getEthtag();\r
+\r
+ case ESI:\r
+ return getEsi();\r
+\r
+ case MACADDRESS:\r
+ return getMacaddress();\r
+\r
+ case L3LABEL:\r
+ return getL3label();\r
+\r
+ case L2LABEL:\r
+ return getL2label();\r
+\r
+ case AFI:\r
+ return getAfi();\r
+\r
+ }\r
+ throw new IllegalStateException();\r
+ }\r
+\r
+ /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */\r
+ public boolean isSet(_Fields field) {\r
+ if (field == null) {\r
+ throw new IllegalArgumentException();\r
+ }\r
+\r
+ switch (field) {\r
+ case P_TYPE:\r
+ return isSetP_type();\r
+ case RD:\r
+ return isSetRd();\r
+ case PREFIX:\r
+ return isSetPrefix();\r
+ case PREFIXLEN:\r
+ return isSetPrefixlen();\r
+ case NEXTHOP:\r
+ return isSetNexthop();\r
+ case ETHTAG:\r
+ return isSetEthtag();\r
+ case ESI:\r
+ return isSetEsi();\r
+ case MACADDRESS:\r
+ return isSetMacaddress();\r
+ case L3LABEL:\r
+ return isSetL3label();\r
+ case L2LABEL:\r
+ return isSetL2label();\r
+ case AFI:\r
+ return isSetAfi();\r
+ }\r
+ throw new IllegalStateException();\r
+ }\r
+\r
+ @Override\r
+ public boolean equals(Object that) {\r
+ if (that == null)\r
+ return false;\r
+ if (that instanceof onUpdateWithdrawRoute_args)\r
+ return this.equals((onUpdateWithdrawRoute_args)that);\r
+ return false;\r
+ }\r
+\r
+ public boolean equals(onUpdateWithdrawRoute_args that) {\r
+ if (that == null)\r
+ return false;\r
+\r
+ boolean this_present_p_type = true && this.isSetP_type();\r
+ boolean that_present_p_type = true && that.isSetP_type();\r
+ if (this_present_p_type || that_present_p_type) {\r
+ if (!(this_present_p_type && that_present_p_type))\r
+ return false;\r
+ if (!this.p_type.equals(that.p_type))\r
+ return false;\r
+ }\r
+\r
+ boolean this_present_rd = true && this.isSetRd();\r
+ boolean that_present_rd = true && that.isSetRd();\r
+ if (this_present_rd || that_present_rd) {\r
+ if (!(this_present_rd && that_present_rd))\r
+ return false;\r
+ if (!this.rd.equals(that.rd))\r
+ return false;\r
+ }\r
+\r
+ boolean this_present_prefix = true && this.isSetPrefix();\r
+ boolean that_present_prefix = true && that.isSetPrefix();\r
+ if (this_present_prefix || that_present_prefix) {\r
+ if (!(this_present_prefix && that_present_prefix))\r
+ return false;\r
+ if (!this.prefix.equals(that.prefix))\r
+ return false;\r
+ }\r
+\r
+ boolean this_present_prefixlen = true;\r
+ boolean that_present_prefixlen = true;\r
+ if (this_present_prefixlen || that_present_prefixlen) {\r
+ if (!(this_present_prefixlen && that_present_prefixlen))\r
+ return false;\r
+ if (this.prefixlen != that.prefixlen)\r
+ return false;\r
+ }\r
+\r
+ boolean this_present_nexthop = true && this.isSetNexthop();\r
+ boolean that_present_nexthop = true && that.isSetNexthop();\r
+ if (this_present_nexthop || that_present_nexthop) {\r
+ if (!(this_present_nexthop && that_present_nexthop))\r
+ return false;\r
+ if (!this.nexthop.equals(that.nexthop))\r
+ return false;\r
+ }\r
+\r
+ boolean this_present_ethtag = true;\r
+ boolean that_present_ethtag = true;\r
+ if (this_present_ethtag || that_present_ethtag) {\r
+ if (!(this_present_ethtag && that_present_ethtag))\r
+ return false;\r
+ if (this.ethtag != that.ethtag)\r
+ return false;\r
+ }\r
+\r
+ boolean this_present_esi = true && this.isSetEsi();\r
+ boolean that_present_esi = true && that.isSetEsi();\r
+ if (this_present_esi || that_present_esi) {\r
+ if (!(this_present_esi && that_present_esi))\r
+ return false;\r
+ if (!this.esi.equals(that.esi))\r
+ return false;\r
+ }\r
+\r
+ boolean this_present_macaddress = true && this.isSetMacaddress();\r
+ boolean that_present_macaddress = true && that.isSetMacaddress();\r
+ if (this_present_macaddress || that_present_macaddress) {\r
+ if (!(this_present_macaddress && that_present_macaddress))\r
+ return false;\r
+ if (!this.macaddress.equals(that.macaddress))\r
+ return false;\r
+ }\r
+\r
+ boolean this_present_l3label = true;\r
+ boolean that_present_l3label = true;\r
+ if (this_present_l3label || that_present_l3label) {\r
+ if (!(this_present_l3label && that_present_l3label))\r
+ return false;\r
+ if (this.l3label != that.l3label)\r
+ return false;\r
+ }\r
+\r
+ boolean this_present_l2label = true;\r
+ boolean that_present_l2label = true;\r
+ if (this_present_l2label || that_present_l2label) {\r
+ if (!(this_present_l2label && that_present_l2label))\r
+ return false;\r
+ if (this.l2label != that.l2label)\r
+ return false;\r
+ }\r
+\r
+ boolean this_present_afi = true && this.isSetAfi();\r
+ boolean that_present_afi = true && that.isSetAfi();\r
+ if (this_present_afi || that_present_afi) {\r
+ if (!(this_present_afi && that_present_afi))\r
+ return false;\r
+ if (!this.afi.equals(that.afi))\r
+ return false;\r
+ }\r
+\r
+ return true;\r
+ }\r
+\r
+ @Override\r
+ public int hashCode() {\r
+ List<Object> list = new ArrayList<Object>();\r
+\r
+ boolean present_p_type = true && (isSetP_type());\r
+ list.add(present_p_type);\r
+ if (present_p_type)\r
+ list.add(p_type.getValue());\r
+\r
+ boolean present_rd = true && (isSetRd());\r
+ list.add(present_rd);\r
+ if (present_rd)\r
+ list.add(rd);\r
+\r
+ boolean present_prefix = true && (isSetPrefix());\r
+ list.add(present_prefix);\r
+ if (present_prefix)\r
+ list.add(prefix);\r
+\r
+ boolean present_prefixlen = true;\r
+ list.add(present_prefixlen);\r
+ if (present_prefixlen)\r
+ list.add(prefixlen);\r
+\r
+ boolean present_nexthop = true && (isSetNexthop());\r
+ list.add(present_nexthop);\r
+ if (present_nexthop)\r
+ list.add(nexthop);\r
+\r
+ boolean present_ethtag = true;\r
+ list.add(present_ethtag);\r
+ if (present_ethtag)\r
+ list.add(ethtag);\r
+\r
+ boolean present_esi = true && (isSetEsi());\r
+ list.add(present_esi);\r
+ if (present_esi)\r
+ list.add(esi);\r
+\r
+ boolean present_macaddress = true && (isSetMacaddress());\r
+ list.add(present_macaddress);\r
+ if (present_macaddress)\r
+ list.add(macaddress);\r
+\r
+ boolean present_l3label = true;\r
+ list.add(present_l3label);\r
+ if (present_l3label)\r
+ list.add(l3label);\r
+\r
+ boolean present_l2label = true;\r
+ list.add(present_l2label);\r
+ if (present_l2label)\r
+ list.add(l2label);\r
+\r
+ boolean present_afi = true && (isSetAfi());\r
+ list.add(present_afi);\r
+ if (present_afi)\r
+ list.add(afi.getValue());\r
+\r
+ return list.hashCode();\r
+ }\r
+\r
+ @Override\r
+ public int compareTo(onUpdateWithdrawRoute_args other) {\r
+ if (!getClass().equals(other.getClass())) {\r
+ return getClass().getName().compareTo(other.getClass().getName());\r
+ }\r
+\r
+ int lastComparison = 0;\r
+\r
+ lastComparison = Boolean.valueOf(isSetP_type()).compareTo(other.isSetP_type());\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ if (isSetP_type()) {\r
+ lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.p_type, other.p_type);\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ }\r
+ lastComparison = Boolean.valueOf(isSetRd()).compareTo(other.isSetRd());\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ if (isSetRd()) {\r
+ lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.rd, other.rd);\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ }\r
+ lastComparison = Boolean.valueOf(isSetPrefix()).compareTo(other.isSetPrefix());\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ if (isSetPrefix()) {\r
+ lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.prefix, other.prefix);\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ }\r
+ lastComparison = Boolean.valueOf(isSetPrefixlen()).compareTo(other.isSetPrefixlen());\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ if (isSetPrefixlen()) {\r
+ lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.prefixlen, other.prefixlen);\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ }\r
+ lastComparison = Boolean.valueOf(isSetNexthop()).compareTo(other.isSetNexthop());\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ if (isSetNexthop()) {\r
+ lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.nexthop, other.nexthop);\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ }\r
+ lastComparison = Boolean.valueOf(isSetEthtag()).compareTo(other.isSetEthtag());\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ if (isSetEthtag()) {\r
+ lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.ethtag, other.ethtag);\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ }\r
+ lastComparison = Boolean.valueOf(isSetEsi()).compareTo(other.isSetEsi());\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ if (isSetEsi()) {\r
+ lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.esi, other.esi);\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ }\r
+ lastComparison = Boolean.valueOf(isSetMacaddress()).compareTo(other.isSetMacaddress());\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ if (isSetMacaddress()) {\r
+ lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.macaddress, other.macaddress);\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ }\r
+ lastComparison = Boolean.valueOf(isSetL3label()).compareTo(other.isSetL3label());\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ if (isSetL3label()) {\r
+ lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.l3label, other.l3label);\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ }\r
+ lastComparison = Boolean.valueOf(isSetL2label()).compareTo(other.isSetL2label());\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ if (isSetL2label()) {\r
+ lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.l2label, other.l2label);\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ }\r
+ lastComparison = Boolean.valueOf(isSetAfi()).compareTo(other.isSetAfi());\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ if (isSetAfi()) {\r
+ lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.afi, other.afi);\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ }\r
+ return 0;\r
+ }\r
+\r
+ public _Fields fieldForId(int fieldId) {\r
+ return _Fields.findByThriftId(fieldId);\r
+ }\r
+\r
+ public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {\r
+ schemes.get(iprot.getScheme()).getScheme().read(iprot, this);\r
+ }\r
+\r
+ public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {\r
+ schemes.get(oprot.getScheme()).getScheme().write(oprot, this);\r
+ }\r
+\r
+ @Override\r
+ public String toString() {\r
+ StringBuilder sb = new StringBuilder("onUpdateWithdrawRoute_args(");\r
+ boolean first = true;\r
+\r
+ sb.append("p_type:");\r
+ if (this.p_type == null) {\r
+ sb.append("null");\r
+ } else {\r
+ sb.append(this.p_type);\r
+ }\r
+ first = false;\r
+ if (!first) sb.append(", ");\r
+ sb.append("rd:");\r
+ if (this.rd == null) {\r
+ sb.append("null");\r
+ } else {\r
+ sb.append(this.rd);\r
+ }\r
+ first = false;\r
+ if (!first) sb.append(", ");\r
+ sb.append("prefix:");\r
+ if (this.prefix == null) {\r
+ sb.append("null");\r
+ } else {\r
+ sb.append(this.prefix);\r
+ }\r
+ first = false;\r
+ if (!first) sb.append(", ");\r
+ sb.append("prefixlen:");\r
+ sb.append(this.prefixlen);\r
+ first = false;\r
+ if (!first) sb.append(", ");\r
+ sb.append("nexthop:");\r
+ if (this.nexthop == null) {\r
+ sb.append("null");\r
+ } else {\r
+ sb.append(this.nexthop);\r
+ }\r
+ first = false;\r
+ if (!first) sb.append(", ");\r
+ sb.append("ethtag:");\r
+ sb.append(this.ethtag);\r
+ first = false;\r
+ if (!first) sb.append(", ");\r
+ sb.append("esi:");\r
+ if (this.esi == null) {\r
+ sb.append("null");\r
+ } else {\r
+ sb.append(this.esi);\r
+ }\r
+ first = false;\r
+ if (!first) sb.append(", ");\r
+ sb.append("macaddress:");\r
+ if (this.macaddress == null) {\r
+ sb.append("null");\r
+ } else {\r
+ sb.append(this.macaddress);\r
+ }\r
+ first = false;\r
+ if (!first) sb.append(", ");\r
+ sb.append("l3label:");\r
+ sb.append(this.l3label);\r
+ first = false;\r
+ if (!first) sb.append(", ");\r
+ sb.append("l2label:");\r
+ sb.append(this.l2label);\r
+ first = false;\r
+ if (!first) sb.append(", ");\r
+ sb.append("afi:");\r
+ if (this.afi == null) {\r
+ sb.append("null");\r
+ } else {\r
+ sb.append(this.afi);\r
+ }\r
+ first = false;\r
+ sb.append(")");\r
+ return sb.toString();\r
+ }\r
+\r
+ public void validate() throws org.apache.thrift.TException {\r
+ // check for required fields\r
+ // check for sub-struct validity\r
+ }\r
+\r
+ private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {\r
+ try {\r
+ write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));\r
+ } catch (org.apache.thrift.TException te) {\r
+ throw new java.io.IOException(te);\r
+ }\r
+ }\r
+\r
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {\r
+ try {\r
+ // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.\r
+ __isset_bitfield = 0;\r
+ read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));\r
+ } catch (org.apache.thrift.TException te) {\r
+ throw new java.io.IOException(te);\r
+ }\r
+ }\r
+\r
+ private static class onUpdateWithdrawRoute_argsStandardSchemeFactory implements SchemeFactory {\r
+ public onUpdateWithdrawRoute_argsStandardScheme getScheme() {\r
+ return new onUpdateWithdrawRoute_argsStandardScheme();\r
+ }\r
+ }\r
+\r
+ private static class onUpdateWithdrawRoute_argsStandardScheme extends StandardScheme<onUpdateWithdrawRoute_args> {\r
+\r
+ public void read(org.apache.thrift.protocol.TProtocol iprot, onUpdateWithdrawRoute_args struct) throws org.apache.thrift.TException {\r
+ org.apache.thrift.protocol.TField schemeField;\r
+ iprot.readStructBegin();\r
+ while (true)\r
+ {\r
+ schemeField = iprot.readFieldBegin();\r
+ if (schemeField.type == org.apache.thrift.protocol.TType.STOP) {\r
+ break;\r
+ }\r
+ switch (schemeField.id) {\r
+ case 1: // P_TYPE\r
+ if (schemeField.type == org.apache.thrift.protocol.TType.I32) {\r
+ struct.p_type = protocol_type.findByValue(iprot.readI32());\r
+ struct.setP_typeIsSet(true);\r
+ } else {\r
+ org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);\r
+ }\r
+ break;\r
+ case 2: // RD\r
+ if (schemeField.type == org.apache.thrift.protocol.TType.STRING) {\r
+ struct.rd = iprot.readString();\r
+ struct.setRdIsSet(true);\r
+ } else {\r
+ org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);\r
+ }\r
+ break;\r
+ case 3: // PREFIX\r
+ if (schemeField.type == org.apache.thrift.protocol.TType.STRING) {\r
+ struct.prefix = iprot.readString();\r
+ struct.setPrefixIsSet(true);\r
+ } else {\r
+ org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);\r
+ }\r
+ break;\r
+ case 4: // PREFIXLEN\r
+ if (schemeField.type == org.apache.thrift.protocol.TType.I32) {\r
+ struct.prefixlen = iprot.readI32();\r
+ struct.setPrefixlenIsSet(true);\r
+ } else {\r
+ org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);\r
+ }\r
+ break;\r
+ case 5: // NEXTHOP\r
+ if (schemeField.type == org.apache.thrift.protocol.TType.STRING) {\r
+ struct.nexthop = iprot.readString();\r
+ struct.setNexthopIsSet(true);\r
+ } else {\r
+ org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);\r
+ }\r
+ break;\r
+ case 6: // ETHTAG\r
+ if (schemeField.type == org.apache.thrift.protocol.TType.I64) {\r
+ struct.ethtag = iprot.readI64();\r
+ struct.setEthtagIsSet(true);\r
+ } else {\r
+ org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);\r
+ }\r
+ break;\r
+ case 7: // ESI\r
+ if (schemeField.type == org.apache.thrift.protocol.TType.STRING) {\r
+ struct.esi = iprot.readString();\r
+ struct.setEsiIsSet(true);\r
+ } else {\r
+ org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);\r
+ }\r
+ break;\r
+ case 8: // MACADDRESS\r
+ if (schemeField.type == org.apache.thrift.protocol.TType.STRING) {\r
+ struct.macaddress = iprot.readString();\r
+ struct.setMacaddressIsSet(true);\r
+ } else {\r
+ org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);\r
+ }\r
+ break;\r
+ case 9: // L3LABEL\r
+ if (schemeField.type == org.apache.thrift.protocol.TType.I32) {\r
+ struct.l3label = iprot.readI32();\r
+ struct.setL3labelIsSet(true);\r
+ } else {\r
+ org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);\r
+ }\r
+ break;\r
+ case 10: // L2LABEL\r
+ if (schemeField.type == org.apache.thrift.protocol.TType.I32) {\r
+ struct.l2label = iprot.readI32();\r
+ struct.setL2labelIsSet(true);\r
+ } else {\r
+ org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);\r
+ }\r
+ break;\r
+ case 11: // AFI\r
+ if (schemeField.type == org.apache.thrift.protocol.TType.I32) {\r
+ struct.afi = af_afi.findByValue(iprot.readI32());\r
+ struct.setAfiIsSet(true);\r
+ } else {\r
+ org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);\r
+ }\r
+ break;\r
+ default:\r
+ org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);\r
+ }\r
+ iprot.readFieldEnd();\r
+ }\r
+ iprot.readStructEnd();\r
+\r
+ // check for required fields of primitive type, which can't be checked in the validate method\r
+ struct.validate();\r
+ }\r
+\r
+ public void write(org.apache.thrift.protocol.TProtocol oprot, onUpdateWithdrawRoute_args struct) throws org.apache.thrift.TException {\r
+ struct.validate();\r
+\r
+ oprot.writeStructBegin(STRUCT_DESC);\r
+ if (struct.p_type != null) {\r
+ oprot.writeFieldBegin(P_TYPE_FIELD_DESC);\r
+ oprot.writeI32(struct.p_type.getValue());\r
+ oprot.writeFieldEnd();\r
+ }\r
+ if (struct.rd != null) {\r
+ oprot.writeFieldBegin(RD_FIELD_DESC);\r
+ oprot.writeString(struct.rd);\r
+ oprot.writeFieldEnd();\r
+ }\r
+ if (struct.prefix != null) {\r
+ oprot.writeFieldBegin(PREFIX_FIELD_DESC);\r
+ oprot.writeString(struct.prefix);\r
+ oprot.writeFieldEnd();\r
+ }\r
+ oprot.writeFieldBegin(PREFIXLEN_FIELD_DESC);\r
+ oprot.writeI32(struct.prefixlen);\r
+ oprot.writeFieldEnd();\r
+ if (struct.nexthop != null) {\r
+ oprot.writeFieldBegin(NEXTHOP_FIELD_DESC);\r
+ oprot.writeString(struct.nexthop);\r
+ oprot.writeFieldEnd();\r
+ }\r
+ oprot.writeFieldBegin(ETHTAG_FIELD_DESC);\r
+ oprot.writeI64(struct.ethtag);\r
+ oprot.writeFieldEnd();\r
+ if (struct.esi != null) {\r
+ oprot.writeFieldBegin(ESI_FIELD_DESC);\r
+ oprot.writeString(struct.esi);\r
+ oprot.writeFieldEnd();\r
+ }\r
+ if (struct.macaddress != null) {\r
+ oprot.writeFieldBegin(MACADDRESS_FIELD_DESC);\r
+ oprot.writeString(struct.macaddress);\r
+ oprot.writeFieldEnd();\r
+ }\r
+ oprot.writeFieldBegin(L3LABEL_FIELD_DESC);\r
+ oprot.writeI32(struct.l3label);\r
+ oprot.writeFieldEnd();\r
+ oprot.writeFieldBegin(L2LABEL_FIELD_DESC);\r
+ oprot.writeI32(struct.l2label);\r
+ oprot.writeFieldEnd();\r
+ if (struct.afi != null) {\r
+ oprot.writeFieldBegin(AFI_FIELD_DESC);\r
+ oprot.writeI32(struct.afi.getValue());\r
+ oprot.writeFieldEnd();\r
+ }\r
+ oprot.writeFieldStop();\r
+ oprot.writeStructEnd();\r
+ }\r
+\r
+ }\r
+\r
+ private static class onUpdateWithdrawRoute_argsTupleSchemeFactory implements SchemeFactory {\r
+ public onUpdateWithdrawRoute_argsTupleScheme getScheme() {\r
+ return new onUpdateWithdrawRoute_argsTupleScheme();\r
+ }\r
+ }\r
+\r
+ private static class onUpdateWithdrawRoute_argsTupleScheme extends TupleScheme<onUpdateWithdrawRoute_args> {\r
+\r
+ @Override\r
+ public void write(org.apache.thrift.protocol.TProtocol prot, onUpdateWithdrawRoute_args struct) throws org.apache.thrift.TException {\r
+ TTupleProtocol oprot = (TTupleProtocol) prot;\r
+ BitSet optionals = new BitSet();\r
+ if (struct.isSetP_type()) {\r
+ optionals.set(0);\r
+ }\r
+ if (struct.isSetRd()) {\r
+ optionals.set(1);\r
+ }\r
+ if (struct.isSetPrefix()) {\r
+ optionals.set(2);\r
+ }\r
+ if (struct.isSetPrefixlen()) {\r
+ optionals.set(3);\r
+ }\r
+ if (struct.isSetNexthop()) {\r
+ optionals.set(4);\r
+ }\r
+ if (struct.isSetEthtag()) {\r
+ optionals.set(5);\r
+ }\r
+ if (struct.isSetEsi()) {\r
+ optionals.set(6);\r
+ }\r
+ if (struct.isSetMacaddress()) {\r
+ optionals.set(7);\r
+ }\r
+ if (struct.isSetL3label()) {\r
+ optionals.set(8);\r
+ }\r
+ if (struct.isSetL2label()) {\r
+ optionals.set(9);\r
+ }\r
+ if (struct.isSetAfi()) {\r
+ optionals.set(10);\r
+ }\r
+ oprot.writeBitSet(optionals, 11);\r
+ if (struct.isSetP_type()) {\r
+ oprot.writeI32(struct.p_type.getValue());\r
+ }\r
+ if (struct.isSetRd()) {\r
+ oprot.writeString(struct.rd);\r
+ }\r
+ if (struct.isSetPrefix()) {\r
+ oprot.writeString(struct.prefix);\r
+ }\r
+ if (struct.isSetPrefixlen()) {\r
+ oprot.writeI32(struct.prefixlen);\r
+ }\r
+ if (struct.isSetNexthop()) {\r
+ oprot.writeString(struct.nexthop);\r
+ }\r
+ if (struct.isSetEthtag()) {\r
+ oprot.writeI64(struct.ethtag);\r
+ }\r
+ if (struct.isSetEsi()) {\r
+ oprot.writeString(struct.esi);\r
+ }\r
+ if (struct.isSetMacaddress()) {\r
+ oprot.writeString(struct.macaddress);\r
+ }\r
+ if (struct.isSetL3label()) {\r
+ oprot.writeI32(struct.l3label);\r
+ }\r
+ if (struct.isSetL2label()) {\r
+ oprot.writeI32(struct.l2label);\r
+ }\r
+ if (struct.isSetAfi()) {\r
+ oprot.writeI32(struct.afi.getValue());\r
+ }\r
+ }\r
+\r
+ @Override\r
+ public void read(org.apache.thrift.protocol.TProtocol prot, onUpdateWithdrawRoute_args struct) throws org.apache.thrift.TException {\r
+ TTupleProtocol iprot = (TTupleProtocol) prot;\r
+ BitSet incoming = iprot.readBitSet(11);\r
+ if (incoming.get(0)) {\r
+ struct.p_type = protocol_type.findByValue(iprot.readI32());\r
+ struct.setP_typeIsSet(true);\r
+ }\r
+ if (incoming.get(1)) {\r
+ struct.rd = iprot.readString();\r
+ struct.setRdIsSet(true);\r
+ }\r
+ if (incoming.get(2)) {\r
+ struct.prefix = iprot.readString();\r
+ struct.setPrefixIsSet(true);\r
+ }\r
+ if (incoming.get(3)) {\r
+ struct.prefixlen = iprot.readI32();\r
+ struct.setPrefixlenIsSet(true);\r
+ }\r
+ if (incoming.get(4)) {\r
+ struct.nexthop = iprot.readString();\r
+ struct.setNexthopIsSet(true);\r
+ }\r
+ if (incoming.get(5)) {\r
+ struct.ethtag = iprot.readI64();\r
+ struct.setEthtagIsSet(true);\r
+ }\r
+ if (incoming.get(6)) {\r
+ struct.esi = iprot.readString();\r
+ struct.setEsiIsSet(true);\r
+ }\r
+ if (incoming.get(7)) {\r
+ struct.macaddress = iprot.readString();\r
+ struct.setMacaddressIsSet(true);\r
+ }\r
+ if (incoming.get(8)) {\r
+ struct.l3label = iprot.readI32();\r
+ struct.setL3labelIsSet(true);\r
+ }\r
+ if (incoming.get(9)) {\r
+ struct.l2label = iprot.readI32();\r
+ struct.setL2labelIsSet(true);\r
+ }\r
+ if (incoming.get(10)) {\r
+ struct.afi = af_afi.findByValue(iprot.readI32());\r
+ struct.setAfiIsSet(true);\r
+ }\r
+ }\r
+ }\r
+\r
+ }\r
+\r
+ public static class onStartConfigResyncNotification_args implements org.apache.thrift.TBase<onStartConfigResyncNotification_args, onStartConfigResyncNotification_args._Fields>, java.io.Serializable, Cloneable, Comparable<onStartConfigResyncNotification_args> {\r
+ private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("onStartConfigResyncNotification_args");\r
+\r
+\r
+ private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();\r
+ static {\r
+ schemes.put(StandardScheme.class, new onStartConfigResyncNotification_argsStandardSchemeFactory());\r
+ schemes.put(TupleScheme.class, new onStartConfigResyncNotification_argsTupleSchemeFactory());\r
+ }\r
+\r
+\r
+ /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */\r
+ public enum _Fields implements org.apache.thrift.TFieldIdEnum {\r
+;\r
+\r
+ private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();\r
+\r
+ static {\r
+ for (_Fields field : EnumSet.allOf(_Fields.class)) {\r
+ byName.put(field.getFieldName(), field);\r
+ }\r
+ }\r
+\r
+ /**\r
+ * Find the _Fields constant that matches fieldId, or null if its not found.\r
+ */\r
+ public static _Fields findByThriftId(int fieldId) {\r
+ switch(fieldId) {\r
+ default:\r
+ return null;\r
+ }\r
+ }\r
+\r
+ /**\r
+ * Find the _Fields constant that matches fieldId, throwing an exception\r
+ * if it is not found.\r
+ */\r
+ public static _Fields findByThriftIdOrThrow(int fieldId) {\r
+ _Fields fields = findByThriftId(fieldId);\r
+ if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");\r
+ return fields;\r
+ }\r
+\r
+ /**\r
+ * Find the _Fields constant that matches name, or null if its not found.\r
+ */\r
+ public static _Fields findByName(String name) {\r
+ return byName.get(name);\r
+ }\r
+\r
+ private final short _thriftId;\r
+ private final String _fieldName;\r
+\r
+ _Fields(short thriftId, String fieldName) {\r
+ _thriftId = thriftId;\r
+ _fieldName = fieldName;\r
+ }\r
+\r
+ public short getThriftFieldId() {\r
+ return _thriftId;\r
+ }\r
+\r
+ public String getFieldName() {\r
+ return _fieldName;\r
+ }\r
+ }\r
+ public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;\r
+ static {\r
+ Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);\r
+ metaDataMap = Collections.unmodifiableMap(tmpMap);\r
+ org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(onStartConfigResyncNotification_args.class, metaDataMap);\r
+ }\r
+\r
+ public onStartConfigResyncNotification_args() {\r
+ }\r
+\r
+ /**\r
+ * Performs a deep copy on <i>other</i>.\r
+ */\r
+ public onStartConfigResyncNotification_args(onStartConfigResyncNotification_args other) {\r
+ }\r
+\r
+ public onStartConfigResyncNotification_args deepCopy() {\r
+ return new onStartConfigResyncNotification_args(this);\r
+ }\r
+\r
+ @Override\r
+ public void clear() {\r
+ }\r
+\r
+ public void setFieldValue(_Fields field, Object value) {\r
+ switch (field) {\r
+ }\r
+ }\r
+\r
+ public Object getFieldValue(_Fields field) {\r
+ switch (field) {\r
+ }\r
+ throw new IllegalStateException();\r
+ }\r
+\r
+ /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */\r
+ public boolean isSet(_Fields field) {\r
+ if (field == null) {\r
+ throw new IllegalArgumentException();\r
+ }\r
+\r
+ switch (field) {\r
+ }\r
+ throw new IllegalStateException();\r
+ }\r
+\r
+ @Override\r
+ public boolean equals(Object that) {\r
+ if (that == null)\r
+ return false;\r
+ if (that instanceof onStartConfigResyncNotification_args)\r
+ return this.equals((onStartConfigResyncNotification_args)that);\r
+ return false;\r
+ }\r
+\r
+ public boolean equals(onStartConfigResyncNotification_args that) {\r
+ if (that == null)\r
+ return false;\r
+\r
+ return true;\r
+ }\r
+\r
+ @Override\r
+ public int hashCode() {\r
+ List<Object> list = new ArrayList<Object>();\r
+\r
+ return list.hashCode();\r
+ }\r
+\r
+ @Override\r
+ public int compareTo(onStartConfigResyncNotification_args other) {\r
+ if (!getClass().equals(other.getClass())) {\r
+ return getClass().getName().compareTo(other.getClass().getName());\r
+ }\r
+\r
+ int lastComparison = 0;\r
+\r
+ return 0;\r
+ }\r
+\r
+ public _Fields fieldForId(int fieldId) {\r
+ return _Fields.findByThriftId(fieldId);\r
+ }\r
+\r
+ public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {\r
+ schemes.get(iprot.getScheme()).getScheme().read(iprot, this);\r
+ }\r
+\r
+ public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {\r
+ schemes.get(oprot.getScheme()).getScheme().write(oprot, this);\r
+ }\r
+\r
+ @Override\r
+ public String toString() {\r
+ StringBuilder sb = new StringBuilder("onStartConfigResyncNotification_args(");\r
+ boolean first = true;\r
+\r
+ sb.append(")");\r
+ return sb.toString();\r
+ }\r
+\r
+ public void validate() throws org.apache.thrift.TException {\r
+ // check for required fields\r
+ // check for sub-struct validity\r
+ }\r
+\r
+ private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {\r
+ try {\r
+ write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));\r
+ } catch (org.apache.thrift.TException te) {\r
+ throw new java.io.IOException(te);\r
+ }\r
+ }\r
+\r
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {\r
+ try {\r
+ read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));\r
+ } catch (org.apache.thrift.TException te) {\r
+ throw new java.io.IOException(te);\r
+ }\r
+ }\r
+\r
+ private static class onStartConfigResyncNotification_argsStandardSchemeFactory implements SchemeFactory {\r
+ public onStartConfigResyncNotification_argsStandardScheme getScheme() {\r
+ return new onStartConfigResyncNotification_argsStandardScheme();\r
+ }\r
+ }\r
+\r
+ private static class onStartConfigResyncNotification_argsStandardScheme extends StandardScheme<onStartConfigResyncNotification_args> {\r
+\r
+ public void read(org.apache.thrift.protocol.TProtocol iprot, onStartConfigResyncNotification_args struct) throws org.apache.thrift.TException {\r
+ org.apache.thrift.protocol.TField schemeField;\r
+ iprot.readStructBegin();\r
+ while (true)\r
+ {\r
+ schemeField = iprot.readFieldBegin();\r
+ if (schemeField.type == org.apache.thrift.protocol.TType.STOP) {\r
+ break;\r
+ }\r
+ switch (schemeField.id) {\r
+ default:\r
+ org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);\r
+ }\r
+ iprot.readFieldEnd();\r
+ }\r
+ iprot.readStructEnd();\r
+\r
+ // check for required fields of primitive type, which can't be checked in the validate method\r
+ struct.validate();\r
+ }\r
+\r
+ public void write(org.apache.thrift.protocol.TProtocol oprot, onStartConfigResyncNotification_args struct) throws org.apache.thrift.TException {\r
+ struct.validate();\r
+\r
+ oprot.writeStructBegin(STRUCT_DESC);\r
+ oprot.writeFieldStop();\r
+ oprot.writeStructEnd();\r
+ }\r
+\r
+ }\r
+\r
+ private static class onStartConfigResyncNotification_argsTupleSchemeFactory implements SchemeFactory {\r
+ public onStartConfigResyncNotification_argsTupleScheme getScheme() {\r
+ return new onStartConfigResyncNotification_argsTupleScheme();\r
+ }\r
+ }\r
+\r
+ private static class onStartConfigResyncNotification_argsTupleScheme extends TupleScheme<onStartConfigResyncNotification_args> {\r
+\r
+ @Override\r
+ public void write(org.apache.thrift.protocol.TProtocol prot, onStartConfigResyncNotification_args struct) throws org.apache.thrift.TException {\r
+ TTupleProtocol oprot = (TTupleProtocol) prot;\r
+ }\r
+\r
+ @Override\r
+ public void read(org.apache.thrift.protocol.TProtocol prot, onStartConfigResyncNotification_args struct) throws org.apache.thrift.TException {\r
+ TTupleProtocol iprot = (TTupleProtocol) prot;\r
+ }\r
+ }\r
+\r
+ }\r
+\r
+ public static class onNotificationSendEvent_args implements org.apache.thrift.TBase<onNotificationSendEvent_args, onNotificationSendEvent_args._Fields>, java.io.Serializable, Cloneable, Comparable<onNotificationSendEvent_args> {\r
+ private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("onNotificationSendEvent_args");\r
+\r
+ private static final org.apache.thrift.protocol.TField PREFIX_FIELD_DESC = new org.apache.thrift.protocol.TField("prefix", org.apache.thrift.protocol.TType.STRING, (short)1);\r
+ private static final org.apache.thrift.protocol.TField ERR_CODE_FIELD_DESC = new org.apache.thrift.protocol.TField("errCode", org.apache.thrift.protocol.TType.BYTE, (short)2);\r
+ private static final org.apache.thrift.protocol.TField ERR_SUBCODE_FIELD_DESC = new org.apache.thrift.protocol.TField("errSubcode", org.apache.thrift.protocol.TType.BYTE, (short)3);\r
+\r
+ private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();\r
+ static {\r
+ schemes.put(StandardScheme.class, new onNotificationSendEvent_argsStandardSchemeFactory());\r
+ schemes.put(TupleScheme.class, new onNotificationSendEvent_argsTupleSchemeFactory());\r
+ }\r
+\r
+ public String prefix; // required\r
+ public byte errCode; // required\r
+ public byte errSubcode; // required\r
+\r
+ /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */\r
+ public enum _Fields implements org.apache.thrift.TFieldIdEnum {\r
+ PREFIX((short)1, "prefix"),\r
+ ERR_CODE((short)2, "errCode"),\r
+ ERR_SUBCODE((short)3, "errSubcode");\r
+\r
+ private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();\r
+\r
+ static {\r
+ for (_Fields field : EnumSet.allOf(_Fields.class)) {\r
+ byName.put(field.getFieldName(), field);\r
+ }\r
+ }\r
+\r
+ /**\r
+ * Find the _Fields constant that matches fieldId, or null if its not found.\r
+ */\r
+ public static _Fields findByThriftId(int fieldId) {\r
+ switch(fieldId) {\r
+ case 1: // PREFIX\r
+ return PREFIX;\r
+ case 2: // ERR_CODE\r
+ return ERR_CODE;\r
+ case 3: // ERR_SUBCODE\r
+ return ERR_SUBCODE;\r
+ default:\r
+ return null;\r
+ }\r
+ }\r
+\r
+ /**\r
+ * Find the _Fields constant that matches fieldId, throwing an exception\r
+ * if it is not found.\r
+ */\r
+ public static _Fields findByThriftIdOrThrow(int fieldId) {\r
+ _Fields fields = findByThriftId(fieldId);\r
+ if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");\r
+ return fields;\r
+ }\r
+\r
+ /**\r
+ * Find the _Fields constant that matches name, or null if its not found.\r
+ */\r
+ public static _Fields findByName(String name) {\r
+ return byName.get(name);\r
+ }\r
+\r
+ private final short _thriftId;\r
+ private final String _fieldName;\r
+\r
+ _Fields(short thriftId, String fieldName) {\r
+ _thriftId = thriftId;\r
+ _fieldName = fieldName;\r
+ }\r
+\r
+ public short getThriftFieldId() {\r
+ return _thriftId;\r
+ }\r
+\r
+ public String getFieldName() {\r
+ return _fieldName;\r
+ }\r
+ }\r
+\r
+ // isset id assignments\r
+ private static final int __ERRCODE_ISSET_ID = 0;\r
+ private static final int __ERRSUBCODE_ISSET_ID = 1;\r
+ private byte __isset_bitfield = 0;\r
+ public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;\r
+ static {\r
+ Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);\r
+ tmpMap.put(_Fields.PREFIX, new org.apache.thrift.meta_data.FieldMetaData("prefix", org.apache.thrift.TFieldRequirementType.DEFAULT,\r
+ new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));\r
+ tmpMap.put(_Fields.ERR_CODE, new org.apache.thrift.meta_data.FieldMetaData("errCode", org.apache.thrift.TFieldRequirementType.DEFAULT,\r
+ new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.BYTE)));\r
+ tmpMap.put(_Fields.ERR_SUBCODE, new org.apache.thrift.meta_data.FieldMetaData("errSubcode", org.apache.thrift.TFieldRequirementType.DEFAULT,\r
+ new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.BYTE)));\r
+ metaDataMap = Collections.unmodifiableMap(tmpMap);\r
+ org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(onNotificationSendEvent_args.class, metaDataMap);\r
+ }\r
+\r
+ public onNotificationSendEvent_args() {\r
+ }\r
+\r
+ public onNotificationSendEvent_args(\r
+ String prefix,\r
+ byte errCode,\r
+ byte errSubcode)\r
+ {\r
+ this();\r
+ this.prefix = prefix;\r
+ this.errCode = errCode;\r
+ setErrCodeIsSet(true);\r
+ this.errSubcode = errSubcode;\r
+ setErrSubcodeIsSet(true);\r
+ }\r
+\r
+ /**\r
+ * Performs a deep copy on <i>other</i>.\r
+ */\r
+ public onNotificationSendEvent_args(onNotificationSendEvent_args other) {\r
+ __isset_bitfield = other.__isset_bitfield;\r
+ if (other.isSetPrefix()) {\r
+ this.prefix = other.prefix;\r
+ }\r
+ this.errCode = other.errCode;\r
+ this.errSubcode = other.errSubcode;\r
+ }\r
+\r
+ public onNotificationSendEvent_args deepCopy() {\r
+ return new onNotificationSendEvent_args(this);\r
+ }\r
+\r
+ @Override\r
+ public void clear() {\r
+ this.prefix = null;\r
+ setErrCodeIsSet(false);\r
+ this.errCode = 0;\r
+ setErrSubcodeIsSet(false);\r
+ this.errSubcode = 0;\r
+ }\r
+\r
+ public String getPrefix() {\r
+ return this.prefix;\r
+ }\r
+\r
+ public onNotificationSendEvent_args setPrefix(String prefix) {\r
+ this.prefix = prefix;\r
+ return this;\r
+ }\r
+\r
+ public void unsetPrefix() {\r
+ this.prefix = null;\r
+ }\r
+\r
+ /** Returns true if field prefix is set (has been assigned a value) and false otherwise */\r
+ public boolean isSetPrefix() {\r
+ return this.prefix != null;\r
+ }\r
+\r
+ public void setPrefixIsSet(boolean value) {\r
+ if (!value) {\r
+ this.prefix = null;\r
+ }\r
+ }\r
+\r
+ public byte getErrCode() {\r
+ return this.errCode;\r
+ }\r
+\r
+ public onNotificationSendEvent_args setErrCode(byte errCode) {\r
+ this.errCode = errCode;\r
+ setErrCodeIsSet(true);\r
+ return this;\r
+ }\r
+\r
+ public void unsetErrCode() {\r
+ __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __ERRCODE_ISSET_ID);\r
+ }\r
+\r
+ /** Returns true if field errCode is set (has been assigned a value) and false otherwise */\r
+ public boolean isSetErrCode() {\r
+ return EncodingUtils.testBit(__isset_bitfield, __ERRCODE_ISSET_ID);\r
+ }\r
+\r
+ public void setErrCodeIsSet(boolean value) {\r
+ __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __ERRCODE_ISSET_ID, value);\r
+ }\r
+\r
+ public byte getErrSubcode() {\r
+ return this.errSubcode;\r
+ }\r
+\r
+ public onNotificationSendEvent_args setErrSubcode(byte errSubcode) {\r
+ this.errSubcode = errSubcode;\r
+ setErrSubcodeIsSet(true);\r
+ return this;\r
+ }\r
+\r
+ public void unsetErrSubcode() {\r
+ __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __ERRSUBCODE_ISSET_ID);\r
+ }\r
+\r
+ /** Returns true if field errSubcode is set (has been assigned a value) and false otherwise */\r
+ public boolean isSetErrSubcode() {\r
+ return EncodingUtils.testBit(__isset_bitfield, __ERRSUBCODE_ISSET_ID);\r
+ }\r
+\r
+ public void setErrSubcodeIsSet(boolean value) {\r
+ __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __ERRSUBCODE_ISSET_ID, value);\r
+ }\r
+\r
+ public void setFieldValue(_Fields field, Object value) {\r
+ switch (field) {\r
+ case PREFIX:\r
+ if (value == null) {\r
+ unsetPrefix();\r
+ } else {\r
+ setPrefix((String)value);\r
+ }\r
+ break;\r
+\r
+ case ERR_CODE:\r
+ if (value == null) {\r
+ unsetErrCode();\r
+ } else {\r
+ setErrCode((Byte)value);\r
+ }\r
+ break;\r
+\r
+ case ERR_SUBCODE:\r
+ if (value == null) {\r
+ unsetErrSubcode();\r
+ } else {\r
+ setErrSubcode((Byte)value);\r
+ }\r
+ break;\r
+\r
+ }\r
+ }\r
+\r
+ public Object getFieldValue(_Fields field) {\r
+ switch (field) {\r
+ case PREFIX:\r
+ return getPrefix();\r
+\r
+ case ERR_CODE:\r
+ return getErrCode();\r
+\r
+ case ERR_SUBCODE:\r
+ return getErrSubcode();\r
+\r
+ }\r
+ throw new IllegalStateException();\r
+ }\r
+\r
+ /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */\r
+ public boolean isSet(_Fields field) {\r
+ if (field == null) {\r
+ throw new IllegalArgumentException();\r
+ }\r
+\r
+ switch (field) {\r
+ case PREFIX:\r
+ return isSetPrefix();\r
+ case ERR_CODE:\r
+ return isSetErrCode();\r
+ case ERR_SUBCODE:\r
+ return isSetErrSubcode();\r
+ }\r
+ throw new IllegalStateException();\r
+ }\r
+\r
+ @Override\r
+ public boolean equals(Object that) {\r
+ if (that == null)\r
+ return false;\r
+ if (that instanceof onNotificationSendEvent_args)\r
+ return this.equals((onNotificationSendEvent_args)that);\r
+ return false;\r
+ }\r
+\r
+ public boolean equals(onNotificationSendEvent_args that) {\r
+ if (that == null)\r
+ return false;\r
+\r
+ boolean this_present_prefix = true && this.isSetPrefix();\r
+ boolean that_present_prefix = true && that.isSetPrefix();\r
+ if (this_present_prefix || that_present_prefix) {\r
+ if (!(this_present_prefix && that_present_prefix))\r
+ return false;\r
+ if (!this.prefix.equals(that.prefix))\r
+ return false;\r
+ }\r
+\r
+ boolean this_present_errCode = true;\r
+ boolean that_present_errCode = true;\r
+ if (this_present_errCode || that_present_errCode) {\r
+ if (!(this_present_errCode && that_present_errCode))\r
+ return false;\r
+ if (this.errCode != that.errCode)\r
+ return false;\r
+ }\r
+\r
+ boolean this_present_errSubcode = true;\r
+ boolean that_present_errSubcode = true;\r
+ if (this_present_errSubcode || that_present_errSubcode) {\r
+ if (!(this_present_errSubcode && that_present_errSubcode))\r
+ return false;\r
+ if (this.errSubcode != that.errSubcode)\r
+ return false;\r
+ }\r
+\r
+ return true;\r
+ }\r
+\r
+ @Override\r
+ public int hashCode() {\r
+ List<Object> list = new ArrayList<Object>();\r
+\r
+ boolean present_prefix = true && (isSetPrefix());\r
+ list.add(present_prefix);\r
+ if (present_prefix)\r
+ list.add(prefix);\r
+\r
+ boolean present_errCode = true;\r
+ list.add(present_errCode);\r
+ if (present_errCode)\r
+ list.add(errCode);\r
+\r
+ boolean present_errSubcode = true;\r
+ list.add(present_errSubcode);\r
+ if (present_errSubcode)\r
+ list.add(errSubcode);\r
+\r
+ return list.hashCode();\r
+ }\r
+\r
+ @Override\r
+ public int compareTo(onNotificationSendEvent_args other) {\r
+ if (!getClass().equals(other.getClass())) {\r
+ return getClass().getName().compareTo(other.getClass().getName());\r
+ }\r
+\r
+ int lastComparison = 0;\r
+\r
+ lastComparison = Boolean.valueOf(isSetPrefix()).compareTo(other.isSetPrefix());\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ if (isSetPrefix()) {\r
+ lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.prefix, other.prefix);\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ }\r
+ lastComparison = Boolean.valueOf(isSetErrCode()).compareTo(other.isSetErrCode());\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ if (isSetErrCode()) {\r
+ lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.errCode, other.errCode);\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ }\r
+ lastComparison = Boolean.valueOf(isSetErrSubcode()).compareTo(other.isSetErrSubcode());\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ if (isSetErrSubcode()) {\r
+ lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.errSubcode, other.errSubcode);\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ }\r
+ return 0;\r
+ }\r
+\r
+ public _Fields fieldForId(int fieldId) {\r
+ return _Fields.findByThriftId(fieldId);\r
+ }\r
+\r
+ public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {\r
+ schemes.get(iprot.getScheme()).getScheme().read(iprot, this);\r
+ }\r
+\r
+ public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {\r
+ schemes.get(oprot.getScheme()).getScheme().write(oprot, this);\r
+ }\r
+\r
+ @Override\r
+ public String toString() {\r
+ StringBuilder sb = new StringBuilder("onNotificationSendEvent_args(");\r
+ boolean first = true;\r
+\r
+ sb.append("prefix:");\r
+ if (this.prefix == null) {\r
+ sb.append("null");\r
+ } else {\r
+ sb.append(this.prefix);\r
+ }\r
+ first = false;\r
+ if (!first) sb.append(", ");\r
+ sb.append("errCode:");\r
+ sb.append(this.errCode);\r
+ first = false;\r
+ if (!first) sb.append(", ");\r
+ sb.append("errSubcode:");\r
+ sb.append(this.errSubcode);\r
+ first = false;\r
+ sb.append(")");\r
+ return sb.toString();\r
+ }\r
+\r
+ public void validate() throws org.apache.thrift.TException {\r
+ // check for required fields\r
+ // check for sub-struct validity\r
+ }\r
+\r
+ private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {\r
+ try {\r
+ write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));\r
+ } catch (org.apache.thrift.TException te) {\r
+ throw new java.io.IOException(te);\r
+ }\r
+ }\r
+\r
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {\r
+ try {\r
+ // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.\r
+ __isset_bitfield = 0;\r
+ read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));\r
+ } catch (org.apache.thrift.TException te) {\r
+ throw new java.io.IOException(te);\r
+ }\r
+ }\r
+\r
+ private static class onNotificationSendEvent_argsStandardSchemeFactory implements SchemeFactory {\r
+ public onNotificationSendEvent_argsStandardScheme getScheme() {\r
+ return new onNotificationSendEvent_argsStandardScheme();\r
+ }\r
+ }\r
+\r
+ private static class onNotificationSendEvent_argsStandardScheme extends StandardScheme<onNotificationSendEvent_args> {\r
+\r
+ public void read(org.apache.thrift.protocol.TProtocol iprot, onNotificationSendEvent_args struct) throws org.apache.thrift.TException {\r
+ org.apache.thrift.protocol.TField schemeField;\r
+ iprot.readStructBegin();\r
+ while (true)\r
+ {\r
+ schemeField = iprot.readFieldBegin();\r
+ if (schemeField.type == org.apache.thrift.protocol.TType.STOP) {\r
+ break;\r
+ }\r
+ switch (schemeField.id) {\r
+ case 1: // PREFIX\r
+ if (schemeField.type == org.apache.thrift.protocol.TType.STRING) {\r
+ struct.prefix = iprot.readString();\r
+ struct.setPrefixIsSet(true);\r
+ } else {\r
+ org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);\r
+ }\r
+ break;\r
+ case 2: // ERR_CODE\r
+ if (schemeField.type == org.apache.thrift.protocol.TType.BYTE) {\r
+ struct.errCode = iprot.readByte();\r
+ struct.setErrCodeIsSet(true);\r
+ } else {\r
+ org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);\r
+ }\r
+ break;\r
+ case 3: // ERR_SUBCODE\r
+ if (schemeField.type == org.apache.thrift.protocol.TType.BYTE) {\r
+ struct.errSubcode = iprot.readByte();\r
+ struct.setErrSubcodeIsSet(true);\r
+ } else {\r
+ org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);\r
+ }\r
+ break;\r
+ default:\r
+ org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);\r
+ }\r
+ iprot.readFieldEnd();\r
+ }\r
+ iprot.readStructEnd();\r
+\r
+ // check for required fields of primitive type, which can't be checked in the validate method\r
+ struct.validate();\r
+ }\r
+\r
+ public void write(org.apache.thrift.protocol.TProtocol oprot, onNotificationSendEvent_args struct) throws org.apache.thrift.TException {\r
+ struct.validate();\r
+\r
+ oprot.writeStructBegin(STRUCT_DESC);\r
+ if (struct.prefix != null) {\r
+ oprot.writeFieldBegin(PREFIX_FIELD_DESC);\r
+ oprot.writeString(struct.prefix);\r
+ oprot.writeFieldEnd();\r
+ }\r
+ oprot.writeFieldBegin(ERR_CODE_FIELD_DESC);\r
+ oprot.writeByte(struct.errCode);\r
+ oprot.writeFieldEnd();\r
+ oprot.writeFieldBegin(ERR_SUBCODE_FIELD_DESC);\r
+ oprot.writeByte(struct.errSubcode);\r
+ oprot.writeFieldEnd();\r
+ oprot.writeFieldStop();\r
+ oprot.writeStructEnd();\r
+ }\r
+\r
+ }\r
+\r
+ private static class onNotificationSendEvent_argsTupleSchemeFactory implements SchemeFactory {\r
+ public onNotificationSendEvent_argsTupleScheme getScheme() {\r
+ return new onNotificationSendEvent_argsTupleScheme();\r
+ }\r
+ }\r
+\r
+ private static class onNotificationSendEvent_argsTupleScheme extends TupleScheme<onNotificationSendEvent_args> {\r
+\r
+ @Override\r
+ public void write(org.apache.thrift.protocol.TProtocol prot, onNotificationSendEvent_args struct) throws org.apache.thrift.TException {\r
+ TTupleProtocol oprot = (TTupleProtocol) prot;\r
+ BitSet optionals = new BitSet();\r
+ if (struct.isSetPrefix()) {\r
+ optionals.set(0);\r
+ }\r
+ if (struct.isSetErrCode()) {\r
+ optionals.set(1);\r
+ }\r
+ if (struct.isSetErrSubcode()) {\r
+ optionals.set(2);\r
+ }\r
+ oprot.writeBitSet(optionals, 3);\r
+ if (struct.isSetPrefix()) {\r
+ oprot.writeString(struct.prefix);\r
+ }\r
+ if (struct.isSetErrCode()) {\r
+ oprot.writeByte(struct.errCode);\r
+ }\r
+ if (struct.isSetErrSubcode()) {\r
+ oprot.writeByte(struct.errSubcode);\r
+ }\r
+ }\r
+\r
+ @Override\r
+ public void read(org.apache.thrift.protocol.TProtocol prot, onNotificationSendEvent_args struct) throws org.apache.thrift.TException {\r
+ TTupleProtocol iprot = (TTupleProtocol) prot;\r
+ BitSet incoming = iprot.readBitSet(3);\r
+ if (incoming.get(0)) {\r
+ struct.prefix = iprot.readString();\r
+ struct.setPrefixIsSet(true);\r
+ }\r
+ if (incoming.get(1)) {\r
+ struct.errCode = iprot.readByte();\r
+ struct.setErrCodeIsSet(true);\r
+ }\r
+ if (incoming.get(2)) {\r
+ struct.errSubcode = iprot.readByte();\r
+ struct.setErrSubcodeIsSet(true);\r
+ }\r
+ }\r
+ }\r
+\r
+ }\r
+\r
+ public static class peerDown_args implements org.apache.thrift.TBase<peerDown_args, peerDown_args._Fields>, java.io.Serializable, Cloneable, Comparable<peerDown_args> {\r
+ private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("peerDown_args");\r
+\r
+ private static final org.apache.thrift.protocol.TField IP_ADDRESS_FIELD_DESC = new org.apache.thrift.protocol.TField("ipAddress", org.apache.thrift.protocol.TType.STRING, (short)1);\r
+ private static final org.apache.thrift.protocol.TField AS_NUMBER_FIELD_DESC = new org.apache.thrift.protocol.TField("asNumber", org.apache.thrift.protocol.TType.I64, (short)2);\r
+\r
+ private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();\r
+ static {\r
+ schemes.put(StandardScheme.class, new peerDown_argsStandardSchemeFactory());\r
+ schemes.put(TupleScheme.class, new peerDown_argsTupleSchemeFactory());\r
+ }\r
+\r
+ public String ipAddress; // required\r
+ public long asNumber; // required\r
+\r
+ /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */\r
+ public enum _Fields implements org.apache.thrift.TFieldIdEnum {\r
+ IP_ADDRESS((short)1, "ipAddress"),\r
+ AS_NUMBER((short)2, "asNumber");\r
+\r
+ private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();\r
+\r
+ static {\r
+ for (_Fields field : EnumSet.allOf(_Fields.class)) {\r
+ byName.put(field.getFieldName(), field);\r
+ }\r
+ }\r
+\r
+ /**\r
+ * Find the _Fields constant that matches fieldId, or null if its not found.\r
+ */\r
+ public static _Fields findByThriftId(int fieldId) {\r
+ switch(fieldId) {\r
+ case 1: // IP_ADDRESS\r
+ return IP_ADDRESS;\r
+ case 2: // AS_NUMBER\r
+ return AS_NUMBER;\r
+ default:\r
+ return null;\r
+ }\r
+ }\r
+\r
+ /**\r
+ * Find the _Fields constant that matches fieldId, throwing an exception\r
+ * if it is not found.\r
+ */\r
+ public static _Fields findByThriftIdOrThrow(int fieldId) {\r
+ _Fields fields = findByThriftId(fieldId);\r
+ if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");\r
+ return fields;\r
+ }\r
+\r
+ /**\r
+ * Find the _Fields constant that matches name, or null if its not found.\r
+ */\r
+ public static _Fields findByName(String name) {\r
+ return byName.get(name);\r
+ }\r
+\r
+ private final short _thriftId;\r
+ private final String _fieldName;\r
+\r
+ _Fields(short thriftId, String fieldName) {\r
+ _thriftId = thriftId;\r
+ _fieldName = fieldName;\r
+ }\r
+\r
+ public short getThriftFieldId() {\r
+ return _thriftId;\r
+ }\r
+\r
+ public String getFieldName() {\r
+ return _fieldName;\r
+ }\r
+ }\r
+\r
+ // isset id assignments\r
+ private static final int __ASNUMBER_ISSET_ID = 0;\r
+ private byte __isset_bitfield = 0;\r
+ public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;\r
+ static {\r
+ Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);\r
+ tmpMap.put(_Fields.IP_ADDRESS, new org.apache.thrift.meta_data.FieldMetaData("ipAddress", org.apache.thrift.TFieldRequirementType.DEFAULT,\r
+ new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));\r
+ tmpMap.put(_Fields.AS_NUMBER, new org.apache.thrift.meta_data.FieldMetaData("asNumber", org.apache.thrift.TFieldRequirementType.DEFAULT,\r
+ new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));\r
+ metaDataMap = Collections.unmodifiableMap(tmpMap);\r
+ org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(peerDown_args.class, metaDataMap);\r
+ }\r
+\r
+ public peerDown_args() {\r
+ }\r
+\r
+ public peerDown_args(\r
+ String ipAddress,\r
+ long asNumber)\r
+ {\r
+ this();\r
+ this.ipAddress = ipAddress;\r
+ this.asNumber = asNumber;\r
+ setAsNumberIsSet(true);\r
+ }\r
+\r
+ /**\r
+ * Performs a deep copy on <i>other</i>.\r
+ */\r
+ public peerDown_args(peerDown_args other) {\r
+ __isset_bitfield = other.__isset_bitfield;\r
+ if (other.isSetIpAddress()) {\r
+ this.ipAddress = other.ipAddress;\r
+ }\r
+ this.asNumber = other.asNumber;\r
+ }\r
+\r
+ public peerDown_args deepCopy() {\r
+ return new peerDown_args(this);\r
+ }\r
+\r
+ @Override\r
+ public void clear() {\r
+ this.ipAddress = null;\r
+ setAsNumberIsSet(false);\r
+ this.asNumber = 0;\r
+ }\r
+\r
+ public String getIpAddress() {\r
+ return this.ipAddress;\r
+ }\r
+\r
+ public peerDown_args setIpAddress(String ipAddress) {\r
+ this.ipAddress = ipAddress;\r
+ return this;\r
+ }\r
+\r
+ public void unsetIpAddress() {\r
+ this.ipAddress = null;\r
+ }\r
+\r
+ /** Returns true if field ipAddress is set (has been assigned a value) and false otherwise */\r
+ public boolean isSetIpAddress() {\r
+ return this.ipAddress != null;\r
+ }\r
+\r
+ public void setIpAddressIsSet(boolean value) {\r
+ if (!value) {\r
+ this.ipAddress = null;\r
+ }\r
+ }\r
+\r
+ public long getAsNumber() {\r
+ return this.asNumber;\r
+ }\r
+\r
+ public peerDown_args setAsNumber(long asNumber) {\r
+ this.asNumber = asNumber;\r
+ setAsNumberIsSet(true);\r
+ return this;\r
+ }\r
+\r
+ public void unsetAsNumber() {\r
+ __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __ASNUMBER_ISSET_ID);\r
+ }\r
+\r
+ /** Returns true if field asNumber is set (has been assigned a value) and false otherwise */\r
+ public boolean isSetAsNumber() {\r
+ return EncodingUtils.testBit(__isset_bitfield, __ASNUMBER_ISSET_ID);\r
+ }\r
+\r
+ public void setAsNumberIsSet(boolean value) {\r
+ __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __ASNUMBER_ISSET_ID, value);\r
+ }\r
+\r
+ public void setFieldValue(_Fields field, Object value) {\r
+ switch (field) {\r
+ case IP_ADDRESS:\r
+ if (value == null) {\r
+ unsetIpAddress();\r
+ } else {\r
+ setIpAddress((String)value);\r
+ }\r
+ break;\r
+\r
+ case AS_NUMBER:\r
+ if (value == null) {\r
+ unsetAsNumber();\r
+ } else {\r
+ setAsNumber((Long)value);\r
+ }\r
+ break;\r
+\r
+ }\r
+ }\r
+\r
+ public Object getFieldValue(_Fields field) {\r
+ switch (field) {\r
+ case IP_ADDRESS:\r
+ return getIpAddress();\r
+\r
+ case AS_NUMBER:\r
+ return getAsNumber();\r
+\r
+ }\r
+ throw new IllegalStateException();\r
+ }\r
+\r
+ /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */\r
+ public boolean isSet(_Fields field) {\r
+ if (field == null) {\r
+ throw new IllegalArgumentException();\r
+ }\r
+\r
+ switch (field) {\r
+ case IP_ADDRESS:\r
+ return isSetIpAddress();\r
+ case AS_NUMBER:\r
+ return isSetAsNumber();\r
+ }\r
+ throw new IllegalStateException();\r
+ }\r
+\r
+ @Override\r
+ public boolean equals(Object that) {\r
+ if (that == null)\r
+ return false;\r
+ if (that instanceof peerDown_args)\r
+ return this.equals((peerDown_args)that);\r
+ return false;\r
+ }\r
+\r
+ public boolean equals(peerDown_args that) {\r
+ if (that == null)\r
+ return false;\r
+\r
+ boolean this_present_ipAddress = true && this.isSetIpAddress();\r
+ boolean that_present_ipAddress = true && that.isSetIpAddress();\r
+ if (this_present_ipAddress || that_present_ipAddress) {\r
+ if (!(this_present_ipAddress && that_present_ipAddress))\r
+ return false;\r
+ if (!this.ipAddress.equals(that.ipAddress))\r
+ return false;\r
+ }\r
+\r
+ boolean this_present_asNumber = true;\r
+ boolean that_present_asNumber = true;\r
+ if (this_present_asNumber || that_present_asNumber) {\r
+ if (!(this_present_asNumber && that_present_asNumber))\r
+ return false;\r
+ if (this.asNumber != that.asNumber)\r
+ return false;\r
+ }\r
+\r
+ return true;\r
+ }\r
+\r
+ @Override\r
+ public int hashCode() {\r
+ List<Object> list = new ArrayList<Object>();\r
+\r
+ boolean present_ipAddress = true && (isSetIpAddress());\r
+ list.add(present_ipAddress);\r
+ if (present_ipAddress)\r
+ list.add(ipAddress);\r
+\r
+ boolean present_asNumber = true;\r
+ list.add(present_asNumber);\r
+ if (present_asNumber)\r
+ list.add(asNumber);\r
+\r
+ return list.hashCode();\r
+ }\r
+\r
+ @Override\r
+ public int compareTo(peerDown_args other) {\r
+ if (!getClass().equals(other.getClass())) {\r
+ return getClass().getName().compareTo(other.getClass().getName());\r
+ }\r
+\r
+ int lastComparison = 0;\r
+\r
+ lastComparison = Boolean.valueOf(isSetIpAddress()).compareTo(other.isSetIpAddress());\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ if (isSetIpAddress()) {\r
+ lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.ipAddress, other.ipAddress);\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ }\r
+ lastComparison = Boolean.valueOf(isSetAsNumber()).compareTo(other.isSetAsNumber());\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ if (isSetAsNumber()) {\r
+ lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.asNumber, other.asNumber);\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ }\r
+ return 0;\r
+ }\r
+\r
+ public _Fields fieldForId(int fieldId) {\r
+ return _Fields.findByThriftId(fieldId);\r
+ }\r
+\r
+ public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {\r
+ schemes.get(iprot.getScheme()).getScheme().read(iprot, this);\r
+ }\r
+\r
+ public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {\r
+ schemes.get(oprot.getScheme()).getScheme().write(oprot, this);\r
+ }\r
+\r
+ @Override\r
+ public String toString() {\r
+ StringBuilder sb = new StringBuilder("peerDown_args(");\r
+ boolean first = true;\r
+\r
+ sb.append("ipAddress:");\r
+ if (this.ipAddress == null) {\r
+ sb.append("null");\r
+ } else {\r
+ sb.append(this.ipAddress);\r
+ }\r
+ first = false;\r
+ if (!first) sb.append(", ");\r
+ sb.append("asNumber:");\r
+ sb.append(this.asNumber);\r
+ first = false;\r
+ sb.append(")");\r
+ return sb.toString();\r
+ }\r
+\r
+ public void validate() throws org.apache.thrift.TException {\r
+ // check for required fields\r
+ // check for sub-struct validity\r
+ }\r
+\r
+ private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {\r
+ try {\r
+ write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));\r
+ } catch (org.apache.thrift.TException te) {\r
+ throw new java.io.IOException(te);\r
+ }\r
+ }\r
+\r
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {\r
+ try {\r
+ // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.\r
+ __isset_bitfield = 0;\r
+ read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));\r
+ } catch (org.apache.thrift.TException te) {\r
+ throw new java.io.IOException(te);\r
+ }\r
+ }\r
+\r
+ private static class peerDown_argsStandardSchemeFactory implements SchemeFactory {\r
+ public peerDown_argsStandardScheme getScheme() {\r
+ return new peerDown_argsStandardScheme();\r
+ }\r
+ }\r
+\r
+ private static class peerDown_argsStandardScheme extends StandardScheme<peerDown_args> {\r
+\r
+ public void read(org.apache.thrift.protocol.TProtocol iprot, peerDown_args struct) throws org.apache.thrift.TException {\r
+ org.apache.thrift.protocol.TField schemeField;\r
+ iprot.readStructBegin();\r
+ while (true)\r
+ {\r
+ schemeField = iprot.readFieldBegin();\r
+ if (schemeField.type == org.apache.thrift.protocol.TType.STOP) {\r
+ break;\r
+ }\r
+ switch (schemeField.id) {\r
+ case 1: // IP_ADDRESS\r
+ if (schemeField.type == org.apache.thrift.protocol.TType.STRING) {\r
+ struct.ipAddress = iprot.readString();\r
+ struct.setIpAddressIsSet(true);\r
+ } else {\r
+ org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);\r
+ }\r
+ break;\r
+ case 2: // AS_NUMBER\r
+ if (schemeField.type == org.apache.thrift.protocol.TType.I64) {\r
+ struct.asNumber = iprot.readI64();\r
+ struct.setAsNumberIsSet(true);\r
+ } else {\r
+ org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);\r
+ }\r
+ break;\r
+ default:\r
+ org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);\r
+ }\r
+ iprot.readFieldEnd();\r
+ }\r
+ iprot.readStructEnd();\r
+\r
+ // check for required fields of primitive type, which can't be checked in the validate method\r
+ struct.validate();\r
+ }\r
+\r
+ public void write(org.apache.thrift.protocol.TProtocol oprot, peerDown_args struct) throws org.apache.thrift.TException {\r
+ struct.validate();\r
+\r
+ oprot.writeStructBegin(STRUCT_DESC);\r
+ if (struct.ipAddress != null) {\r
+ oprot.writeFieldBegin(IP_ADDRESS_FIELD_DESC);\r
+ oprot.writeString(struct.ipAddress);\r
+ oprot.writeFieldEnd();\r
+ }\r
+ oprot.writeFieldBegin(AS_NUMBER_FIELD_DESC);\r
+ oprot.writeI64(struct.asNumber);\r
+ oprot.writeFieldEnd();\r
+ oprot.writeFieldStop();\r
+ oprot.writeStructEnd();\r
+ }\r
+\r
+ }\r
+\r
+ private static class peerDown_argsTupleSchemeFactory implements SchemeFactory {\r
+ public peerDown_argsTupleScheme getScheme() {\r
+ return new peerDown_argsTupleScheme();\r
+ }\r
+ }\r
+\r
+ private static class peerDown_argsTupleScheme extends TupleScheme<peerDown_args> {\r
+\r
+ @Override\r
+ public void write(org.apache.thrift.protocol.TProtocol prot, peerDown_args struct) throws org.apache.thrift.TException {\r
+ TTupleProtocol oprot = (TTupleProtocol) prot;\r
+ BitSet optionals = new BitSet();\r
+ if (struct.isSetIpAddress()) {\r
+ optionals.set(0);\r
+ }\r
+ if (struct.isSetAsNumber()) {\r
+ optionals.set(1);\r
+ }\r
+ oprot.writeBitSet(optionals, 2);\r
+ if (struct.isSetIpAddress()) {\r
+ oprot.writeString(struct.ipAddress);\r
+ }\r
+ if (struct.isSetAsNumber()) {\r
+ oprot.writeI64(struct.asNumber);\r
+ }\r
+ }\r
+\r
+ @Override\r
+ public void read(org.apache.thrift.protocol.TProtocol prot, peerDown_args struct) throws org.apache.thrift.TException {\r
+ TTupleProtocol iprot = (TTupleProtocol) prot;\r
+ BitSet incoming = iprot.readBitSet(2);\r
+ if (incoming.get(0)) {\r
+ struct.ipAddress = iprot.readString();\r
+ struct.setIpAddressIsSet(true);\r
+ }\r
+ if (incoming.get(1)) {\r
+ struct.asNumber = iprot.readI64();\r
+ struct.setAsNumberIsSet(true);\r
+ }\r
+ }\r
+ }\r
+\r
+ }\r
+\r
+ public static class peerUp_args implements org.apache.thrift.TBase<peerUp_args, peerUp_args._Fields>, java.io.Serializable, Cloneable, Comparable<peerUp_args> {\r
+ private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("peerUp_args");\r
+\r
+ private static final org.apache.thrift.protocol.TField IP_ADDRESS_FIELD_DESC = new org.apache.thrift.protocol.TField("ipAddress", org.apache.thrift.protocol.TType.STRING, (short)1);\r
+ private static final org.apache.thrift.protocol.TField AS_NUMBER_FIELD_DESC = new org.apache.thrift.protocol.TField("asNumber", org.apache.thrift.protocol.TType.I64, (short)2);\r
+\r
+ private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();\r
+ static {\r
+ schemes.put(StandardScheme.class, new peerUp_argsStandardSchemeFactory());\r
+ schemes.put(TupleScheme.class, new peerUp_argsTupleSchemeFactory());\r
+ }\r
+\r
+ public String ipAddress; // required\r
+ public long asNumber; // required\r
+\r
+ /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */\r
+ public enum _Fields implements org.apache.thrift.TFieldIdEnum {\r
+ IP_ADDRESS((short)1, "ipAddress"),\r
+ AS_NUMBER((short)2, "asNumber");\r
+\r
+ private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();\r
+\r
+ static {\r
+ for (_Fields field : EnumSet.allOf(_Fields.class)) {\r
+ byName.put(field.getFieldName(), field);\r
+ }\r
+ }\r
+\r
+ /**\r
+ * Find the _Fields constant that matches fieldId, or null if its not found.\r
+ */\r
+ public static _Fields findByThriftId(int fieldId) {\r
+ switch(fieldId) {\r
+ case 1: // IP_ADDRESS\r
+ return IP_ADDRESS;\r
+ case 2: // AS_NUMBER\r
+ return AS_NUMBER;\r
+ default:\r
+ return null;\r
+ }\r
+ }\r
+\r
+ /**\r
+ * Find the _Fields constant that matches fieldId, throwing an exception\r
+ * if it is not found.\r
+ */\r
+ public static _Fields findByThriftIdOrThrow(int fieldId) {\r
+ _Fields fields = findByThriftId(fieldId);\r
+ if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");\r
+ return fields;\r
+ }\r
+\r
+ /**\r
+ * Find the _Fields constant that matches name, or null if its not found.\r
+ */\r
+ public static _Fields findByName(String name) {\r
+ return byName.get(name);\r
+ }\r
+\r
+ private final short _thriftId;\r
+ private final String _fieldName;\r
+\r
+ _Fields(short thriftId, String fieldName) {\r
+ _thriftId = thriftId;\r
+ _fieldName = fieldName;\r
+ }\r
+\r
+ public short getThriftFieldId() {\r
+ return _thriftId;\r
+ }\r
+\r
+ public String getFieldName() {\r
+ return _fieldName;\r
+ }\r
+ }\r
+\r
+ // isset id assignments\r
+ private static final int __ASNUMBER_ISSET_ID = 0;\r
+ private byte __isset_bitfield = 0;\r
+ public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;\r
+ static {\r
+ Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);\r
+ tmpMap.put(_Fields.IP_ADDRESS, new org.apache.thrift.meta_data.FieldMetaData("ipAddress", org.apache.thrift.TFieldRequirementType.DEFAULT,\r
+ new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));\r
+ tmpMap.put(_Fields.AS_NUMBER, new org.apache.thrift.meta_data.FieldMetaData("asNumber", org.apache.thrift.TFieldRequirementType.DEFAULT,\r
+ new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));\r
+ metaDataMap = Collections.unmodifiableMap(tmpMap);\r
+ org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(peerUp_args.class, metaDataMap);\r
+ }\r
+\r
+ public peerUp_args() {\r
+ }\r
+\r
+ public peerUp_args(\r
+ String ipAddress,\r
+ long asNumber)\r
+ {\r
+ this();\r
+ this.ipAddress = ipAddress;\r
+ this.asNumber = asNumber;\r
+ setAsNumberIsSet(true);\r
+ }\r
+\r
+ /**\r
+ * Performs a deep copy on <i>other</i>.\r
+ */\r
+ public peerUp_args(peerUp_args other) {\r
+ __isset_bitfield = other.__isset_bitfield;\r
+ if (other.isSetIpAddress()) {\r
+ this.ipAddress = other.ipAddress;\r
+ }\r
+ this.asNumber = other.asNumber;\r
+ }\r
+\r
+ public peerUp_args deepCopy() {\r
+ return new peerUp_args(this);\r
+ }\r
+\r
+ @Override\r
+ public void clear() {\r
+ this.ipAddress = null;\r
+ setAsNumberIsSet(false);\r
+ this.asNumber = 0;\r
+ }\r
+\r
+ public String getIpAddress() {\r
+ return this.ipAddress;\r
+ }\r
+\r
+ public peerUp_args setIpAddress(String ipAddress) {\r
+ this.ipAddress = ipAddress;\r
+ return this;\r
+ }\r
+\r
+ public void unsetIpAddress() {\r
+ this.ipAddress = null;\r
+ }\r
+\r
+ /** Returns true if field ipAddress is set (has been assigned a value) and false otherwise */\r
+ public boolean isSetIpAddress() {\r
+ return this.ipAddress != null;\r
+ }\r
+\r
+ public void setIpAddressIsSet(boolean value) {\r
+ if (!value) {\r
+ this.ipAddress = null;\r
+ }\r
+ }\r
+\r
+ public long getAsNumber() {\r
+ return this.asNumber;\r
+ }\r
+\r
+ public peerUp_args setAsNumber(long asNumber) {\r
+ this.asNumber = asNumber;\r
+ setAsNumberIsSet(true);\r
+ return this;\r
+ }\r
+\r
+ public void unsetAsNumber() {\r
+ __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __ASNUMBER_ISSET_ID);\r
+ }\r
+\r
+ /** Returns true if field asNumber is set (has been assigned a value) and false otherwise */\r
+ public boolean isSetAsNumber() {\r
+ return EncodingUtils.testBit(__isset_bitfield, __ASNUMBER_ISSET_ID);\r
+ }\r
+\r
+ public void setAsNumberIsSet(boolean value) {\r
+ __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __ASNUMBER_ISSET_ID, value);\r
+ }\r
+\r
+ public void setFieldValue(_Fields field, Object value) {\r
+ switch (field) {\r
+ case IP_ADDRESS:\r
+ if (value == null) {\r
+ unsetIpAddress();\r
+ } else {\r
+ setIpAddress((String)value);\r
+ }\r
+ break;\r
+\r
+ case AS_NUMBER:\r
+ if (value == null) {\r
+ unsetAsNumber();\r
+ } else {\r
+ setAsNumber((Long)value);\r
+ }\r
+ break;\r
+\r
+ }\r
+ }\r
+\r
+ public Object getFieldValue(_Fields field) {\r
+ switch (field) {\r
+ case IP_ADDRESS:\r
+ return getIpAddress();\r
+\r
+ case AS_NUMBER:\r
+ return getAsNumber();\r
+\r
+ }\r
+ throw new IllegalStateException();\r
+ }\r
+\r
+ /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */\r
+ public boolean isSet(_Fields field) {\r
+ if (field == null) {\r
+ throw new IllegalArgumentException();\r
+ }\r
+\r
+ switch (field) {\r
+ case IP_ADDRESS:\r
+ return isSetIpAddress();\r
+ case AS_NUMBER:\r
+ return isSetAsNumber();\r
+ }\r
+ throw new IllegalStateException();\r
+ }\r
+\r
+ @Override\r
+ public boolean equals(Object that) {\r
+ if (that == null)\r
+ return false;\r
+ if (that instanceof peerUp_args)\r
+ return this.equals((peerUp_args)that);\r
+ return false;\r
+ }\r
+\r
+ public boolean equals(peerUp_args that) {\r
+ if (that == null)\r
+ return false;\r
+\r
+ boolean this_present_ipAddress = true && this.isSetIpAddress();\r
+ boolean that_present_ipAddress = true && that.isSetIpAddress();\r
+ if (this_present_ipAddress || that_present_ipAddress) {\r
+ if (!(this_present_ipAddress && that_present_ipAddress))\r
+ return false;\r
+ if (!this.ipAddress.equals(that.ipAddress))\r
+ return false;\r
+ }\r
+\r
+ boolean this_present_asNumber = true;\r
+ boolean that_present_asNumber = true;\r
+ if (this_present_asNumber || that_present_asNumber) {\r
+ if (!(this_present_asNumber && that_present_asNumber))\r
+ return false;\r
+ if (this.asNumber != that.asNumber)\r
+ return false;\r
+ }\r
+\r
+ return true;\r
+ }\r
+\r
+ @Override\r
+ public int hashCode() {\r
+ List<Object> list = new ArrayList<Object>();\r
+\r
+ boolean present_ipAddress = true && (isSetIpAddress());\r
+ list.add(present_ipAddress);\r
+ if (present_ipAddress)\r
+ list.add(ipAddress);\r
+\r
+ boolean present_asNumber = true;\r
+ list.add(present_asNumber);\r
+ if (present_asNumber)\r
+ list.add(asNumber);\r
+\r
+ return list.hashCode();\r
+ }\r
+\r
+ @Override\r
+ public int compareTo(peerUp_args other) {\r
+ if (!getClass().equals(other.getClass())) {\r
+ return getClass().getName().compareTo(other.getClass().getName());\r
+ }\r
+\r
+ int lastComparison = 0;\r
+\r
+ lastComparison = Boolean.valueOf(isSetIpAddress()).compareTo(other.isSetIpAddress());\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ if (isSetIpAddress()) {\r
+ lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.ipAddress, other.ipAddress);\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ }\r
+ lastComparison = Boolean.valueOf(isSetAsNumber()).compareTo(other.isSetAsNumber());\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ if (isSetAsNumber()) {\r
+ lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.asNumber, other.asNumber);\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ }\r
+ return 0;\r
+ }\r
+\r
+ public _Fields fieldForId(int fieldId) {\r
+ return _Fields.findByThriftId(fieldId);\r
+ }\r
+\r
+ public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {\r
+ schemes.get(iprot.getScheme()).getScheme().read(iprot, this);\r
+ }\r
+\r
+ public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {\r
+ schemes.get(oprot.getScheme()).getScheme().write(oprot, this);\r
+ }\r
+\r
+ @Override\r
+ public String toString() {\r
+ StringBuilder sb = new StringBuilder("peerUp_args(");\r
+ boolean first = true;\r
+\r
+ sb.append("ipAddress:");\r
+ if (this.ipAddress == null) {\r
+ sb.append("null");\r
+ } else {\r
+ sb.append(this.ipAddress);\r
+ }\r
+ first = false;\r
+ if (!first) sb.append(", ");\r
+ sb.append("asNumber:");\r
+ sb.append(this.asNumber);\r
+ first = false;\r
+ sb.append(")");\r
+ return sb.toString();\r
+ }\r
+\r
+ public void validate() throws org.apache.thrift.TException {\r
+ // check for required fields\r
+ // check for sub-struct validity\r
+ }\r
+\r
+ private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {\r
+ try {\r
+ write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));\r
+ } catch (org.apache.thrift.TException te) {\r
+ throw new java.io.IOException(te);\r
+ }\r
+ }\r
+\r
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {\r
+ try {\r
+ // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.\r
+ __isset_bitfield = 0;\r
+ read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));\r
+ } catch (org.apache.thrift.TException te) {\r
+ throw new java.io.IOException(te);\r
+ }\r
+ }\r
+\r
+ private static class peerUp_argsStandardSchemeFactory implements SchemeFactory {\r
+ public peerUp_argsStandardScheme getScheme() {\r
+ return new peerUp_argsStandardScheme();\r
+ }\r
+ }\r
+\r
+ private static class peerUp_argsStandardScheme extends StandardScheme<peerUp_args> {\r
+\r
+ public void read(org.apache.thrift.protocol.TProtocol iprot, peerUp_args struct) throws org.apache.thrift.TException {\r
+ org.apache.thrift.protocol.TField schemeField;\r
+ iprot.readStructBegin();\r
+ while (true)\r
+ {\r
+ schemeField = iprot.readFieldBegin();\r
+ if (schemeField.type == org.apache.thrift.protocol.TType.STOP) {\r
+ break;\r
+ }\r
+ switch (schemeField.id) {\r
+ case 1: // IP_ADDRESS\r
+ if (schemeField.type == org.apache.thrift.protocol.TType.STRING) {\r
+ struct.ipAddress = iprot.readString();\r
+ struct.setIpAddressIsSet(true);\r
+ } else {\r
+ org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);\r
+ }\r
+ break;\r
+ case 2: // AS_NUMBER\r
+ if (schemeField.type == org.apache.thrift.protocol.TType.I64) {\r
+ struct.asNumber = iprot.readI64();\r
+ struct.setAsNumberIsSet(true);\r
+ } else {\r
+ org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);\r
+ }\r
+ break;\r
+ default:\r
+ org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);\r
+ }\r
+ iprot.readFieldEnd();\r
+ }\r
+ iprot.readStructEnd();\r
+\r
+ // check for required fields of primitive type, which can't be checked in the validate method\r
+ struct.validate();\r
+ }\r
+\r
+ public void write(org.apache.thrift.protocol.TProtocol oprot, peerUp_args struct) throws org.apache.thrift.TException {\r
+ struct.validate();\r
+\r
+ oprot.writeStructBegin(STRUCT_DESC);\r
+ if (struct.ipAddress != null) {\r
+ oprot.writeFieldBegin(IP_ADDRESS_FIELD_DESC);\r
+ oprot.writeString(struct.ipAddress);\r
+ oprot.writeFieldEnd();\r
+ }\r
+ oprot.writeFieldBegin(AS_NUMBER_FIELD_DESC);\r
+ oprot.writeI64(struct.asNumber);\r
+ oprot.writeFieldEnd();\r
+ oprot.writeFieldStop();\r
+ oprot.writeStructEnd();\r
+ }\r
+\r
+ }\r
+\r
+ private static class peerUp_argsTupleSchemeFactory implements SchemeFactory {\r
+ public peerUp_argsTupleScheme getScheme() {\r
+ return new peerUp_argsTupleScheme();\r
+ }\r
+ }\r
+\r
+ private static class peerUp_argsTupleScheme extends TupleScheme<peerUp_args> {\r
+\r
+ @Override\r
+ public void write(org.apache.thrift.protocol.TProtocol prot, peerUp_args struct) throws org.apache.thrift.TException {\r
+ TTupleProtocol oprot = (TTupleProtocol) prot;\r
+ BitSet optionals = new BitSet();\r
+ if (struct.isSetIpAddress()) {\r
+ optionals.set(0);\r
+ }\r
+ if (struct.isSetAsNumber()) {\r
+ optionals.set(1);\r
+ }\r
+ oprot.writeBitSet(optionals, 2);\r
+ if (struct.isSetIpAddress()) {\r
+ oprot.writeString(struct.ipAddress);\r
+ }\r
+ if (struct.isSetAsNumber()) {\r
+ oprot.writeI64(struct.asNumber);\r
+ }\r
+ }\r
+\r
+ @Override\r
+ public void read(org.apache.thrift.protocol.TProtocol prot, peerUp_args struct) throws org.apache.thrift.TException {\r
+ TTupleProtocol iprot = (TTupleProtocol) prot;\r
+ BitSet incoming = iprot.readBitSet(2);\r
+ if (incoming.get(0)) {\r
+ struct.ipAddress = iprot.readString();\r
+ struct.setIpAddressIsSet(true);\r
+ }\r
+ if (incoming.get(1)) {\r
+ struct.asNumber = iprot.readI64();\r
+ struct.setAsNumberIsSet(true);\r
+ }\r
+ }\r
+ }\r
+\r
+ }\r
+\r
+}\r
-/**
- * Autogenerated by Thrift Compiler (0.9.3)
- *
- * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
- * @generated
- */
- package org.opendaylight.netvirt.bgpmanager.thrift.gen;
-import org.apache.thrift.scheme.IScheme;
-import org.apache.thrift.scheme.SchemeFactory;
-import org.apache.thrift.scheme.StandardScheme;
-
-import org.apache.thrift.scheme.TupleScheme;
-import org.apache.thrift.protocol.TTupleProtocol;
-import org.apache.thrift.protocol.TProtocolException;
-import org.apache.thrift.EncodingUtils;
-import org.apache.thrift.TException;
-import org.apache.thrift.async.AsyncMethodCallback;
-import org.apache.thrift.server.AbstractNonblockingServer.*;
-import java.util.List;
-import java.util.ArrayList;
-import java.util.Map;
-import java.util.HashMap;
-import java.util.EnumMap;
-import java.util.Set;
-import java.util.HashSet;
-import java.util.EnumSet;
-import java.util.Collections;
-import java.util.BitSet;
-import java.nio.ByteBuffer;
-import java.util.Arrays;
-import javax.annotation.Generated;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"})
-@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)", date = "2017-09-13")
-public class Routes implements org.apache.thrift.TBase<Routes, Routes._Fields>, java.io.Serializable, Cloneable, Comparable<Routes> {
- private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("Routes");
-
- private static final org.apache.thrift.protocol.TField ERRCODE_FIELD_DESC = new org.apache.thrift.protocol.TField("errcode", org.apache.thrift.protocol.TType.I32, (short)1);
- private static final org.apache.thrift.protocol.TField UPDATES_FIELD_DESC = new org.apache.thrift.protocol.TField("updates", org.apache.thrift.protocol.TType.LIST, (short)2);
- private static final org.apache.thrift.protocol.TField MORE_FIELD_DESC = new org.apache.thrift.protocol.TField("more", org.apache.thrift.protocol.TType.I32, (short)4);
-
- private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
- static {
- schemes.put(StandardScheme.class, new RoutesStandardSchemeFactory());
- schemes.put(TupleScheme.class, new RoutesTupleSchemeFactory());
- }
-
- public int errcode; // required
- public List<Update> updates; // optional
- public int more; // optional
-
- /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
- public enum _Fields implements org.apache.thrift.TFieldIdEnum {
- ERRCODE((short)1, "errcode"),
- UPDATES((short)2, "updates"),
- MORE((short)4, "more");
-
- private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
-
- static {
- for (_Fields field : EnumSet.allOf(_Fields.class)) {
- byName.put(field.getFieldName(), field);
- }
- }
-
- /**
- * Find the _Fields constant that matches fieldId, or null if its not found.
- */
- public static _Fields findByThriftId(int fieldId) {
- switch(fieldId) {
- case 1: // ERRCODE
- return ERRCODE;
- case 2: // UPDATES
- return UPDATES;
- case 4: // MORE
- return MORE;
- default:
- return null;
- }
- }
-
- /**
- * Find the _Fields constant that matches fieldId, throwing an exception
- * if it is not found.
- */
- public static _Fields findByThriftIdOrThrow(int fieldId) {
- _Fields fields = findByThriftId(fieldId);
- if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
- return fields;
- }
-
- /**
- * Find the _Fields constant that matches name, or null if its not found.
- */
- public static _Fields findByName(String name) {
- return byName.get(name);
- }
-
- private final short _thriftId;
- private final String _fieldName;
-
- _Fields(short thriftId, String fieldName) {
- _thriftId = thriftId;
- _fieldName = fieldName;
- }
-
- public short getThriftFieldId() {
- return _thriftId;
- }
-
- public String getFieldName() {
- return _fieldName;
- }
- }
-
- // isset id assignments
- private static final int __ERRCODE_ISSET_ID = 0;
- private static final int __MORE_ISSET_ID = 1;
- private byte __isset_bitfield = 0;
- private static final _Fields optionals[] = {_Fields.UPDATES,_Fields.MORE};
- public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
- static {
- Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
- tmpMap.put(_Fields.ERRCODE, new org.apache.thrift.meta_data.FieldMetaData("errcode", org.apache.thrift.TFieldRequirementType.DEFAULT,
- new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I32)));
- tmpMap.put(_Fields.UPDATES, new org.apache.thrift.meta_data.FieldMetaData("updates", org.apache.thrift.TFieldRequirementType.OPTIONAL,
- new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST,
- new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, Update.class))));
- tmpMap.put(_Fields.MORE, new org.apache.thrift.meta_data.FieldMetaData("more", org.apache.thrift.TFieldRequirementType.OPTIONAL,
- new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I32)));
- metaDataMap = Collections.unmodifiableMap(tmpMap);
- org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(Routes.class, metaDataMap);
- }
-
- public Routes() {
- }
-
- public Routes(
- int errcode)
- {
- this();
- this.errcode = errcode;
- setErrcodeIsSet(true);
- }
-
- /**
- * Performs a deep copy on <i>other</i>.
- */
- public Routes(Routes other) {
- __isset_bitfield = other.__isset_bitfield;
- this.errcode = other.errcode;
- if (other.isSetUpdates()) {
- List<Update> __this__updates = new ArrayList<Update>(other.updates.size());
- for (Update other_element : other.updates) {
- __this__updates.add(new Update(other_element));
- }
- this.updates = __this__updates;
- }
- this.more = other.more;
- }
-
- public Routes deepCopy() {
- return new Routes(this);
- }
-
- @Override
- public void clear() {
- setErrcodeIsSet(false);
- this.errcode = 0;
- this.updates = null;
- setMoreIsSet(false);
- this.more = 0;
- }
-
- public int getErrcode() {
- return this.errcode;
- }
-
- public Routes setErrcode(int errcode) {
- this.errcode = errcode;
- setErrcodeIsSet(true);
- return this;
- }
-
- public void unsetErrcode() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __ERRCODE_ISSET_ID);
- }
-
- /** Returns true if field errcode is set (has been assigned a value) and false otherwise */
- public boolean isSetErrcode() {
- return EncodingUtils.testBit(__isset_bitfield, __ERRCODE_ISSET_ID);
- }
-
- public void setErrcodeIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __ERRCODE_ISSET_ID, value);
- }
-
- public int getUpdatesSize() {
- return (this.updates == null) ? 0 : this.updates.size();
- }
-
- public java.util.Iterator<Update> getUpdatesIterator() {
- return (this.updates == null) ? null : this.updates.iterator();
- }
-
- public void addToUpdates(Update elem) {
- if (this.updates == null) {
- this.updates = new ArrayList<Update>();
- }
- this.updates.add(elem);
- }
-
- public List<Update> getUpdates() {
- return this.updates;
- }
-
- public Routes setUpdates(List<Update> updates) {
- this.updates = updates;
- return this;
- }
-
- public void unsetUpdates() {
- this.updates = null;
- }
-
- /** Returns true if field updates is set (has been assigned a value) and false otherwise */
- public boolean isSetUpdates() {
- return this.updates != null;
- }
-
- public void setUpdatesIsSet(boolean value) {
- if (!value) {
- this.updates = null;
- }
- }
-
- public int getMore() {
- return this.more;
- }
-
- public Routes setMore(int more) {
- this.more = more;
- setMoreIsSet(true);
- return this;
- }
-
- public void unsetMore() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __MORE_ISSET_ID);
- }
-
- /** Returns true if field more is set (has been assigned a value) and false otherwise */
- public boolean isSetMore() {
- return EncodingUtils.testBit(__isset_bitfield, __MORE_ISSET_ID);
- }
-
- public void setMoreIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __MORE_ISSET_ID, value);
- }
-
- public void setFieldValue(_Fields field, Object value) {
- switch (field) {
- case ERRCODE:
- if (value == null) {
- unsetErrcode();
- } else {
- setErrcode((Integer)value);
- }
- break;
-
- case UPDATES:
- if (value == null) {
- unsetUpdates();
- } else {
- setUpdates((List<Update>)value);
- }
- break;
-
- case MORE:
- if (value == null) {
- unsetMore();
- } else {
- setMore((Integer)value);
- }
- break;
-
- }
- }
-
- public Object getFieldValue(_Fields field) {
- switch (field) {
- case ERRCODE:
- return Integer.valueOf(getErrcode());
-
- case UPDATES:
- return getUpdates();
-
- case MORE:
- return Integer.valueOf(getMore());
-
- }
- throw new IllegalStateException();
- }
-
- /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
- public boolean isSet(_Fields field) {
- if (field == null) {
- throw new IllegalArgumentException();
- }
-
- switch (field) {
- case ERRCODE:
- return isSetErrcode();
- case UPDATES:
- return isSetUpdates();
- case MORE:
- return isSetMore();
- }
- throw new IllegalStateException();
- }
-
- @Override
- public boolean equals(Object that) {
- if (that == null)
- return false;
- if (that instanceof Routes)
- return this.equals((Routes)that);
- return false;
- }
-
- public boolean equals(Routes that) {
- if (that == null)
- return false;
-
- boolean this_present_errcode = true;
- boolean that_present_errcode = true;
- if (this_present_errcode || that_present_errcode) {
- if (!(this_present_errcode && that_present_errcode))
- return false;
- if (this.errcode != that.errcode)
- return false;
- }
-
- boolean this_present_updates = true && this.isSetUpdates();
- boolean that_present_updates = true && that.isSetUpdates();
- if (this_present_updates || that_present_updates) {
- if (!(this_present_updates && that_present_updates))
- return false;
- if (!this.updates.equals(that.updates))
- return false;
- }
-
- boolean this_present_more = true && this.isSetMore();
- boolean that_present_more = true && that.isSetMore();
- if (this_present_more || that_present_more) {
- if (!(this_present_more && that_present_more))
- return false;
- if (this.more != that.more)
- return false;
- }
-
- return true;
- }
-
- @Override
- public int hashCode() {
- List<Object> list = new ArrayList<Object>();
-
- boolean present_errcode = true;
- list.add(present_errcode);
- if (present_errcode)
- list.add(errcode);
- boolean present_updates = true && (isSetUpdates());
- list.add(present_updates);
- if (present_updates)
- list.add(updates);
- boolean present_more = true && (isSetMore());
- list.add(present_more);
- if (present_more)
- list.add(more);
- return list.hashCode();
- }
-
- @Override
- public int compareTo(Routes other) {
- if (!getClass().equals(other.getClass())) {
- return getClass().getName().compareTo(other.getClass().getName());
- }
-
- int lastComparison = 0;
-
- lastComparison = Boolean.valueOf(isSetErrcode()).compareTo(other.isSetErrcode());
- if (lastComparison != 0) {
- return lastComparison;
- }
- if (isSetErrcode()) {
- lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.errcode, other.errcode);
- if (lastComparison != 0) {
- return lastComparison;
- }
- }
- lastComparison = Boolean.valueOf(isSetUpdates()).compareTo(other.isSetUpdates());
- if (lastComparison != 0) {
- return lastComparison;
- }
- if (isSetUpdates()) {
- lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.updates, other.updates);
- if (lastComparison != 0) {
- return lastComparison;
- }
- }
- lastComparison = Boolean.valueOf(isSetMore()).compareTo(other.isSetMore());
- if (lastComparison != 0) {
- return lastComparison;
- }
- if (isSetMore()) {
- lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.more, other.more);
- if (lastComparison != 0) {
- return lastComparison;
- }
- }
- return 0;
- }
-
- public _Fields fieldForId(int fieldId) {
- return _Fields.findByThriftId(fieldId);
- }
-
- public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
- schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
- }
-
- public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
- schemes.get(oprot.getScheme()).getScheme().write(oprot, this);
- }
-
- @Override
- public String toString() {
- StringBuilder sb = new StringBuilder("Routes(");
- boolean first = true;
-
- sb.append("errcode:");
- sb.append(this.errcode);
- first = false;
- if (isSetUpdates()) {
- if (!first) sb.append(", ");
- sb.append("updates:");
- if (this.updates == null) {
- sb.append("null");
- } else {
- sb.append(this.updates);
- }
- first = false;
- }
- if (isSetMore()) {
- if (!first) sb.append(", ");
- sb.append("more:");
- sb.append(this.more);
- first = false;
- }
- sb.append(")");
- return sb.toString();
- }
-
- public void validate() throws org.apache.thrift.TException {
- // check for required fields
- // check for sub-struct validity
- }
-
- private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
- try {
- write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
- } catch (org.apache.thrift.TException te) {
- throw new java.io.IOException(te);
- }
- }
-
- private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
- try {
- // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
- __isset_bitfield = 0;
- read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
- } catch (org.apache.thrift.TException te) {
- throw new java.io.IOException(te);
- }
- }
-
- private static class RoutesStandardSchemeFactory implements SchemeFactory {
- public RoutesStandardScheme getScheme() {
- return new RoutesStandardScheme();
- }
- }
-
- private static class RoutesStandardScheme extends StandardScheme<Routes> {
-
- public void read(org.apache.thrift.protocol.TProtocol iprot, Routes struct) throws org.apache.thrift.TException {
- org.apache.thrift.protocol.TField schemeField;
- iprot.readStructBegin();
- while (true)
- {
- schemeField = iprot.readFieldBegin();
- if (schemeField.type == org.apache.thrift.protocol.TType.STOP) {
- break;
- }
- switch (schemeField.id) {
- case 1: // ERRCODE
- if (schemeField.type == org.apache.thrift.protocol.TType.I32) {
- struct.errcode = iprot.readI32();
- struct.setErrcodeIsSet(true);
- } else {
- org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
- }
- break;
- case 2: // UPDATES
- if (schemeField.type == org.apache.thrift.protocol.TType.LIST) {
- {
- org.apache.thrift.protocol.TList _list0 = iprot.readListBegin();
- struct.updates = new ArrayList<Update>(_list0.size);
- for (int _i1 = 0; _i1 < _list0.size; ++_i1)
- {
- Update _elem2;
- _elem2 = new Update();
- _elem2.read(iprot);
- struct.updates.add(_elem2);
- }
- iprot.readListEnd();
- }
- struct.setUpdatesIsSet(true);
- } else {
- org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
- }
- break;
- case 4: // MORE
- if (schemeField.type == org.apache.thrift.protocol.TType.I32) {
- struct.more = iprot.readI32();
- struct.setMoreIsSet(true);
- } else {
- org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
- }
- break;
- default:
- org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
- }
- iprot.readFieldEnd();
- }
- iprot.readStructEnd();
-
- // check for required fields of primitive type, which can't be checked in the validate method
- struct.validate();
- }
-
- public void write(org.apache.thrift.protocol.TProtocol oprot, Routes struct) throws org.apache.thrift.TException {
- struct.validate();
-
- oprot.writeStructBegin(STRUCT_DESC);
- oprot.writeFieldBegin(ERRCODE_FIELD_DESC);
- oprot.writeI32(struct.errcode);
- oprot.writeFieldEnd();
- if (struct.updates != null) {
- if (struct.isSetUpdates()) {
- oprot.writeFieldBegin(UPDATES_FIELD_DESC);
- {
- oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, struct.updates.size()));
- for (Update _iter3 : struct.updates)
- {
- _iter3.write(oprot);
- }
- oprot.writeListEnd();
- }
- oprot.writeFieldEnd();
- }
- }
- if (struct.isSetMore()) {
- oprot.writeFieldBegin(MORE_FIELD_DESC);
- oprot.writeI32(struct.more);
- oprot.writeFieldEnd();
- }
- oprot.writeFieldStop();
- oprot.writeStructEnd();
- }
-
- }
-
- private static class RoutesTupleSchemeFactory implements SchemeFactory {
- public RoutesTupleScheme getScheme() {
- return new RoutesTupleScheme();
- }
- }
-
- private static class RoutesTupleScheme extends TupleScheme<Routes> {
-
- @Override
- public void write(org.apache.thrift.protocol.TProtocol prot, Routes struct) throws org.apache.thrift.TException {
- TTupleProtocol oprot = (TTupleProtocol) prot;
- BitSet optionals = new BitSet();
- if (struct.isSetErrcode()) {
- optionals.set(0);
- }
- if (struct.isSetUpdates()) {
- optionals.set(1);
- }
- if (struct.isSetMore()) {
- optionals.set(2);
- }
- oprot.writeBitSet(optionals, 3);
- if (struct.isSetErrcode()) {
- oprot.writeI32(struct.errcode);
- }
- if (struct.isSetUpdates()) {
- {
- oprot.writeI32(struct.updates.size());
- for (Update _iter4 : struct.updates)
- {
- _iter4.write(oprot);
- }
- }
- }
- if (struct.isSetMore()) {
- oprot.writeI32(struct.more);
- }
- }
-
- @Override
- public void read(org.apache.thrift.protocol.TProtocol prot, Routes struct) throws org.apache.thrift.TException {
- TTupleProtocol iprot = (TTupleProtocol) prot;
- BitSet incoming = iprot.readBitSet(3);
- if (incoming.get(0)) {
- struct.errcode = iprot.readI32();
- struct.setErrcodeIsSet(true);
- }
- if (incoming.get(1)) {
- {
- org.apache.thrift.protocol.TList _list5 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32());
- struct.updates = new ArrayList<Update>(_list5.size);
- for (int _i6 = 0; _i6 < _list5.size; ++_i6)
- {
- Update _elem7;
- _elem7 = new Update();
- _elem7.read(iprot);
- struct.updates.add(_elem7);
- }
- }
- struct.setUpdatesIsSet(true);
- }
- if (incoming.get(2)) {
- struct.more = iprot.readI32();
- struct.setMoreIsSet(true);
- }
- }
- }
-
-}
-
+/**\r
+ * Autogenerated by Thrift Compiler (0.9.3)\r
+ *\r
+ * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING\r
+ * @generated\r
+ */\r
+\r
+package org.opendaylight.netvirt.bgpmanager.thrift.gen;\r
+\r
+import org.apache.thrift.scheme.IScheme;\r
+import org.apache.thrift.scheme.SchemeFactory;\r
+import org.apache.thrift.scheme.StandardScheme;\r
+\r
+import org.apache.thrift.scheme.TupleScheme;\r
+import org.apache.thrift.protocol.TTupleProtocol;\r
+import org.apache.thrift.protocol.TProtocolException;\r
+import org.apache.thrift.EncodingUtils;\r
+import org.apache.thrift.TException;\r
+import org.apache.thrift.async.AsyncMethodCallback;\r
+import org.apache.thrift.server.AbstractNonblockingServer.*;\r
+import java.util.List;\r
+import java.util.ArrayList;\r
+import java.util.Map;\r
+import java.util.HashMap;\r
+import java.util.EnumMap;\r
+import java.util.Set;\r
+import java.util.HashSet;\r
+import java.util.EnumSet;\r
+import java.util.Collections;\r
+import java.util.BitSet;\r
+import java.nio.ByteBuffer;\r
+import java.util.Arrays;\r
+import javax.annotation.Generated;\r
+import org.slf4j.Logger;\r
+import org.slf4j.LoggerFactory;\r
+\r
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"})\r
+@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)", date = "2018-04-09")\r
+public class Routes implements org.apache.thrift.TBase<Routes, Routes._Fields>, java.io.Serializable, Cloneable, Comparable<Routes> {\r
+ private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("Routes");\r
+\r
+ private static final org.apache.thrift.protocol.TField ERRCODE_FIELD_DESC = new org.apache.thrift.protocol.TField("errcode", org.apache.thrift.protocol.TType.I32, (short)1);\r
+ private static final org.apache.thrift.protocol.TField UPDATES_FIELD_DESC = new org.apache.thrift.protocol.TField("updates", org.apache.thrift.protocol.TType.LIST, (short)2);\r
+ private static final org.apache.thrift.protocol.TField MORE_FIELD_DESC = new org.apache.thrift.protocol.TField("more", org.apache.thrift.protocol.TType.I32, (short)4);\r
+\r
+ private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();\r
+ static {\r
+ schemes.put(StandardScheme.class, new RoutesStandardSchemeFactory());\r
+ schemes.put(TupleScheme.class, new RoutesTupleSchemeFactory());\r
+ }\r
+\r
+ public int errcode; // required\r
+ public List<Update> updates; // optional\r
+ public int more; // optional\r
+\r
+ /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */\r
+ public enum _Fields implements org.apache.thrift.TFieldIdEnum {\r
+ ERRCODE((short)1, "errcode"),\r
+ UPDATES((short)2, "updates"),\r
+ MORE((short)4, "more");\r
+\r
+ private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();\r
+\r
+ static {\r
+ for (_Fields field : EnumSet.allOf(_Fields.class)) {\r
+ byName.put(field.getFieldName(), field);\r
+ }\r
+ }\r
+\r
+ /**\r
+ * Find the _Fields constant that matches fieldId, or null if its not found.\r
+ */\r
+ public static _Fields findByThriftId(int fieldId) {\r
+ switch(fieldId) {\r
+ case 1: // ERRCODE\r
+ return ERRCODE;\r
+ case 2: // UPDATES\r
+ return UPDATES;\r
+ case 4: // MORE\r
+ return MORE;\r
+ default:\r
+ return null;\r
+ }\r
+ }\r
+\r
+ /**\r
+ * Find the _Fields constant that matches fieldId, throwing an exception\r
+ * if it is not found.\r
+ */\r
+ public static _Fields findByThriftIdOrThrow(int fieldId) {\r
+ _Fields fields = findByThriftId(fieldId);\r
+ if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");\r
+ return fields;\r
+ }\r
+\r
+ /**\r
+ * Find the _Fields constant that matches name, or null if its not found.\r
+ */\r
+ public static _Fields findByName(String name) {\r
+ return byName.get(name);\r
+ }\r
+\r
+ private final short _thriftId;\r
+ private final String _fieldName;\r
+\r
+ _Fields(short thriftId, String fieldName) {\r
+ _thriftId = thriftId;\r
+ _fieldName = fieldName;\r
+ }\r
+\r
+ public short getThriftFieldId() {\r
+ return _thriftId;\r
+ }\r
+\r
+ public String getFieldName() {\r
+ return _fieldName;\r
+ }\r
+ }\r
+\r
+ // isset id assignments\r
+ private static final int __ERRCODE_ISSET_ID = 0;\r
+ private static final int __MORE_ISSET_ID = 1;\r
+ private byte __isset_bitfield = 0;\r
+ private static final _Fields optionals[] = {_Fields.UPDATES,_Fields.MORE};\r
+ public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;\r
+ static {\r
+ Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);\r
+ tmpMap.put(_Fields.ERRCODE, new org.apache.thrift.meta_data.FieldMetaData("errcode", org.apache.thrift.TFieldRequirementType.DEFAULT,\r
+ new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I32)));\r
+ tmpMap.put(_Fields.UPDATES, new org.apache.thrift.meta_data.FieldMetaData("updates", org.apache.thrift.TFieldRequirementType.OPTIONAL,\r
+ new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST,\r
+ new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, Update.class))));\r
+ tmpMap.put(_Fields.MORE, new org.apache.thrift.meta_data.FieldMetaData("more", org.apache.thrift.TFieldRequirementType.OPTIONAL,\r
+ new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I32)));\r
+ metaDataMap = Collections.unmodifiableMap(tmpMap);\r
+ org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(Routes.class, metaDataMap);\r
+ }\r
+\r
+ public Routes() {\r
+ }\r
+\r
+ public Routes(\r
+ int errcode)\r
+ {\r
+ this();\r
+ this.errcode = errcode;\r
+ setErrcodeIsSet(true);\r
+ }\r
+\r
+ /**\r
+ * Performs a deep copy on <i>other</i>.\r
+ */\r
+ public Routes(Routes other) {\r
+ __isset_bitfield = other.__isset_bitfield;\r
+ this.errcode = other.errcode;\r
+ if (other.isSetUpdates()) {\r
+ List<Update> __this__updates = new ArrayList<Update>(other.updates.size());\r
+ for (Update other_element : other.updates) {\r
+ __this__updates.add(new Update(other_element));\r
+ }\r
+ this.updates = __this__updates;\r
+ }\r
+ this.more = other.more;\r
+ }\r
+\r
+ public Routes deepCopy() {\r
+ return new Routes(this);\r
+ }\r
+\r
+ @Override\r
+ public void clear() {\r
+ setErrcodeIsSet(false);\r
+ this.errcode = 0;\r
+ this.updates = null;\r
+ setMoreIsSet(false);\r
+ this.more = 0;\r
+ }\r
+\r
+ public int getErrcode() {\r
+ return this.errcode;\r
+ }\r
+\r
+ public Routes setErrcode(int errcode) {\r
+ this.errcode = errcode;\r
+ setErrcodeIsSet(true);\r
+ return this;\r
+ }\r
+\r
+ public void unsetErrcode() {\r
+ __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __ERRCODE_ISSET_ID);\r
+ }\r
+\r
+ /** Returns true if field errcode is set (has been assigned a value) and false otherwise */\r
+ public boolean isSetErrcode() {\r
+ return EncodingUtils.testBit(__isset_bitfield, __ERRCODE_ISSET_ID);\r
+ }\r
+\r
+ public void setErrcodeIsSet(boolean value) {\r
+ __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __ERRCODE_ISSET_ID, value);\r
+ }\r
+\r
+ public int getUpdatesSize() {\r
+ return (this.updates == null) ? 0 : this.updates.size();\r
+ }\r
+\r
+ public java.util.Iterator<Update> getUpdatesIterator() {\r
+ return (this.updates == null) ? null : this.updates.iterator();\r
+ }\r
+\r
+ public void addToUpdates(Update elem) {\r
+ if (this.updates == null) {\r
+ this.updates = new ArrayList<Update>();\r
+ }\r
+ this.updates.add(elem);\r
+ }\r
+\r
+ public List<Update> getUpdates() {\r
+ return this.updates;\r
+ }\r
+\r
+ public Routes setUpdates(List<Update> updates) {\r
+ this.updates = updates;\r
+ return this;\r
+ }\r
+\r
+ public void unsetUpdates() {\r
+ this.updates = null;\r
+ }\r
+\r
+ /** Returns true if field updates is set (has been assigned a value) and false otherwise */\r
+ public boolean isSetUpdates() {\r
+ return this.updates != null;\r
+ }\r
+\r
+ public void setUpdatesIsSet(boolean value) {\r
+ if (!value) {\r
+ this.updates = null;\r
+ }\r
+ }\r
+\r
+ public int getMore() {\r
+ return this.more;\r
+ }\r
+\r
+ public Routes setMore(int more) {\r
+ this.more = more;\r
+ setMoreIsSet(true);\r
+ return this;\r
+ }\r
+\r
+ public void unsetMore() {\r
+ __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __MORE_ISSET_ID);\r
+ }\r
+\r
+ /** Returns true if field more is set (has been assigned a value) and false otherwise */\r
+ public boolean isSetMore() {\r
+ return EncodingUtils.testBit(__isset_bitfield, __MORE_ISSET_ID);\r
+ }\r
+\r
+ public void setMoreIsSet(boolean value) {\r
+ __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __MORE_ISSET_ID, value);\r
+ }\r
+\r
+ public void setFieldValue(_Fields field, Object value) {\r
+ switch (field) {\r
+ case ERRCODE:\r
+ if (value == null) {\r
+ unsetErrcode();\r
+ } else {\r
+ setErrcode((Integer)value);\r
+ }\r
+ break;\r
+\r
+ case UPDATES:\r
+ if (value == null) {\r
+ unsetUpdates();\r
+ } else {\r
+ setUpdates((List<Update>)value);\r
+ }\r
+ break;\r
+\r
+ case MORE:\r
+ if (value == null) {\r
+ unsetMore();\r
+ } else {\r
+ setMore((Integer)value);\r
+ }\r
+ break;\r
+\r
+ }\r
+ }\r
+\r
+ public Object getFieldValue(_Fields field) {\r
+ switch (field) {\r
+ case ERRCODE:\r
+ return getErrcode();\r
+\r
+ case UPDATES:\r
+ return getUpdates();\r
+\r
+ case MORE:\r
+ return getMore();\r
+\r
+ }\r
+ throw new IllegalStateException();\r
+ }\r
+\r
+ /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */\r
+ public boolean isSet(_Fields field) {\r
+ if (field == null) {\r
+ throw new IllegalArgumentException();\r
+ }\r
+\r
+ switch (field) {\r
+ case ERRCODE:\r
+ return isSetErrcode();\r
+ case UPDATES:\r
+ return isSetUpdates();\r
+ case MORE:\r
+ return isSetMore();\r
+ }\r
+ throw new IllegalStateException();\r
+ }\r
+\r
+ @Override\r
+ public boolean equals(Object that) {\r
+ if (that == null)\r
+ return false;\r
+ if (that instanceof Routes)\r
+ return this.equals((Routes)that);\r
+ return false;\r
+ }\r
+\r
+ public boolean equals(Routes that) {\r
+ if (that == null)\r
+ return false;\r
+\r
+ boolean this_present_errcode = true;\r
+ boolean that_present_errcode = true;\r
+ if (this_present_errcode || that_present_errcode) {\r
+ if (!(this_present_errcode && that_present_errcode))\r
+ return false;\r
+ if (this.errcode != that.errcode)\r
+ return false;\r
+ }\r
+\r
+ boolean this_present_updates = true && this.isSetUpdates();\r
+ boolean that_present_updates = true && that.isSetUpdates();\r
+ if (this_present_updates || that_present_updates) {\r
+ if (!(this_present_updates && that_present_updates))\r
+ return false;\r
+ if (!this.updates.equals(that.updates))\r
+ return false;\r
+ }\r
+\r
+ boolean this_present_more = true && this.isSetMore();\r
+ boolean that_present_more = true && that.isSetMore();\r
+ if (this_present_more || that_present_more) {\r
+ if (!(this_present_more && that_present_more))\r
+ return false;\r
+ if (this.more != that.more)\r
+ return false;\r
+ }\r
+\r
+ return true;\r
+ }\r
+\r
+ @Override\r
+ public int hashCode() {\r
+ List<Object> list = new ArrayList<Object>();\r
+\r
+ boolean present_errcode = true;\r
+ list.add(present_errcode);\r
+ if (present_errcode)\r
+ list.add(errcode);\r
+\r
+ boolean present_updates = true && (isSetUpdates());\r
+ list.add(present_updates);\r
+ if (present_updates)\r
+ list.add(updates);\r
+\r
+ boolean present_more = true && (isSetMore());\r
+ list.add(present_more);\r
+ if (present_more)\r
+ list.add(more);\r
+\r
+ return list.hashCode();\r
+ }\r
+\r
+ @Override\r
+ public int compareTo(Routes other) {\r
+ if (!getClass().equals(other.getClass())) {\r
+ return getClass().getName().compareTo(other.getClass().getName());\r
+ }\r
+\r
+ int lastComparison = 0;\r
+\r
+ lastComparison = Boolean.valueOf(isSetErrcode()).compareTo(other.isSetErrcode());\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ if (isSetErrcode()) {\r
+ lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.errcode, other.errcode);\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ }\r
+ lastComparison = Boolean.valueOf(isSetUpdates()).compareTo(other.isSetUpdates());\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ if (isSetUpdates()) {\r
+ lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.updates, other.updates);\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ }\r
+ lastComparison = Boolean.valueOf(isSetMore()).compareTo(other.isSetMore());\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ if (isSetMore()) {\r
+ lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.more, other.more);\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ }\r
+ return 0;\r
+ }\r
+\r
+ public _Fields fieldForId(int fieldId) {\r
+ return _Fields.findByThriftId(fieldId);\r
+ }\r
+\r
+ public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {\r
+ schemes.get(iprot.getScheme()).getScheme().read(iprot, this);\r
+ }\r
+\r
+ public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {\r
+ schemes.get(oprot.getScheme()).getScheme().write(oprot, this);\r
+ }\r
+\r
+ @Override\r
+ public String toString() {\r
+ StringBuilder sb = new StringBuilder("Routes(");\r
+ boolean first = true;\r
+\r
+ sb.append("errcode:");\r
+ sb.append(this.errcode);\r
+ first = false;\r
+ if (isSetUpdates()) {\r
+ if (!first) sb.append(", ");\r
+ sb.append("updates:");\r
+ if (this.updates == null) {\r
+ sb.append("null");\r
+ } else {\r
+ sb.append(this.updates);\r
+ }\r
+ first = false;\r
+ }\r
+ if (isSetMore()) {\r
+ if (!first) sb.append(", ");\r
+ sb.append("more:");\r
+ sb.append(this.more);\r
+ first = false;\r
+ }\r
+ sb.append(")");\r
+ return sb.toString();\r
+ }\r
+\r
+ public void validate() throws org.apache.thrift.TException {\r
+ // check for required fields\r
+ // check for sub-struct validity\r
+ }\r
+\r
+ private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {\r
+ try {\r
+ write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));\r
+ } catch (org.apache.thrift.TException te) {\r
+ throw new java.io.IOException(te);\r
+ }\r
+ }\r
+\r
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {\r
+ try {\r
+ // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.\r
+ __isset_bitfield = 0;\r
+ read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));\r
+ } catch (org.apache.thrift.TException te) {\r
+ throw new java.io.IOException(te);\r
+ }\r
+ }\r
+\r
+ private static class RoutesStandardSchemeFactory implements SchemeFactory {\r
+ public RoutesStandardScheme getScheme() {\r
+ return new RoutesStandardScheme();\r
+ }\r
+ }\r
+\r
+ private static class RoutesStandardScheme extends StandardScheme<Routes> {\r
+\r
+ public void read(org.apache.thrift.protocol.TProtocol iprot, Routes struct) throws org.apache.thrift.TException {\r
+ org.apache.thrift.protocol.TField schemeField;\r
+ iprot.readStructBegin();\r
+ while (true)\r
+ {\r
+ schemeField = iprot.readFieldBegin();\r
+ if (schemeField.type == org.apache.thrift.protocol.TType.STOP) {\r
+ break;\r
+ }\r
+ switch (schemeField.id) {\r
+ case 1: // ERRCODE\r
+ if (schemeField.type == org.apache.thrift.protocol.TType.I32) {\r
+ struct.errcode = iprot.readI32();\r
+ struct.setErrcodeIsSet(true);\r
+ } else {\r
+ org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);\r
+ }\r
+ break;\r
+ case 2: // UPDATES\r
+ if (schemeField.type == org.apache.thrift.protocol.TType.LIST) {\r
+ {\r
+ org.apache.thrift.protocol.TList _list0 = iprot.readListBegin();\r
+ struct.updates = new ArrayList<Update>(_list0.size);\r
+ Update _elem1;\r
+ for (int _i2 = 0; _i2 < _list0.size; ++_i2)\r
+ {\r
+ _elem1 = new Update();\r
+ _elem1.read(iprot);\r
+ struct.updates.add(_elem1);\r
+ }\r
+ iprot.readListEnd();\r
+ }\r
+ struct.setUpdatesIsSet(true);\r
+ } else {\r
+ org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);\r
+ }\r
+ break;\r
+ case 4: // MORE\r
+ if (schemeField.type == org.apache.thrift.protocol.TType.I32) {\r
+ struct.more = iprot.readI32();\r
+ struct.setMoreIsSet(true);\r
+ } else {\r
+ org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);\r
+ }\r
+ break;\r
+ default:\r
+ org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);\r
+ }\r
+ iprot.readFieldEnd();\r
+ }\r
+ iprot.readStructEnd();\r
+\r
+ // check for required fields of primitive type, which can't be checked in the validate method\r
+ struct.validate();\r
+ }\r
+\r
+ public void write(org.apache.thrift.protocol.TProtocol oprot, Routes struct) throws org.apache.thrift.TException {\r
+ struct.validate();\r
+\r
+ oprot.writeStructBegin(STRUCT_DESC);\r
+ oprot.writeFieldBegin(ERRCODE_FIELD_DESC);\r
+ oprot.writeI32(struct.errcode);\r
+ oprot.writeFieldEnd();\r
+ if (struct.updates != null) {\r
+ if (struct.isSetUpdates()) {\r
+ oprot.writeFieldBegin(UPDATES_FIELD_DESC);\r
+ {\r
+ oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, struct.updates.size()));\r
+ for (Update _iter3 : struct.updates)\r
+ {\r
+ _iter3.write(oprot);\r
+ }\r
+ oprot.writeListEnd();\r
+ }\r
+ oprot.writeFieldEnd();\r
+ }\r
+ }\r
+ if (struct.isSetMore()) {\r
+ oprot.writeFieldBegin(MORE_FIELD_DESC);\r
+ oprot.writeI32(struct.more);\r
+ oprot.writeFieldEnd();\r
+ }\r
+ oprot.writeFieldStop();\r
+ oprot.writeStructEnd();\r
+ }\r
+\r
+ }\r
+\r
+ private static class RoutesTupleSchemeFactory implements SchemeFactory {\r
+ public RoutesTupleScheme getScheme() {\r
+ return new RoutesTupleScheme();\r
+ }\r
+ }\r
+\r
+ private static class RoutesTupleScheme extends TupleScheme<Routes> {\r
+\r
+ @Override\r
+ public void write(org.apache.thrift.protocol.TProtocol prot, Routes struct) throws org.apache.thrift.TException {\r
+ TTupleProtocol oprot = (TTupleProtocol) prot;\r
+ BitSet optionals = new BitSet();\r
+ if (struct.isSetErrcode()) {\r
+ optionals.set(0);\r
+ }\r
+ if (struct.isSetUpdates()) {\r
+ optionals.set(1);\r
+ }\r
+ if (struct.isSetMore()) {\r
+ optionals.set(2);\r
+ }\r
+ oprot.writeBitSet(optionals, 3);\r
+ if (struct.isSetErrcode()) {\r
+ oprot.writeI32(struct.errcode);\r
+ }\r
+ if (struct.isSetUpdates()) {\r
+ {\r
+ oprot.writeI32(struct.updates.size());\r
+ for (Update _iter4 : struct.updates)\r
+ {\r
+ _iter4.write(oprot);\r
+ }\r
+ }\r
+ }\r
+ if (struct.isSetMore()) {\r
+ oprot.writeI32(struct.more);\r
+ }\r
+ }\r
+\r
+ @Override\r
+ public void read(org.apache.thrift.protocol.TProtocol prot, Routes struct) throws org.apache.thrift.TException {\r
+ TTupleProtocol iprot = (TTupleProtocol) prot;\r
+ BitSet incoming = iprot.readBitSet(3);\r
+ if (incoming.get(0)) {\r
+ struct.errcode = iprot.readI32();\r
+ struct.setErrcodeIsSet(true);\r
+ }\r
+ if (incoming.get(1)) {\r
+ {\r
+ org.apache.thrift.protocol.TList _list5 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32());\r
+ struct.updates = new ArrayList<Update>(_list5.size);\r
+ Update _elem6;\r
+ for (int _i7 = 0; _i7 < _list5.size; ++_i7)\r
+ {\r
+ _elem6 = new Update();\r
+ _elem6.read(iprot);\r
+ struct.updates.add(_elem6);\r
+ }\r
+ }\r
+ struct.setUpdatesIsSet(true);\r
+ }\r
+ if (incoming.get(2)) {\r
+ struct.more = iprot.readI32();\r
+ struct.setMoreIsSet(true);\r
+ }\r
+ }\r
+ }\r
+\r
+}\r
+\r
-/**
- * Autogenerated by Thrift Compiler (0.9.3)
- *
- * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
- * @generated
- */
- package org.opendaylight.netvirt.bgpmanager.thrift.gen;
-import org.apache.thrift.scheme.IScheme;
-import org.apache.thrift.scheme.SchemeFactory;
-import org.apache.thrift.scheme.StandardScheme;
-
-import org.apache.thrift.scheme.TupleScheme;
-import org.apache.thrift.protocol.TTupleProtocol;
-import org.apache.thrift.protocol.TProtocolException;
-import org.apache.thrift.EncodingUtils;
-import org.apache.thrift.TException;
-import org.apache.thrift.async.AsyncMethodCallback;
-import org.apache.thrift.server.AbstractNonblockingServer.*;
-import java.util.List;
-import java.util.ArrayList;
-import java.util.Map;
-import java.util.HashMap;
-import java.util.EnumMap;
-import java.util.Set;
-import java.util.HashSet;
-import java.util.EnumSet;
-import java.util.Collections;
-import java.util.BitSet;
-import java.nio.ByteBuffer;
-import java.util.Arrays;
-import javax.annotation.Generated;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"})
-@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)", date = "2017-09-13")
-public class Update implements org.apache.thrift.TBase<Update, Update._Fields>, java.io.Serializable, Cloneable, Comparable<Update> {
- private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("Update");
-
- private static final org.apache.thrift.protocol.TField TYPE_FIELD_DESC = new org.apache.thrift.protocol.TField("type", org.apache.thrift.protocol.TType.I32, (short)1);
- private static final org.apache.thrift.protocol.TField RESERVED_FIELD_DESC = new org.apache.thrift.protocol.TField("reserved", org.apache.thrift.protocol.TType.I32, (short)2);
- private static final org.apache.thrift.protocol.TField PREFIXLEN_FIELD_DESC = new org.apache.thrift.protocol.TField("prefixlen", org.apache.thrift.protocol.TType.I32, (short)3);
- private static final org.apache.thrift.protocol.TField L3LABEL_FIELD_DESC = new org.apache.thrift.protocol.TField("l3label", org.apache.thrift.protocol.TType.I32, (short)4);
- private static final org.apache.thrift.protocol.TField L2LABEL_FIELD_DESC = new org.apache.thrift.protocol.TField("l2label", org.apache.thrift.protocol.TType.I32, (short)5);
- private static final org.apache.thrift.protocol.TField ETHTAG_FIELD_DESC = new org.apache.thrift.protocol.TField("ethtag", org.apache.thrift.protocol.TType.I32, (short)6);
- private static final org.apache.thrift.protocol.TField ESI_FIELD_DESC = new org.apache.thrift.protocol.TField("esi", org.apache.thrift.protocol.TType.STRING, (short)7);
- private static final org.apache.thrift.protocol.TField MACADDRESS_FIELD_DESC = new org.apache.thrift.protocol.TField("macaddress", org.apache.thrift.protocol.TType.STRING, (short)8);
- private static final org.apache.thrift.protocol.TField RD_FIELD_DESC = new org.apache.thrift.protocol.TField("rd", org.apache.thrift.protocol.TType.STRING, (short)9);
- private static final org.apache.thrift.protocol.TField PREFIX_FIELD_DESC = new org.apache.thrift.protocol.TField("prefix", org.apache.thrift.protocol.TType.STRING, (short)10);
- private static final org.apache.thrift.protocol.TField NEXTHOP_FIELD_DESC = new org.apache.thrift.protocol.TField("nexthop", org.apache.thrift.protocol.TType.STRING, (short)11);
- private static final org.apache.thrift.protocol.TField ROUTERMAC_FIELD_DESC = new org.apache.thrift.protocol.TField("routermac", org.apache.thrift.protocol.TType.STRING, (short)12);
-
- private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
- static {
- schemes.put(StandardScheme.class, new UpdateStandardSchemeFactory());
- schemes.put(TupleScheme.class, new UpdateTupleSchemeFactory());
- }
-
- public int type; // required
- public int reserved; // required
- public int prefixlen; // required
- public int l3label; // required
- public int l2label; // required
- public int ethtag; // required
- public String esi; // required
- public String macaddress; // required
- public String rd; // required
- public String prefix; // required
- public String nexthop; // required
- public String routermac; // required
-
- /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
- public enum _Fields implements org.apache.thrift.TFieldIdEnum {
- TYPE((short)1, "type"),
- RESERVED((short)2, "reserved"),
- PREFIXLEN((short)3, "prefixlen"),
- L3LABEL((short)4, "l3label"),
- L2LABEL((short)5, "l2label"),
- ETHTAG((short)6, "ethtag"),
- ESI((short)7, "esi"),
- MACADDRESS((short)8, "macaddress"),
- RD((short)9, "rd"),
- PREFIX((short)10, "prefix"),
- NEXTHOP((short)11, "nexthop"),
- ROUTERMAC((short)12, "routermac");
-
- private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
-
- static {
- for (_Fields field : EnumSet.allOf(_Fields.class)) {
- byName.put(field.getFieldName(), field);
- }
- }
-
- /**
- * Find the _Fields constant that matches fieldId, or null if its not found.
- */
- public static _Fields findByThriftId(int fieldId) {
- switch(fieldId) {
- case 1: // TYPE
- return TYPE;
- case 2: // RESERVED
- return RESERVED;
- case 3: // PREFIXLEN
- return PREFIXLEN;
- case 4: // L3LABEL
- return L3LABEL;
- case 5: // L2LABEL
- return L2LABEL;
- case 6: // ETHTAG
- return ETHTAG;
- case 7: // ESI
- return ESI;
- case 8: // MACADDRESS
- return MACADDRESS;
- case 9: // RD
- return RD;
- case 10: // PREFIX
- return PREFIX;
- case 11: // NEXTHOP
- return NEXTHOP;
- case 12: // ROUTERMAC
- return ROUTERMAC;
- default:
- return null;
- }
- }
-
- /**
- * Find the _Fields constant that matches fieldId, throwing an exception
- * if it is not found.
- */
- public static _Fields findByThriftIdOrThrow(int fieldId) {
- _Fields fields = findByThriftId(fieldId);
- if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
- return fields;
- }
-
- /**
- * Find the _Fields constant that matches name, or null if its not found.
- */
- public static _Fields findByName(String name) {
- return byName.get(name);
- }
-
- private final short _thriftId;
- private final String _fieldName;
-
- _Fields(short thriftId, String fieldName) {
- _thriftId = thriftId;
- _fieldName = fieldName;
- }
-
- public short getThriftFieldId() {
- return _thriftId;
- }
-
- public String getFieldName() {
- return _fieldName;
- }
- }
-
- // isset id assignments
- private static final int __TYPE_ISSET_ID = 0;
- private static final int __RESERVED_ISSET_ID = 1;
- private static final int __PREFIXLEN_ISSET_ID = 2;
- private static final int __L3LABEL_ISSET_ID = 3;
- private static final int __L2LABEL_ISSET_ID = 4;
- private static final int __ETHTAG_ISSET_ID = 5;
- private byte __isset_bitfield = 0;
- public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
- static {
- Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
- tmpMap.put(_Fields.TYPE, new org.apache.thrift.meta_data.FieldMetaData("type", org.apache.thrift.TFieldRequirementType.DEFAULT,
- new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I32)));
- tmpMap.put(_Fields.RESERVED, new org.apache.thrift.meta_data.FieldMetaData("reserved", org.apache.thrift.TFieldRequirementType.DEFAULT,
- new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I32)));
- tmpMap.put(_Fields.PREFIXLEN, new org.apache.thrift.meta_data.FieldMetaData("prefixlen", org.apache.thrift.TFieldRequirementType.DEFAULT,
- new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I32)));
- tmpMap.put(_Fields.L3LABEL, new org.apache.thrift.meta_data.FieldMetaData("l3label", org.apache.thrift.TFieldRequirementType.DEFAULT,
- new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I32)));
- tmpMap.put(_Fields.L2LABEL, new org.apache.thrift.meta_data.FieldMetaData("l2label", org.apache.thrift.TFieldRequirementType.DEFAULT,
- new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I32)));
- tmpMap.put(_Fields.ETHTAG, new org.apache.thrift.meta_data.FieldMetaData("ethtag", org.apache.thrift.TFieldRequirementType.DEFAULT,
- new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I32)));
- tmpMap.put(_Fields.ESI, new org.apache.thrift.meta_data.FieldMetaData("esi", org.apache.thrift.TFieldRequirementType.DEFAULT,
- new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
- tmpMap.put(_Fields.MACADDRESS, new org.apache.thrift.meta_data.FieldMetaData("macaddress", org.apache.thrift.TFieldRequirementType.DEFAULT,
- new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
- tmpMap.put(_Fields.RD, new org.apache.thrift.meta_data.FieldMetaData("rd", org.apache.thrift.TFieldRequirementType.DEFAULT,
- new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
- tmpMap.put(_Fields.PREFIX, new org.apache.thrift.meta_data.FieldMetaData("prefix", org.apache.thrift.TFieldRequirementType.DEFAULT,
- new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
- tmpMap.put(_Fields.NEXTHOP, new org.apache.thrift.meta_data.FieldMetaData("nexthop", org.apache.thrift.TFieldRequirementType.DEFAULT,
- new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
- tmpMap.put(_Fields.ROUTERMAC, new org.apache.thrift.meta_data.FieldMetaData("routermac", org.apache.thrift.TFieldRequirementType.DEFAULT,
- new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
- metaDataMap = Collections.unmodifiableMap(tmpMap);
- org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(Update.class, metaDataMap);
- }
-
- public Update() {
- }
-
- public Update(
- int type,
- int reserved,
- int prefixlen,
- int l3label,
- int l2label,
- int ethtag,
- String esi,
- String macaddress,
- String rd,
- String prefix,
- String nexthop,
- String routermac)
- {
- this();
- this.type = type;
- setTypeIsSet(true);
- this.reserved = reserved;
- setReservedIsSet(true);
- this.prefixlen = prefixlen;
- setPrefixlenIsSet(true);
- this.l3label = l3label;
- setL3labelIsSet(true);
- this.l2label = l2label;
- setL2labelIsSet(true);
- this.ethtag = ethtag;
- setEthtagIsSet(true);
- this.esi = esi;
- this.macaddress = macaddress;
- this.rd = rd;
- this.prefix = prefix;
- this.nexthop = nexthop;
- this.routermac = routermac;
- }
-
- /**
- * Performs a deep copy on <i>other</i>.
- */
- public Update(Update other) {
- __isset_bitfield = other.__isset_bitfield;
- this.type = other.type;
- this.reserved = other.reserved;
- this.prefixlen = other.prefixlen;
- this.l3label = other.l3label;
- this.l2label = other.l2label;
- this.ethtag = other.ethtag;
- if (other.isSetEsi()) {
- this.esi = other.esi;
- }
- if (other.isSetMacaddress()) {
- this.macaddress = other.macaddress;
- }
- if (other.isSetRd()) {
- this.rd = other.rd;
- }
- if (other.isSetPrefix()) {
- this.prefix = other.prefix;
- }
- if (other.isSetNexthop()) {
- this.nexthop = other.nexthop;
- }
- if (other.isSetRoutermac()) {
- this.routermac = other.routermac;
- }
- }
-
- public Update deepCopy() {
- return new Update(this);
- }
-
- @Override
- public void clear() {
- setTypeIsSet(false);
- this.type = 0;
- setReservedIsSet(false);
- this.reserved = 0;
- setPrefixlenIsSet(false);
- this.prefixlen = 0;
- setL3labelIsSet(false);
- this.l3label = 0;
- setL2labelIsSet(false);
- this.l2label = 0;
- setEthtagIsSet(false);
- this.ethtag = 0;
- this.esi = null;
- this.macaddress = null;
- this.rd = null;
- this.prefix = null;
- this.nexthop = null;
- this.routermac = null;
- }
-
- public int getType() {
- return this.type;
- }
-
- public Update setType(int type) {
- this.type = type;
- setTypeIsSet(true);
- return this;
- }
-
- public void unsetType() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __TYPE_ISSET_ID);
- }
-
- /** Returns true if field type is set (has been assigned a value) and false otherwise */
- public boolean isSetType() {
- return EncodingUtils.testBit(__isset_bitfield, __TYPE_ISSET_ID);
- }
-
- public void setTypeIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __TYPE_ISSET_ID, value);
- }
-
- public int getReserved() {
- return this.reserved;
- }
-
- public Update setReserved(int reserved) {
- this.reserved = reserved;
- setReservedIsSet(true);
- return this;
- }
-
- public void unsetReserved() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __RESERVED_ISSET_ID);
- }
-
- /** Returns true if field reserved is set (has been assigned a value) and false otherwise */
- public boolean isSetReserved() {
- return EncodingUtils.testBit(__isset_bitfield, __RESERVED_ISSET_ID);
- }
-
- public void setReservedIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __RESERVED_ISSET_ID, value);
- }
-
- public int getPrefixlen() {
- return this.prefixlen;
- }
-
- public Update setPrefixlen(int prefixlen) {
- this.prefixlen = prefixlen;
- setPrefixlenIsSet(true);
- return this;
- }
-
- public void unsetPrefixlen() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __PREFIXLEN_ISSET_ID);
- }
-
- /** Returns true if field prefixlen is set (has been assigned a value) and false otherwise */
- public boolean isSetPrefixlen() {
- return EncodingUtils.testBit(__isset_bitfield, __PREFIXLEN_ISSET_ID);
- }
-
- public void setPrefixlenIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __PREFIXLEN_ISSET_ID, value);
- }
-
- public int getL3label() {
- return this.l3label;
- }
-
- public Update setL3label(int l3label) {
- this.l3label = l3label;
- setL3labelIsSet(true);
- return this;
- }
-
- public void unsetL3label() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __L3LABEL_ISSET_ID);
- }
-
- /** Returns true if field l3label is set (has been assigned a value) and false otherwise */
- public boolean isSetL3label() {
- return EncodingUtils.testBit(__isset_bitfield, __L3LABEL_ISSET_ID);
- }
-
- public void setL3labelIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __L3LABEL_ISSET_ID, value);
- }
-
- public int getL2label() {
- return this.l2label;
- }
-
- public Update setL2label(int l2label) {
- this.l2label = l2label;
- setL2labelIsSet(true);
- return this;
- }
-
- public void unsetL2label() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __L2LABEL_ISSET_ID);
- }
-
- /** Returns true if field l2label is set (has been assigned a value) and false otherwise */
- public boolean isSetL2label() {
- return EncodingUtils.testBit(__isset_bitfield, __L2LABEL_ISSET_ID);
- }
-
- public void setL2labelIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __L2LABEL_ISSET_ID, value);
- }
-
- public int getEthtag() {
- return this.ethtag;
- }
-
- public Update setEthtag(int ethtag) {
- this.ethtag = ethtag;
- setEthtagIsSet(true);
- return this;
- }
-
- public void unsetEthtag() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __ETHTAG_ISSET_ID);
- }
-
- /** Returns true if field ethtag is set (has been assigned a value) and false otherwise */
- public boolean isSetEthtag() {
- return EncodingUtils.testBit(__isset_bitfield, __ETHTAG_ISSET_ID);
- }
-
- public void setEthtagIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __ETHTAG_ISSET_ID, value);
- }
-
- public String getEsi() {
- return this.esi;
- }
-
- public Update setEsi(String esi) {
- this.esi = esi;
- return this;
- }
-
- public void unsetEsi() {
- this.esi = null;
- }
-
- /** Returns true if field esi is set (has been assigned a value) and false otherwise */
- public boolean isSetEsi() {
- return this.esi != null;
- }
-
- public void setEsiIsSet(boolean value) {
- if (!value) {
- this.esi = null;
- }
- }
-
- public String getMacaddress() {
- return this.macaddress;
- }
-
- public Update setMacaddress(String macaddress) {
- this.macaddress = macaddress;
- return this;
- }
-
- public void unsetMacaddress() {
- this.macaddress = null;
- }
-
- /** Returns true if field macaddress is set (has been assigned a value) and false otherwise */
- public boolean isSetMacaddress() {
- return this.macaddress != null;
- }
-
- public void setMacaddressIsSet(boolean value) {
- if (!value) {
- this.macaddress = null;
- }
- }
-
- public String getRd() {
- return this.rd;
- }
-
- public Update setRd(String rd) {
- this.rd = rd;
- return this;
- }
-
- public void unsetRd() {
- this.rd = null;
- }
-
- /** Returns true if field rd is set (has been assigned a value) and false otherwise */
- public boolean isSetRd() {
- return this.rd != null;
- }
-
- public void setRdIsSet(boolean value) {
- if (!value) {
- this.rd = null;
- }
- }
-
- public String getPrefix() {
- return this.prefix;
- }
-
- public Update setPrefix(String prefix) {
- this.prefix = prefix;
- return this;
- }
-
- public void unsetPrefix() {
- this.prefix = null;
- }
-
- /** Returns true if field prefix is set (has been assigned a value) and false otherwise */
- public boolean isSetPrefix() {
- return this.prefix != null;
- }
-
- public void setPrefixIsSet(boolean value) {
- if (!value) {
- this.prefix = null;
- }
- }
-
- public String getNexthop() {
- return this.nexthop;
- }
-
- public Update setNexthop(String nexthop) {
- this.nexthop = nexthop;
- return this;
- }
-
- public void unsetNexthop() {
- this.nexthop = null;
- }
-
- /** Returns true if field nexthop is set (has been assigned a value) and false otherwise */
- public boolean isSetNexthop() {
- return this.nexthop != null;
- }
-
- public void setNexthopIsSet(boolean value) {
- if (!value) {
- this.nexthop = null;
- }
- }
-
- public String getRoutermac() {
- return this.routermac;
- }
-
- public Update setRoutermac(String routermac) {
- this.routermac = routermac;
- return this;
- }
-
- public void unsetRoutermac() {
- this.routermac = null;
- }
-
- /** Returns true if field routermac is set (has been assigned a value) and false otherwise */
- public boolean isSetRoutermac() {
- return this.routermac != null;
- }
-
- public void setRoutermacIsSet(boolean value) {
- if (!value) {
- this.routermac = null;
- }
- }
-
- public void setFieldValue(_Fields field, Object value) {
- switch (field) {
- case TYPE:
- if (value == null) {
- unsetType();
- } else {
- setType((Integer)value);
- }
- break;
-
- case RESERVED:
- if (value == null) {
- unsetReserved();
- } else {
- setReserved((Integer)value);
- }
- break;
-
- case PREFIXLEN:
- if (value == null) {
- unsetPrefixlen();
- } else {
- setPrefixlen((Integer)value);
- }
- break;
-
- case L3LABEL:
- if (value == null) {
- unsetL3label();
- } else {
- setL3label((Integer)value);
- }
- break;
-
- case L2LABEL:
- if (value == null) {
- unsetL2label();
- } else {
- setL2label((Integer)value);
- }
- break;
-
- case ETHTAG:
- if (value == null) {
- unsetEthtag();
- } else {
- setEthtag((Integer)value);
- }
- break;
-
- case ESI:
- if (value == null) {
- unsetEsi();
- } else {
- setEsi((String)value);
- }
- break;
-
- case MACADDRESS:
- if (value == null) {
- unsetMacaddress();
- } else {
- setMacaddress((String)value);
- }
- break;
-
- case RD:
- if (value == null) {
- unsetRd();
- } else {
- setRd((String)value);
- }
- break;
-
- case PREFIX:
- if (value == null) {
- unsetPrefix();
- } else {
- setPrefix((String)value);
- }
- break;
-
- case NEXTHOP:
- if (value == null) {
- unsetNexthop();
- } else {
- setNexthop((String)value);
- }
- break;
-
- case ROUTERMAC:
- if (value == null) {
- unsetRoutermac();
- } else {
- setRoutermac((String)value);
- }
- break;
-
- }
- }
-
- public Object getFieldValue(_Fields field) {
- switch (field) {
- case TYPE:
- return Integer.valueOf(getType());
-
- case RESERVED:
- return Integer.valueOf(getReserved());
-
- case PREFIXLEN:
- return Integer.valueOf(getPrefixlen());
-
- case L3LABEL:
- return Integer.valueOf(getL3label());
-
- case L2LABEL:
- return Integer.valueOf(getL2label());
-
- case ETHTAG:
- return Integer.valueOf(getEthtag());
-
- case ESI:
- return getEsi();
-
- case MACADDRESS:
- return getMacaddress();
-
- case RD:
- return getRd();
-
- case PREFIX:
- return getPrefix();
-
- case NEXTHOP:
- return getNexthop();
-
- case ROUTERMAC:
- return getRoutermac();
-
- }
- throw new IllegalStateException();
- }
-
- /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
- public boolean isSet(_Fields field) {
- if (field == null) {
- throw new IllegalArgumentException();
- }
-
- switch (field) {
- case TYPE:
- return isSetType();
- case RESERVED:
- return isSetReserved();
- case PREFIXLEN:
- return isSetPrefixlen();
- case L3LABEL:
- return isSetL3label();
- case L2LABEL:
- return isSetL2label();
- case ETHTAG:
- return isSetEthtag();
- case ESI:
- return isSetEsi();
- case MACADDRESS:
- return isSetMacaddress();
- case RD:
- return isSetRd();
- case PREFIX:
- return isSetPrefix();
- case NEXTHOP:
- return isSetNexthop();
- case ROUTERMAC:
- return isSetRoutermac();
- }
- throw new IllegalStateException();
- }
-
- @Override
- public boolean equals(Object that) {
- if (that == null)
- return false;
- if (that instanceof Update)
- return this.equals((Update)that);
- return false;
- }
-
- public boolean equals(Update that) {
- if (that == null)
- return false;
-
- boolean this_present_type = true;
- boolean that_present_type = true;
- if (this_present_type || that_present_type) {
- if (!(this_present_type && that_present_type))
- return false;
- if (this.type != that.type)
- return false;
- }
-
- boolean this_present_reserved = true;
- boolean that_present_reserved = true;
- if (this_present_reserved || that_present_reserved) {
- if (!(this_present_reserved && that_present_reserved))
- return false;
- if (this.reserved != that.reserved)
- return false;
- }
-
- boolean this_present_prefixlen = true;
- boolean that_present_prefixlen = true;
- if (this_present_prefixlen || that_present_prefixlen) {
- if (!(this_present_prefixlen && that_present_prefixlen))
- return false;
- if (this.prefixlen != that.prefixlen)
- return false;
- }
-
- boolean this_present_l3label = true;
- boolean that_present_l3label = true;
- if (this_present_l3label || that_present_l3label) {
- if (!(this_present_l3label && that_present_l3label))
- return false;
- if (this.l3label != that.l3label)
- return false;
- }
-
- boolean this_present_l2label = true;
- boolean that_present_l2label = true;
- if (this_present_l2label || that_present_l2label) {
- if (!(this_present_l2label && that_present_l2label))
- return false;
- if (this.l2label != that.l2label)
- return false;
- }
-
- boolean this_present_ethtag = true;
- boolean that_present_ethtag = true;
- if (this_present_ethtag || that_present_ethtag) {
- if (!(this_present_ethtag && that_present_ethtag))
- return false;
- if (this.ethtag != that.ethtag)
- return false;
- }
-
- boolean this_present_esi = true && this.isSetEsi();
- boolean that_present_esi = true && that.isSetEsi();
- if (this_present_esi || that_present_esi) {
- if (!(this_present_esi && that_present_esi))
- return false;
- if (!this.esi.equals(that.esi))
- return false;
- }
-
- boolean this_present_macaddress = true && this.isSetMacaddress();
- boolean that_present_macaddress = true && that.isSetMacaddress();
- if (this_present_macaddress || that_present_macaddress) {
- if (!(this_present_macaddress && that_present_macaddress))
- return false;
- if (!this.macaddress.equals(that.macaddress))
- return false;
- }
-
- boolean this_present_rd = true && this.isSetRd();
- boolean that_present_rd = true && that.isSetRd();
- if (this_present_rd || that_present_rd) {
- if (!(this_present_rd && that_present_rd))
- return false;
- if (!this.rd.equals(that.rd))
- return false;
- }
-
- boolean this_present_prefix = true && this.isSetPrefix();
- boolean that_present_prefix = true && that.isSetPrefix();
- if (this_present_prefix || that_present_prefix) {
- if (!(this_present_prefix && that_present_prefix))
- return false;
- if (!this.prefix.equals(that.prefix))
- return false;
- }
-
- boolean this_present_nexthop = true && this.isSetNexthop();
- boolean that_present_nexthop = true && that.isSetNexthop();
- if (this_present_nexthop || that_present_nexthop) {
- if (!(this_present_nexthop && that_present_nexthop))
- return false;
- if (!this.nexthop.equals(that.nexthop))
- return false;
- }
-
- boolean this_present_routermac = true && this.isSetRoutermac();
- boolean that_present_routermac = true && that.isSetRoutermac();
- if (this_present_routermac || that_present_routermac) {
- if (!(this_present_routermac && that_present_routermac))
- return false;
- if (!this.routermac.equals(that.routermac))
- return false;
- }
-
- return true;
- }
-
- @Override
- public int hashCode() {
- List<Object> list = new ArrayList<Object>();
- boolean present_type = true;
- list.add(present_type);
- if (present_type)
- list.add(type);
- boolean present_reserved = true;
- list.add(present_reserved);
- if (present_reserved)
- list.add(reserved);
- boolean present_prefixlen = true;
- list.add(present_prefixlen);
- if (present_prefixlen)
- list.add(prefixlen);
- boolean present_l3label = true;
- list.add(present_l3label);
- if (present_l3label)
- list.add(l3label);
- boolean present_l2label = true;
- list.add(present_l2label);
- if (present_l2label)
- list.add(l2label);
- boolean present_ethtag = true;
- list.add(present_ethtag);
- if (present_ethtag)
- list.add(ethtag);
- boolean present_esi = true && (isSetEsi());
- list.add(present_esi);
- if (present_esi)
- list.add(esi);
- boolean present_macaddress = true && (isSetMacaddress());
- list.add(present_macaddress);
- if (present_macaddress)
- list.add(macaddress);
- boolean present_rd = true && (isSetRd());
- list.add(present_rd);
- if (present_rd)
- list.add(rd);
- boolean present_prefix = true && (isSetPrefix());
- list.add(present_prefix);
- if (present_prefix)
- list.add(prefix);
- boolean present_nexthop = true && (isSetNexthop());
- list.add(present_nexthop);
- if (present_nexthop)
- list.add(nexthop);
- boolean present_routermac = true && (isSetRoutermac());
- list.add(present_routermac);
- if (present_routermac)
- list.add(routermac);
- return list.hashCode();
- }
-
- @Override
- public int compareTo(Update other) {
- if (!getClass().equals(other.getClass())) {
- return getClass().getName().compareTo(other.getClass().getName());
- }
-
- int lastComparison = 0;
-
- lastComparison = Boolean.valueOf(isSetType()).compareTo(other.isSetType());
- if (lastComparison != 0) {
- return lastComparison;
- }
- if (isSetType()) {
- lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.type, other.type);
- if (lastComparison != 0) {
- return lastComparison;
- }
- }
- lastComparison = Boolean.valueOf(isSetReserved()).compareTo(other.isSetReserved());
- if (lastComparison != 0) {
- return lastComparison;
- }
- if (isSetReserved()) {
- lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.reserved, other.reserved);
- if (lastComparison != 0) {
- return lastComparison;
- }
- }
- lastComparison = Boolean.valueOf(isSetPrefixlen()).compareTo(other.isSetPrefixlen());
- if (lastComparison != 0) {
- return lastComparison;
- }
- if (isSetPrefixlen()) {
- lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.prefixlen, other.prefixlen);
- if (lastComparison != 0) {
- return lastComparison;
- }
- }
- lastComparison = Boolean.valueOf(isSetL3label()).compareTo(other.isSetL3label());
- if (lastComparison != 0) {
- return lastComparison;
- }
- if (isSetL3label()) {
- lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.l3label, other.l3label);
- if (lastComparison != 0) {
- return lastComparison;
- }
- }
- lastComparison = Boolean.valueOf(isSetL2label()).compareTo(other.isSetL2label());
- if (lastComparison != 0) {
- return lastComparison;
- }
- if (isSetL2label()) {
- lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.l2label, other.l2label);
- if (lastComparison != 0) {
- return lastComparison;
- }
- }
- lastComparison = Boolean.valueOf(isSetEthtag()).compareTo(other.isSetEthtag());
- if (lastComparison != 0) {
- return lastComparison;
- }
- if (isSetEthtag()) {
- lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.ethtag, other.ethtag);
- if (lastComparison != 0) {
- return lastComparison;
- }
- }
- lastComparison = Boolean.valueOf(isSetEsi()).compareTo(other.isSetEsi());
- if (lastComparison != 0) {
- return lastComparison;
- }
- if (isSetEsi()) {
- lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.esi, other.esi);
- if (lastComparison != 0) {
- return lastComparison;
- }
- }
- lastComparison = Boolean.valueOf(isSetMacaddress()).compareTo(other.isSetMacaddress());
- if (lastComparison != 0) {
- return lastComparison;
- }
- if (isSetMacaddress()) {
- lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.macaddress, other.macaddress);
- if (lastComparison != 0) {
- return lastComparison;
- }
- }
- lastComparison = Boolean.valueOf(isSetRd()).compareTo(other.isSetRd());
- if (lastComparison != 0) {
- return lastComparison;
- }
- if (isSetRd()) {
- lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.rd, other.rd);
- if (lastComparison != 0) {
- return lastComparison;
- }
- }
- lastComparison = Boolean.valueOf(isSetPrefix()).compareTo(other.isSetPrefix());
- if (lastComparison != 0) {
- return lastComparison;
- }
- if (isSetPrefix()) {
- lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.prefix, other.prefix);
- if (lastComparison != 0) {
- return lastComparison;
- }
- }
- lastComparison = Boolean.valueOf(isSetNexthop()).compareTo(other.isSetNexthop());
- if (lastComparison != 0) {
- return lastComparison;
- }
- if (isSetNexthop()) {
- lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.nexthop, other.nexthop);
- if (lastComparison != 0) {
- return lastComparison;
- }
- }
- lastComparison = Boolean.valueOf(isSetRoutermac()).compareTo(other.isSetRoutermac());
- if (lastComparison != 0) {
- return lastComparison;
- }
- if (isSetRoutermac()) {
- lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.routermac, other.routermac);
- if (lastComparison != 0) {
- return lastComparison;
- }
- }
- return 0;
- }
-
- public _Fields fieldForId(int fieldId) {
- return _Fields.findByThriftId(fieldId);
- }
-
- public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
- schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
- }
-
- public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
- schemes.get(oprot.getScheme()).getScheme().write(oprot, this);
- }
-
- @Override
- public String toString() {
- StringBuilder sb = new StringBuilder("Update(");
- boolean first = true;
-
- sb.append("type:");
- sb.append(this.type);
- first = false;
- if (!first) sb.append(", ");
- sb.append("reserved:");
- sb.append(this.reserved);
- first = false;
- if (!first) sb.append(", ");
- sb.append("prefixlen:");
- sb.append(this.prefixlen);
- first = false;
- if (!first) sb.append(", ");
- sb.append("l3label:");
- sb.append(this.l3label);
- first = false;
- if (!first) sb.append(", ");
- sb.append("l2label:");
- sb.append(this.l2label);
- first = false;
- if (!first) sb.append(", ");
- sb.append("ethtag:");
- sb.append(this.ethtag);
- first = false;
- if (!first) sb.append(", ");
- sb.append("esi:");
- if (this.esi == null) {
- sb.append("null");
- } else {
- sb.append(this.esi);
- }
- first = false;
- if (!first) sb.append(", ");
- sb.append("macaddress:");
- if (this.macaddress == null) {
- sb.append("null");
- } else {
- sb.append(this.macaddress);
- }
- first = false;
- if (!first) sb.append(", ");
- sb.append("rd:");
- if (this.rd == null) {
- sb.append("null");
- } else {
- sb.append(this.rd);
- }
- first = false;
- if (!first) sb.append(", ");
- sb.append("prefix:");
- if (this.prefix == null) {
- sb.append("null");
- } else {
- sb.append(this.prefix);
- }
- first = false;
- if (!first) sb.append(", ");
- sb.append("nexthop:");
- if (this.nexthop == null) {
- sb.append("null");
- } else {
- sb.append(this.nexthop);
- }
- first = false;
- if (!first) sb.append(", ");
- sb.append("routermac:");
- if (this.routermac == null) {
- sb.append("null");
- } else {
- sb.append(this.routermac);
- }
- first = false;
- sb.append(")");
- return sb.toString();
- }
-
- public void validate() throws org.apache.thrift.TException {
- // check for required fields
- // check for sub-struct validity
- }
-
- private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
- try {
- write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
- } catch (org.apache.thrift.TException te) {
- throw new java.io.IOException(te);
- }
- }
-
- private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
- try {
- // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
- __isset_bitfield = 0;
- read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
- } catch (org.apache.thrift.TException te) {
- throw new java.io.IOException(te);
- }
- }
-
- private static class UpdateStandardSchemeFactory implements SchemeFactory {
- public UpdateStandardScheme getScheme() {
- return new UpdateStandardScheme();
- }
- }
-
- private static class UpdateStandardScheme extends StandardScheme<Update> {
-
- public void read(org.apache.thrift.protocol.TProtocol iprot, Update struct) throws org.apache.thrift.TException {
- org.apache.thrift.protocol.TField schemeField;
- iprot.readStructBegin();
- while (true)
- {
- schemeField = iprot.readFieldBegin();
- if (schemeField.type == org.apache.thrift.protocol.TType.STOP) {
- break;
- }
- switch (schemeField.id) {
- case 1: // TYPE
- if (schemeField.type == org.apache.thrift.protocol.TType.I32) {
- struct.type = iprot.readI32();
- struct.setTypeIsSet(true);
- } else {
- org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
- }
- break;
- case 2: // RESERVED
- if (schemeField.type == org.apache.thrift.protocol.TType.I32) {
- struct.reserved = iprot.readI32();
- struct.setReservedIsSet(true);
- } else {
- org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
- }
- break;
- case 3: // PREFIXLEN
- if (schemeField.type == org.apache.thrift.protocol.TType.I32) {
- struct.prefixlen = iprot.readI32();
- struct.setPrefixlenIsSet(true);
- } else {
- org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
- }
- break;
- case 4: // L3LABEL
- if (schemeField.type == org.apache.thrift.protocol.TType.I32) {
- struct.l3label = iprot.readI32();
- struct.setL3labelIsSet(true);
- } else {
- org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
- }
- break;
- case 5: // L2LABEL
- if (schemeField.type == org.apache.thrift.protocol.TType.I32) {
- struct.l2label = iprot.readI32();
- struct.setL2labelIsSet(true);
- } else {
- org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
- }
- break;
- case 6: // ETHTAG
- if (schemeField.type == org.apache.thrift.protocol.TType.I32) {
- struct.ethtag = iprot.readI32();
- struct.setEthtagIsSet(true);
- } else {
- org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
- }
- break;
- case 7: // ESI
- if (schemeField.type == org.apache.thrift.protocol.TType.STRING) {
- struct.esi = iprot.readString();
- struct.setEsiIsSet(true);
- } else {
- org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
- }
- break;
- case 8: // MACADDRESS
- if (schemeField.type == org.apache.thrift.protocol.TType.STRING) {
- struct.macaddress = iprot.readString();
- struct.setMacaddressIsSet(true);
- } else {
- org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
- }
- break;
- case 9: // RD
- if (schemeField.type == org.apache.thrift.protocol.TType.STRING) {
- struct.rd = iprot.readString();
- struct.setRdIsSet(true);
- } else {
- org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
- }
- break;
- case 10: // PREFIX
- if (schemeField.type == org.apache.thrift.protocol.TType.STRING) {
- struct.prefix = iprot.readString();
- struct.setPrefixIsSet(true);
- } else {
- org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
- }
- break;
- case 11: // NEXTHOP
- if (schemeField.type == org.apache.thrift.protocol.TType.STRING) {
- struct.nexthop = iprot.readString();
- struct.setNexthopIsSet(true);
- } else {
- org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
- }
- break;
- case 12: // ROUTERMAC
- if (schemeField.type == org.apache.thrift.protocol.TType.STRING) {
- struct.routermac = iprot.readString();
- struct.setRoutermacIsSet(true);
- } else {
- org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
- }
- break;
- default:
- org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
- }
- iprot.readFieldEnd();
- }
- iprot.readStructEnd();
-
- // check for required fields of primitive type, which can't be checked in the validate method
- struct.validate();
- }
-
- public void write(org.apache.thrift.protocol.TProtocol oprot, Update struct) throws org.apache.thrift.TException {
- struct.validate();
-
- oprot.writeStructBegin(STRUCT_DESC);
- oprot.writeFieldBegin(TYPE_FIELD_DESC);
- oprot.writeI32(struct.type);
- oprot.writeFieldEnd();
- oprot.writeFieldBegin(RESERVED_FIELD_DESC);
- oprot.writeI32(struct.reserved);
- oprot.writeFieldEnd();
- oprot.writeFieldBegin(PREFIXLEN_FIELD_DESC);
- oprot.writeI32(struct.prefixlen);
- oprot.writeFieldEnd();
- oprot.writeFieldBegin(L3LABEL_FIELD_DESC);
- oprot.writeI32(struct.l3label);
- oprot.writeFieldEnd();
- oprot.writeFieldBegin(L2LABEL_FIELD_DESC);
- oprot.writeI32(struct.l2label);
- oprot.writeFieldEnd();
- oprot.writeFieldBegin(ETHTAG_FIELD_DESC);
- oprot.writeI32(struct.ethtag);
- oprot.writeFieldEnd();
- if (struct.esi != null) {
- oprot.writeFieldBegin(ESI_FIELD_DESC);
- oprot.writeString(struct.esi);
- oprot.writeFieldEnd();
- }
- if (struct.macaddress != null) {
- oprot.writeFieldBegin(MACADDRESS_FIELD_DESC);
- oprot.writeString(struct.macaddress);
- oprot.writeFieldEnd();
- }
- if (struct.rd != null) {
- oprot.writeFieldBegin(RD_FIELD_DESC);
- oprot.writeString(struct.rd);
- oprot.writeFieldEnd();
- }
- if (struct.prefix != null) {
- oprot.writeFieldBegin(PREFIX_FIELD_DESC);
- oprot.writeString(struct.prefix);
- oprot.writeFieldEnd();
- }
- if (struct.nexthop != null) {
- oprot.writeFieldBegin(NEXTHOP_FIELD_DESC);
- oprot.writeString(struct.nexthop);
- oprot.writeFieldEnd();
- }
- if (struct.routermac != null) {
- oprot.writeFieldBegin(ROUTERMAC_FIELD_DESC);
- oprot.writeString(struct.routermac);
- oprot.writeFieldEnd();
- }
- oprot.writeFieldStop();
- oprot.writeStructEnd();
- }
-
- }
-
- private static class UpdateTupleSchemeFactory implements SchemeFactory {
- public UpdateTupleScheme getScheme() {
- return new UpdateTupleScheme();
- }
- }
-
- private static class UpdateTupleScheme extends TupleScheme<Update> {
-
- @Override
- public void write(org.apache.thrift.protocol.TProtocol prot, Update struct) throws org.apache.thrift.TException {
- TTupleProtocol oprot = (TTupleProtocol) prot;
- BitSet optionals = new BitSet();
- if (struct.isSetType()) {
- optionals.set(0);
- }
- if (struct.isSetReserved()) {
- optionals.set(1);
- }
- if (struct.isSetPrefixlen()) {
- optionals.set(2);
- }
- if (struct.isSetL3label()) {
- optionals.set(3);
- }
- if (struct.isSetL2label()) {
- optionals.set(4);
- }
- if (struct.isSetEthtag()) {
- optionals.set(5);
- }
- if (struct.isSetEsi()) {
- optionals.set(6);
- }
- if (struct.isSetMacaddress()) {
- optionals.set(7);
- }
- if (struct.isSetRd()) {
- optionals.set(8);
- }
- if (struct.isSetPrefix()) {
- optionals.set(9);
- }
- if (struct.isSetNexthop()) {
- optionals.set(10);
- }
- if (struct.isSetRoutermac()) {
- optionals.set(11);
- }
- oprot.writeBitSet(optionals, 12);
- if (struct.isSetType()) {
- oprot.writeI32(struct.type);
- }
- if (struct.isSetReserved()) {
- oprot.writeI32(struct.reserved);
- }
- if (struct.isSetPrefixlen()) {
- oprot.writeI32(struct.prefixlen);
- }
- if (struct.isSetL3label()) {
- oprot.writeI32(struct.l3label);
- }
- if (struct.isSetL2label()) {
- oprot.writeI32(struct.l2label);
- }
- if (struct.isSetEthtag()) {
- oprot.writeI32(struct.ethtag);
- }
- if (struct.isSetEsi()) {
- oprot.writeString(struct.esi);
- }
- if (struct.isSetMacaddress()) {
- oprot.writeString(struct.macaddress);
- }
- if (struct.isSetRd()) {
- oprot.writeString(struct.rd);
- }
- if (struct.isSetPrefix()) {
- oprot.writeString(struct.prefix);
- }
- if (struct.isSetNexthop()) {
- oprot.writeString(struct.nexthop);
- }
- if (struct.isSetRoutermac()) {
- oprot.writeString(struct.routermac);
- }
- }
-
- @Override
- public void read(org.apache.thrift.protocol.TProtocol prot, Update struct) throws org.apache.thrift.TException {
- TTupleProtocol iprot = (TTupleProtocol) prot;
- BitSet incoming = iprot.readBitSet(12);
- if (incoming.get(0)) {
- struct.type = iprot.readI32();
- struct.setTypeIsSet(true);
- }
- if (incoming.get(1)) {
- struct.reserved = iprot.readI32();
- struct.setReservedIsSet(true);
- }
- if (incoming.get(2)) {
- struct.prefixlen = iprot.readI32();
- struct.setPrefixlenIsSet(true);
- }
- if (incoming.get(3)) {
- struct.l3label = iprot.readI32();
- struct.setL3labelIsSet(true);
- }
- if (incoming.get(4)) {
- struct.l2label = iprot.readI32();
- struct.setL2labelIsSet(true);
- }
- if (incoming.get(5)) {
- struct.ethtag = iprot.readI32();
- struct.setEthtagIsSet(true);
- }
- if (incoming.get(6)) {
- struct.esi = iprot.readString();
- struct.setEsiIsSet(true);
- }
- if (incoming.get(7)) {
- struct.macaddress = iprot.readString();
- struct.setMacaddressIsSet(true);
- }
- if (incoming.get(8)) {
- struct.rd = iprot.readString();
- struct.setRdIsSet(true);
- }
- if (incoming.get(9)) {
- struct.prefix = iprot.readString();
- struct.setPrefixIsSet(true);
- }
- if (incoming.get(10)) {
- struct.nexthop = iprot.readString();
- struct.setNexthopIsSet(true);
- }
- if (incoming.get(11)) {
- struct.routermac = iprot.readString();
- struct.setRoutermacIsSet(true);
- }
- }
- }
-
-}
-
+/**\r
+ * Autogenerated by Thrift Compiler (0.9.3)\r
+ *\r
+ * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING\r
+ * @generated\r
+ */\r
+package org.opendaylight.netvirt.bgpmanager.thrift.gen;\r
+\r
+import org.apache.thrift.scheme.IScheme;\r
+import org.apache.thrift.scheme.SchemeFactory;\r
+import org.apache.thrift.scheme.StandardScheme;\r
+\r
+import org.apache.thrift.scheme.TupleScheme;\r
+import org.apache.thrift.protocol.TTupleProtocol;\r
+import org.apache.thrift.protocol.TProtocolException;\r
+import org.apache.thrift.EncodingUtils;\r
+import org.apache.thrift.TException;\r
+import org.apache.thrift.async.AsyncMethodCallback;\r
+import org.apache.thrift.server.AbstractNonblockingServer.*;\r
+import java.util.List;\r
+import java.util.ArrayList;\r
+import java.util.Map;\r
+import java.util.HashMap;\r
+import java.util.EnumMap;\r
+import java.util.Set;\r
+import java.util.HashSet;\r
+import java.util.EnumSet;\r
+import java.util.Collections;\r
+import java.util.BitSet;\r
+import java.nio.ByteBuffer;\r
+import java.util.Arrays;\r
+import javax.annotation.Generated;\r
+import org.slf4j.Logger;\r
+import org.slf4j.LoggerFactory;\r
+\r
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"})\r
+@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)", date = "2018-04-09")\r
+public class Update implements org.apache.thrift.TBase<Update, Update._Fields>, java.io.Serializable, Cloneable, Comparable<Update> {\r
+ private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("Update");\r
+\r
+ private static final org.apache.thrift.protocol.TField TYPE_FIELD_DESC = new org.apache.thrift.protocol.TField("type", org.apache.thrift.protocol.TType.I32, (short)1);\r
+ private static final org.apache.thrift.protocol.TField RESERVED_FIELD_DESC = new org.apache.thrift.protocol.TField("reserved", org.apache.thrift.protocol.TType.I32, (short)2);\r
+ private static final org.apache.thrift.protocol.TField PREFIXLEN_FIELD_DESC = new org.apache.thrift.protocol.TField("prefixlen", org.apache.thrift.protocol.TType.I32, (short)3);\r
+ private static final org.apache.thrift.protocol.TField L3LABEL_FIELD_DESC = new org.apache.thrift.protocol.TField("l3label", org.apache.thrift.protocol.TType.I32, (short)4);\r
+ private static final org.apache.thrift.protocol.TField L2LABEL_FIELD_DESC = new org.apache.thrift.protocol.TField("l2label", org.apache.thrift.protocol.TType.I32, (short)5);\r
+ private static final org.apache.thrift.protocol.TField ETHTAG_FIELD_DESC = new org.apache.thrift.protocol.TField("ethtag", org.apache.thrift.protocol.TType.I32, (short)6);\r
+ private static final org.apache.thrift.protocol.TField ESI_FIELD_DESC = new org.apache.thrift.protocol.TField("esi", org.apache.thrift.protocol.TType.STRING, (short)7);\r
+ private static final org.apache.thrift.protocol.TField MACADDRESS_FIELD_DESC = new org.apache.thrift.protocol.TField("macaddress", org.apache.thrift.protocol.TType.STRING, (short)8);\r
+ private static final org.apache.thrift.protocol.TField RD_FIELD_DESC = new org.apache.thrift.protocol.TField("rd", org.apache.thrift.protocol.TType.STRING, (short)9);\r
+ private static final org.apache.thrift.protocol.TField PREFIX_FIELD_DESC = new org.apache.thrift.protocol.TField("prefix", org.apache.thrift.protocol.TType.STRING, (short)10);\r
+ private static final org.apache.thrift.protocol.TField NEXTHOP_FIELD_DESC = new org.apache.thrift.protocol.TField("nexthop", org.apache.thrift.protocol.TType.STRING, (short)11);\r
+ private static final org.apache.thrift.protocol.TField ROUTERMAC_FIELD_DESC = new org.apache.thrift.protocol.TField("routermac", org.apache.thrift.protocol.TType.STRING, (short)12);\r
+\r
+ private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();\r
+ static {\r
+ schemes.put(StandardScheme.class, new UpdateStandardSchemeFactory());\r
+ schemes.put(TupleScheme.class, new UpdateTupleSchemeFactory());\r
+ }\r
+\r
+ public int type; // required\r
+ public int reserved; // required\r
+ public int prefixlen; // required\r
+ public int l3label; // required\r
+ public int l2label; // required\r
+ public int ethtag; // required\r
+ public String esi; // required\r
+ public String macaddress; // required\r
+ public String rd; // required\r
+ public String prefix; // required\r
+ public String nexthop; // required\r
+ public String routermac; // required\r
+\r
+ /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */\r
+ public enum _Fields implements org.apache.thrift.TFieldIdEnum {\r
+ TYPE((short)1, "type"),\r
+ RESERVED((short)2, "reserved"),\r
+ PREFIXLEN((short)3, "prefixlen"),\r
+ L3LABEL((short)4, "l3label"),\r
+ L2LABEL((short)5, "l2label"),\r
+ ETHTAG((short)6, "ethtag"),\r
+ ESI((short)7, "esi"),\r
+ MACADDRESS((short)8, "macaddress"),\r
+ RD((short)9, "rd"),\r
+ PREFIX((short)10, "prefix"),\r
+ NEXTHOP((short)11, "nexthop"),\r
+ ROUTERMAC((short)12, "routermac");\r
+\r
+ private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();\r
+\r
+ static {\r
+ for (_Fields field : EnumSet.allOf(_Fields.class)) {\r
+ byName.put(field.getFieldName(), field);\r
+ }\r
+ }\r
+\r
+ /**\r
+ * Find the _Fields constant that matches fieldId, or null if its not found.\r
+ */\r
+ public static _Fields findByThriftId(int fieldId) {\r
+ switch(fieldId) {\r
+ case 1: // TYPE\r
+ return TYPE;\r
+ case 2: // RESERVED\r
+ return RESERVED;\r
+ case 3: // PREFIXLEN\r
+ return PREFIXLEN;\r
+ case 4: // L3LABEL\r
+ return L3LABEL;\r
+ case 5: // L2LABEL\r
+ return L2LABEL;\r
+ case 6: // ETHTAG\r
+ return ETHTAG;\r
+ case 7: // ESI\r
+ return ESI;\r
+ case 8: // MACADDRESS\r
+ return MACADDRESS;\r
+ case 9: // RD\r
+ return RD;\r
+ case 10: // PREFIX\r
+ return PREFIX;\r
+ case 11: // NEXTHOP\r
+ return NEXTHOP;\r
+ case 12: // ROUTERMAC\r
+ return ROUTERMAC;\r
+ default:\r
+ return null;\r
+ }\r
+ }\r
+\r
+ /**\r
+ * Find the _Fields constant that matches fieldId, throwing an exception\r
+ * if it is not found.\r
+ */\r
+ public static _Fields findByThriftIdOrThrow(int fieldId) {\r
+ _Fields fields = findByThriftId(fieldId);\r
+ if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");\r
+ return fields;\r
+ }\r
+\r
+ /**\r
+ * Find the _Fields constant that matches name, or null if its not found.\r
+ */\r
+ public static _Fields findByName(String name) {\r
+ return byName.get(name);\r
+ }\r
+\r
+ private final short _thriftId;\r
+ private final String _fieldName;\r
+\r
+ _Fields(short thriftId, String fieldName) {\r
+ _thriftId = thriftId;\r
+ _fieldName = fieldName;\r
+ }\r
+\r
+ public short getThriftFieldId() {\r
+ return _thriftId;\r
+ }\r
+\r
+ public String getFieldName() {\r
+ return _fieldName;\r
+ }\r
+ }\r
+\r
+ // isset id assignments\r
+ private static final int __TYPE_ISSET_ID = 0;\r
+ private static final int __RESERVED_ISSET_ID = 1;\r
+ private static final int __PREFIXLEN_ISSET_ID = 2;\r
+ private static final int __L3LABEL_ISSET_ID = 3;\r
+ private static final int __L2LABEL_ISSET_ID = 4;\r
+ private static final int __ETHTAG_ISSET_ID = 5;\r
+ private byte __isset_bitfield = 0;\r
+ public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;\r
+ static {\r
+ Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);\r
+ tmpMap.put(_Fields.TYPE, new org.apache.thrift.meta_data.FieldMetaData("type", org.apache.thrift.TFieldRequirementType.DEFAULT,\r
+ new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I32)));\r
+ tmpMap.put(_Fields.RESERVED, new org.apache.thrift.meta_data.FieldMetaData("reserved", org.apache.thrift.TFieldRequirementType.DEFAULT,\r
+ new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I32)));\r
+ tmpMap.put(_Fields.PREFIXLEN, new org.apache.thrift.meta_data.FieldMetaData("prefixlen", org.apache.thrift.TFieldRequirementType.DEFAULT,\r
+ new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I32)));\r
+ tmpMap.put(_Fields.L3LABEL, new org.apache.thrift.meta_data.FieldMetaData("l3label", org.apache.thrift.TFieldRequirementType.DEFAULT,\r
+ new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I32)));\r
+ tmpMap.put(_Fields.L2LABEL, new org.apache.thrift.meta_data.FieldMetaData("l2label", org.apache.thrift.TFieldRequirementType.DEFAULT,\r
+ new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I32)));\r
+ tmpMap.put(_Fields.ETHTAG, new org.apache.thrift.meta_data.FieldMetaData("ethtag", org.apache.thrift.TFieldRequirementType.DEFAULT,\r
+ new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I32)));\r
+ tmpMap.put(_Fields.ESI, new org.apache.thrift.meta_data.FieldMetaData("esi", org.apache.thrift.TFieldRequirementType.DEFAULT,\r
+ new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));\r
+ tmpMap.put(_Fields.MACADDRESS, new org.apache.thrift.meta_data.FieldMetaData("macaddress", org.apache.thrift.TFieldRequirementType.DEFAULT,\r
+ new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));\r
+ tmpMap.put(_Fields.RD, new org.apache.thrift.meta_data.FieldMetaData("rd", org.apache.thrift.TFieldRequirementType.DEFAULT,\r
+ new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));\r
+ tmpMap.put(_Fields.PREFIX, new org.apache.thrift.meta_data.FieldMetaData("prefix", org.apache.thrift.TFieldRequirementType.DEFAULT,\r
+ new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));\r
+ tmpMap.put(_Fields.NEXTHOP, new org.apache.thrift.meta_data.FieldMetaData("nexthop", org.apache.thrift.TFieldRequirementType.DEFAULT,\r
+ new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));\r
+ tmpMap.put(_Fields.ROUTERMAC, new org.apache.thrift.meta_data.FieldMetaData("routermac", org.apache.thrift.TFieldRequirementType.DEFAULT,\r
+ new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));\r
+ metaDataMap = Collections.unmodifiableMap(tmpMap);\r
+ org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(Update.class, metaDataMap);\r
+ }\r
+\r
+ public Update() {\r
+ }\r
+\r
+ public Update(\r
+ int type,\r
+ int reserved,\r
+ int prefixlen,\r
+ int l3label,\r
+ int l2label,\r
+ int ethtag,\r
+ String esi,\r
+ String macaddress,\r
+ String rd,\r
+ String prefix,\r
+ String nexthop,\r
+ String routermac)\r
+ {\r
+ this();\r
+ this.type = type;\r
+ setTypeIsSet(true);\r
+ this.reserved = reserved;\r
+ setReservedIsSet(true);\r
+ this.prefixlen = prefixlen;\r
+ setPrefixlenIsSet(true);\r
+ this.l3label = l3label;\r
+ setL3labelIsSet(true);\r
+ this.l2label = l2label;\r
+ setL2labelIsSet(true);\r
+ this.ethtag = ethtag;\r
+ setEthtagIsSet(true);\r
+ this.esi = esi;\r
+ this.macaddress = macaddress;\r
+ this.rd = rd;\r
+ this.prefix = prefix;\r
+ this.nexthop = nexthop;\r
+ this.routermac = routermac;\r
+ }\r
+\r
+ /**\r
+ * Performs a deep copy on <i>other</i>.\r
+ */\r
+ public Update(Update other) {\r
+ __isset_bitfield = other.__isset_bitfield;\r
+ this.type = other.type;\r
+ this.reserved = other.reserved;\r
+ this.prefixlen = other.prefixlen;\r
+ this.l3label = other.l3label;\r
+ this.l2label = other.l2label;\r
+ this.ethtag = other.ethtag;\r
+ if (other.isSetEsi()) {\r
+ this.esi = other.esi;\r
+ }\r
+ if (other.isSetMacaddress()) {\r
+ this.macaddress = other.macaddress;\r
+ }\r
+ if (other.isSetRd()) {\r
+ this.rd = other.rd;\r
+ }\r
+ if (other.isSetPrefix()) {\r
+ this.prefix = other.prefix;\r
+ }\r
+ if (other.isSetNexthop()) {\r
+ this.nexthop = other.nexthop;\r
+ }\r
+ if (other.isSetRoutermac()) {\r
+ this.routermac = other.routermac;\r
+ }\r
+ }\r
+\r
+ public Update deepCopy() {\r
+ return new Update(this);\r
+ }\r
+\r
+ @Override\r
+ public void clear() {\r
+ setTypeIsSet(false);\r
+ this.type = 0;\r
+ setReservedIsSet(false);\r
+ this.reserved = 0;\r
+ setPrefixlenIsSet(false);\r
+ this.prefixlen = 0;\r
+ setL3labelIsSet(false);\r
+ this.l3label = 0;\r
+ setL2labelIsSet(false);\r
+ this.l2label = 0;\r
+ setEthtagIsSet(false);\r
+ this.ethtag = 0;\r
+ this.esi = null;\r
+ this.macaddress = null;\r
+ this.rd = null;\r
+ this.prefix = null;\r
+ this.nexthop = null;\r
+ this.routermac = null;\r
+ }\r
+\r
+ public int getType() {\r
+ return this.type;\r
+ }\r
+\r
+ public Update setType(int type) {\r
+ this.type = type;\r
+ setTypeIsSet(true);\r
+ return this;\r
+ }\r
+\r
+ public void unsetType() {\r
+ __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __TYPE_ISSET_ID);\r
+ }\r
+\r
+ /** Returns true if field type is set (has been assigned a value) and false otherwise */\r
+ public boolean isSetType() {\r
+ return EncodingUtils.testBit(__isset_bitfield, __TYPE_ISSET_ID);\r
+ }\r
+\r
+ public void setTypeIsSet(boolean value) {\r
+ __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __TYPE_ISSET_ID, value);\r
+ }\r
+\r
+ public int getReserved() {\r
+ return this.reserved;\r
+ }\r
+\r
+ public Update setReserved(int reserved) {\r
+ this.reserved = reserved;\r
+ setReservedIsSet(true);\r
+ return this;\r
+ }\r
+\r
+ public void unsetReserved() {\r
+ __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __RESERVED_ISSET_ID);\r
+ }\r
+\r
+ /** Returns true if field reserved is set (has been assigned a value) and false otherwise */\r
+ public boolean isSetReserved() {\r
+ return EncodingUtils.testBit(__isset_bitfield, __RESERVED_ISSET_ID);\r
+ }\r
+\r
+ public void setReservedIsSet(boolean value) {\r
+ __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __RESERVED_ISSET_ID, value);\r
+ }\r
+\r
+ public int getPrefixlen() {\r
+ return this.prefixlen;\r
+ }\r
+\r
+ public Update setPrefixlen(int prefixlen) {\r
+ this.prefixlen = prefixlen;\r
+ setPrefixlenIsSet(true);\r
+ return this;\r
+ }\r
+\r
+ public void unsetPrefixlen() {\r
+ __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __PREFIXLEN_ISSET_ID);\r
+ }\r
+\r
+ /** Returns true if field prefixlen is set (has been assigned a value) and false otherwise */\r
+ public boolean isSetPrefixlen() {\r
+ return EncodingUtils.testBit(__isset_bitfield, __PREFIXLEN_ISSET_ID);\r
+ }\r
+\r
+ public void setPrefixlenIsSet(boolean value) {\r
+ __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __PREFIXLEN_ISSET_ID, value);\r
+ }\r
+\r
+ public int getL3label() {\r
+ return this.l3label;\r
+ }\r
+\r
+ public Update setL3label(int l3label) {\r
+ this.l3label = l3label;\r
+ setL3labelIsSet(true);\r
+ return this;\r
+ }\r
+\r
+ public void unsetL3label() {\r
+ __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __L3LABEL_ISSET_ID);\r
+ }\r
+\r
+ /** Returns true if field l3label is set (has been assigned a value) and false otherwise */\r
+ public boolean isSetL3label() {\r
+ return EncodingUtils.testBit(__isset_bitfield, __L3LABEL_ISSET_ID);\r
+ }\r
+\r
+ public void setL3labelIsSet(boolean value) {\r
+ __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __L3LABEL_ISSET_ID, value);\r
+ }\r
+\r
+ public int getL2label() {\r
+ return this.l2label;\r
+ }\r
+\r
+ public Update setL2label(int l2label) {\r
+ this.l2label = l2label;\r
+ setL2labelIsSet(true);\r
+ return this;\r
+ }\r
+\r
+ public void unsetL2label() {\r
+ __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __L2LABEL_ISSET_ID);\r
+ }\r
+\r
+ /** Returns true if field l2label is set (has been assigned a value) and false otherwise */\r
+ public boolean isSetL2label() {\r
+ return EncodingUtils.testBit(__isset_bitfield, __L2LABEL_ISSET_ID);\r
+ }\r
+\r
+ public void setL2labelIsSet(boolean value) {\r
+ __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __L2LABEL_ISSET_ID, value);\r
+ }\r
+\r
+ public int getEthtag() {\r
+ return this.ethtag;\r
+ }\r
+\r
+ public Update setEthtag(int ethtag) {\r
+ this.ethtag = ethtag;\r
+ setEthtagIsSet(true);\r
+ return this;\r
+ }\r
+\r
+ public void unsetEthtag() {\r
+ __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __ETHTAG_ISSET_ID);\r
+ }\r
+\r
+ /** Returns true if field ethtag is set (has been assigned a value) and false otherwise */\r
+ public boolean isSetEthtag() {\r
+ return EncodingUtils.testBit(__isset_bitfield, __ETHTAG_ISSET_ID);\r
+ }\r
+\r
+ public void setEthtagIsSet(boolean value) {\r
+ __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __ETHTAG_ISSET_ID, value);\r
+ }\r
+\r
+ public String getEsi() {\r
+ return this.esi;\r
+ }\r
+\r
+ public Update setEsi(String esi) {\r
+ this.esi = esi;\r
+ return this;\r
+ }\r
+\r
+ public void unsetEsi() {\r
+ this.esi = null;\r
+ }\r
+\r
+ /** Returns true if field esi is set (has been assigned a value) and false otherwise */\r
+ public boolean isSetEsi() {\r
+ return this.esi != null;\r
+ }\r
+\r
+ public void setEsiIsSet(boolean value) {\r
+ if (!value) {\r
+ this.esi = null;\r
+ }\r
+ }\r
+\r
+ public String getMacaddress() {\r
+ return this.macaddress;\r
+ }\r
+\r
+ public Update setMacaddress(String macaddress) {\r
+ this.macaddress = macaddress;\r
+ return this;\r
+ }\r
+\r
+ public void unsetMacaddress() {\r
+ this.macaddress = null;\r
+ }\r
+\r
+ /** Returns true if field macaddress is set (has been assigned a value) and false otherwise */\r
+ public boolean isSetMacaddress() {\r
+ return this.macaddress != null;\r
+ }\r
+\r
+ public void setMacaddressIsSet(boolean value) {\r
+ if (!value) {\r
+ this.macaddress = null;\r
+ }\r
+ }\r
+\r
+ public String getRd() {\r
+ return this.rd;\r
+ }\r
+\r
+ public Update setRd(String rd) {\r
+ this.rd = rd;\r
+ return this;\r
+ }\r
+\r
+ public void unsetRd() {\r
+ this.rd = null;\r
+ }\r
+\r
+ /** Returns true if field rd is set (has been assigned a value) and false otherwise */\r
+ public boolean isSetRd() {\r
+ return this.rd != null;\r
+ }\r
+\r
+ public void setRdIsSet(boolean value) {\r
+ if (!value) {\r
+ this.rd = null;\r
+ }\r
+ }\r
+\r
+ public String getPrefix() {\r
+ return this.prefix;\r
+ }\r
+\r
+ public Update setPrefix(String prefix) {\r
+ this.prefix = prefix;\r
+ return this;\r
+ }\r
+\r
+ public void unsetPrefix() {\r
+ this.prefix = null;\r
+ }\r
+\r
+ /** Returns true if field prefix is set (has been assigned a value) and false otherwise */\r
+ public boolean isSetPrefix() {\r
+ return this.prefix != null;\r
+ }\r
+\r
+ public void setPrefixIsSet(boolean value) {\r
+ if (!value) {\r
+ this.prefix = null;\r
+ }\r
+ }\r
+\r
+ public String getNexthop() {\r
+ return this.nexthop;\r
+ }\r
+\r
+ public Update setNexthop(String nexthop) {\r
+ this.nexthop = nexthop;\r
+ return this;\r
+ }\r
+\r
+ public void unsetNexthop() {\r
+ this.nexthop = null;\r
+ }\r
+\r
+ /** Returns true if field nexthop is set (has been assigned a value) and false otherwise */\r
+ public boolean isSetNexthop() {\r
+ return this.nexthop != null;\r
+ }\r
+\r
+ public void setNexthopIsSet(boolean value) {\r
+ if (!value) {\r
+ this.nexthop = null;\r
+ }\r
+ }\r
+\r
+ public String getRoutermac() {\r
+ return this.routermac;\r
+ }\r
+\r
+ public Update setRoutermac(String routermac) {\r
+ this.routermac = routermac;\r
+ return this;\r
+ }\r
+\r
+ public void unsetRoutermac() {\r
+ this.routermac = null;\r
+ }\r
+\r
+ /** Returns true if field routermac is set (has been assigned a value) and false otherwise */\r
+ public boolean isSetRoutermac() {\r
+ return this.routermac != null;\r
+ }\r
+\r
+ public void setRoutermacIsSet(boolean value) {\r
+ if (!value) {\r
+ this.routermac = null;\r
+ }\r
+ }\r
+\r
+ public void setFieldValue(_Fields field, Object value) {\r
+ switch (field) {\r
+ case TYPE:\r
+ if (value == null) {\r
+ unsetType();\r
+ } else {\r
+ setType((Integer)value);\r
+ }\r
+ break;\r
+\r
+ case RESERVED:\r
+ if (value == null) {\r
+ unsetReserved();\r
+ } else {\r
+ setReserved((Integer)value);\r
+ }\r
+ break;\r
+\r
+ case PREFIXLEN:\r
+ if (value == null) {\r
+ unsetPrefixlen();\r
+ } else {\r
+ setPrefixlen((Integer)value);\r
+ }\r
+ break;\r
+\r
+ case L3LABEL:\r
+ if (value == null) {\r
+ unsetL3label();\r
+ } else {\r
+ setL3label((Integer)value);\r
+ }\r
+ break;\r
+\r
+ case L2LABEL:\r
+ if (value == null) {\r
+ unsetL2label();\r
+ } else {\r
+ setL2label((Integer)value);\r
+ }\r
+ break;\r
+\r
+ case ETHTAG:\r
+ if (value == null) {\r
+ unsetEthtag();\r
+ } else {\r
+ setEthtag((Integer)value);\r
+ }\r
+ break;\r
+\r
+ case ESI:\r
+ if (value == null) {\r
+ unsetEsi();\r
+ } else {\r
+ setEsi((String)value);\r
+ }\r
+ break;\r
+\r
+ case MACADDRESS:\r
+ if (value == null) {\r
+ unsetMacaddress();\r
+ } else {\r
+ setMacaddress((String)value);\r
+ }\r
+ break;\r
+\r
+ case RD:\r
+ if (value == null) {\r
+ unsetRd();\r
+ } else {\r
+ setRd((String)value);\r
+ }\r
+ break;\r
+\r
+ case PREFIX:\r
+ if (value == null) {\r
+ unsetPrefix();\r
+ } else {\r
+ setPrefix((String)value);\r
+ }\r
+ break;\r
+\r
+ case NEXTHOP:\r
+ if (value == null) {\r
+ unsetNexthop();\r
+ } else {\r
+ setNexthop((String)value);\r
+ }\r
+ break;\r
+\r
+ case ROUTERMAC:\r
+ if (value == null) {\r
+ unsetRoutermac();\r
+ } else {\r
+ setRoutermac((String)value);\r
+ }\r
+ break;\r
+\r
+ }\r
+ }\r
+\r
+ public Object getFieldValue(_Fields field) {\r
+ switch (field) {\r
+ case TYPE:\r
+ return getType();\r
+\r
+ case RESERVED:\r
+ return getReserved();\r
+\r
+ case PREFIXLEN:\r
+ return getPrefixlen();\r
+\r
+ case L3LABEL:\r
+ return getL3label();\r
+\r
+ case L2LABEL:\r
+ return getL2label();\r
+\r
+ case ETHTAG:\r
+ return getEthtag();\r
+\r
+ case ESI:\r
+ return getEsi();\r
+\r
+ case MACADDRESS:\r
+ return getMacaddress();\r
+\r
+ case RD:\r
+ return getRd();\r
+\r
+ case PREFIX:\r
+ return getPrefix();\r
+\r
+ case NEXTHOP:\r
+ return getNexthop();\r
+\r
+ case ROUTERMAC:\r
+ return getRoutermac();\r
+\r
+ }\r
+ throw new IllegalStateException();\r
+ }\r
+\r
+ /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */\r
+ public boolean isSet(_Fields field) {\r
+ if (field == null) {\r
+ throw new IllegalArgumentException();\r
+ }\r
+\r
+ switch (field) {\r
+ case TYPE:\r
+ return isSetType();\r
+ case RESERVED:\r
+ return isSetReserved();\r
+ case PREFIXLEN:\r
+ return isSetPrefixlen();\r
+ case L3LABEL:\r
+ return isSetL3label();\r
+ case L2LABEL:\r
+ return isSetL2label();\r
+ case ETHTAG:\r
+ return isSetEthtag();\r
+ case ESI:\r
+ return isSetEsi();\r
+ case MACADDRESS:\r
+ return isSetMacaddress();\r
+ case RD:\r
+ return isSetRd();\r
+ case PREFIX:\r
+ return isSetPrefix();\r
+ case NEXTHOP:\r
+ return isSetNexthop();\r
+ case ROUTERMAC:\r
+ return isSetRoutermac();\r
+ }\r
+ throw new IllegalStateException();\r
+ }\r
+\r
+ @Override\r
+ public boolean equals(Object that) {\r
+ if (that == null)\r
+ return false;\r
+ if (that instanceof Update)\r
+ return this.equals((Update)that);\r
+ return false;\r
+ }\r
+\r
+ public boolean equals(Update that) {\r
+ if (that == null)\r
+ return false;\r
+\r
+ boolean this_present_type = true;\r
+ boolean that_present_type = true;\r
+ if (this_present_type || that_present_type) {\r
+ if (!(this_present_type && that_present_type))\r
+ return false;\r
+ if (this.type != that.type)\r
+ return false;\r
+ }\r
+\r
+ boolean this_present_reserved = true;\r
+ boolean that_present_reserved = true;\r
+ if (this_present_reserved || that_present_reserved) {\r
+ if (!(this_present_reserved && that_present_reserved))\r
+ return false;\r
+ if (this.reserved != that.reserved)\r
+ return false;\r
+ }\r
+\r
+ boolean this_present_prefixlen = true;\r
+ boolean that_present_prefixlen = true;\r
+ if (this_present_prefixlen || that_present_prefixlen) {\r
+ if (!(this_present_prefixlen && that_present_prefixlen))\r
+ return false;\r
+ if (this.prefixlen != that.prefixlen)\r
+ return false;\r
+ }\r
+\r
+ boolean this_present_l3label = true;\r
+ boolean that_present_l3label = true;\r
+ if (this_present_l3label || that_present_l3label) {\r
+ if (!(this_present_l3label && that_present_l3label))\r
+ return false;\r
+ if (this.l3label != that.l3label)\r
+ return false;\r
+ }\r
+\r
+ boolean this_present_l2label = true;\r
+ boolean that_present_l2label = true;\r
+ if (this_present_l2label || that_present_l2label) {\r
+ if (!(this_present_l2label && that_present_l2label))\r
+ return false;\r
+ if (this.l2label != that.l2label)\r
+ return false;\r
+ }\r
+\r
+ boolean this_present_ethtag = true;\r
+ boolean that_present_ethtag = true;\r
+ if (this_present_ethtag || that_present_ethtag) {\r
+ if (!(this_present_ethtag && that_present_ethtag))\r
+ return false;\r
+ if (this.ethtag != that.ethtag)\r
+ return false;\r
+ }\r
+\r
+ boolean this_present_esi = true && this.isSetEsi();\r
+ boolean that_present_esi = true && that.isSetEsi();\r
+ if (this_present_esi || that_present_esi) {\r
+ if (!(this_present_esi && that_present_esi))\r
+ return false;\r
+ if (!this.esi.equals(that.esi))\r
+ return false;\r
+ }\r
+\r
+ boolean this_present_macaddress = true && this.isSetMacaddress();\r
+ boolean that_present_macaddress = true && that.isSetMacaddress();\r
+ if (this_present_macaddress || that_present_macaddress) {\r
+ if (!(this_present_macaddress && that_present_macaddress))\r
+ return false;\r
+ if (!this.macaddress.equals(that.macaddress))\r
+ return false;\r
+ }\r
+\r
+ boolean this_present_rd = true && this.isSetRd();\r
+ boolean that_present_rd = true && that.isSetRd();\r
+ if (this_present_rd || that_present_rd) {\r
+ if (!(this_present_rd && that_present_rd))\r
+ return false;\r
+ if (!this.rd.equals(that.rd))\r
+ return false;\r
+ }\r
+\r
+ boolean this_present_prefix = true && this.isSetPrefix();\r
+ boolean that_present_prefix = true && that.isSetPrefix();\r
+ if (this_present_prefix || that_present_prefix) {\r
+ if (!(this_present_prefix && that_present_prefix))\r
+ return false;\r
+ if (!this.prefix.equals(that.prefix))\r
+ return false;\r
+ }\r
+\r
+ boolean this_present_nexthop = true && this.isSetNexthop();\r
+ boolean that_present_nexthop = true && that.isSetNexthop();\r
+ if (this_present_nexthop || that_present_nexthop) {\r
+ if (!(this_present_nexthop && that_present_nexthop))\r
+ return false;\r
+ if (!this.nexthop.equals(that.nexthop))\r
+ return false;\r
+ }\r
+\r
+ boolean this_present_routermac = true && this.isSetRoutermac();\r
+ boolean that_present_routermac = true && that.isSetRoutermac();\r
+ if (this_present_routermac || that_present_routermac) {\r
+ if (!(this_present_routermac && that_present_routermac))\r
+ return false;\r
+ if (!this.routermac.equals(that.routermac))\r
+ return false;\r
+ }\r
+\r
+ return true;\r
+ }\r
+\r
+ @Override\r
+ public int hashCode() {\r
+ List<Object> list = new ArrayList<Object>();\r
+\r
+ boolean present_type = true;\r
+ list.add(present_type);\r
+ if (present_type)\r
+ list.add(type);\r
+\r
+ boolean present_reserved = true;\r
+ list.add(present_reserved);\r
+ if (present_reserved)\r
+ list.add(reserved);\r
+\r
+ boolean present_prefixlen = true;\r
+ list.add(present_prefixlen);\r
+ if (present_prefixlen)\r
+ list.add(prefixlen);\r
+\r
+ boolean present_l3label = true;\r
+ list.add(present_l3label);\r
+ if (present_l3label)\r
+ list.add(l3label);\r
+\r
+ boolean present_l2label = true;\r
+ list.add(present_l2label);\r
+ if (present_l2label)\r
+ list.add(l2label);\r
+\r
+ boolean present_ethtag = true;\r
+ list.add(present_ethtag);\r
+ if (present_ethtag)\r
+ list.add(ethtag);\r
+\r
+ boolean present_esi = true && (isSetEsi());\r
+ list.add(present_esi);\r
+ if (present_esi)\r
+ list.add(esi);\r
+\r
+ boolean present_macaddress = true && (isSetMacaddress());\r
+ list.add(present_macaddress);\r
+ if (present_macaddress)\r
+ list.add(macaddress);\r
+\r
+ boolean present_rd = true && (isSetRd());\r
+ list.add(present_rd);\r
+ if (present_rd)\r
+ list.add(rd);\r
+\r
+ boolean present_prefix = true && (isSetPrefix());\r
+ list.add(present_prefix);\r
+ if (present_prefix)\r
+ list.add(prefix);\r
+\r
+ boolean present_nexthop = true && (isSetNexthop());\r
+ list.add(present_nexthop);\r
+ if (present_nexthop)\r
+ list.add(nexthop);\r
+\r
+ boolean present_routermac = true && (isSetRoutermac());\r
+ list.add(present_routermac);\r
+ if (present_routermac)\r
+ list.add(routermac);\r
+\r
+ return list.hashCode();\r
+ }\r
+\r
+ @Override\r
+ public int compareTo(Update other) {\r
+ if (!getClass().equals(other.getClass())) {\r
+ return getClass().getName().compareTo(other.getClass().getName());\r
+ }\r
+\r
+ int lastComparison = 0;\r
+\r
+ lastComparison = Boolean.valueOf(isSetType()).compareTo(other.isSetType());\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ if (isSetType()) {\r
+ lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.type, other.type);\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ }\r
+ lastComparison = Boolean.valueOf(isSetReserved()).compareTo(other.isSetReserved());\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ if (isSetReserved()) {\r
+ lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.reserved, other.reserved);\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ }\r
+ lastComparison = Boolean.valueOf(isSetPrefixlen()).compareTo(other.isSetPrefixlen());\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ if (isSetPrefixlen()) {\r
+ lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.prefixlen, other.prefixlen);\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ }\r
+ lastComparison = Boolean.valueOf(isSetL3label()).compareTo(other.isSetL3label());\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ if (isSetL3label()) {\r
+ lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.l3label, other.l3label);\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ }\r
+ lastComparison = Boolean.valueOf(isSetL2label()).compareTo(other.isSetL2label());\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ if (isSetL2label()) {\r
+ lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.l2label, other.l2label);\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ }\r
+ lastComparison = Boolean.valueOf(isSetEthtag()).compareTo(other.isSetEthtag());\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ if (isSetEthtag()) {\r
+ lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.ethtag, other.ethtag);\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ }\r
+ lastComparison = Boolean.valueOf(isSetEsi()).compareTo(other.isSetEsi());\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ if (isSetEsi()) {\r
+ lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.esi, other.esi);\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ }\r
+ lastComparison = Boolean.valueOf(isSetMacaddress()).compareTo(other.isSetMacaddress());\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ if (isSetMacaddress()) {\r
+ lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.macaddress, other.macaddress);\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ }\r
+ lastComparison = Boolean.valueOf(isSetRd()).compareTo(other.isSetRd());\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ if (isSetRd()) {\r
+ lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.rd, other.rd);\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ }\r
+ lastComparison = Boolean.valueOf(isSetPrefix()).compareTo(other.isSetPrefix());\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ if (isSetPrefix()) {\r
+ lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.prefix, other.prefix);\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ }\r
+ lastComparison = Boolean.valueOf(isSetNexthop()).compareTo(other.isSetNexthop());\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ if (isSetNexthop()) {\r
+ lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.nexthop, other.nexthop);\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ }\r
+ lastComparison = Boolean.valueOf(isSetRoutermac()).compareTo(other.isSetRoutermac());\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ if (isSetRoutermac()) {\r
+ lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.routermac, other.routermac);\r
+ if (lastComparison != 0) {\r
+ return lastComparison;\r
+ }\r
+ }\r
+ return 0;\r
+ }\r
+\r
+ public _Fields fieldForId(int fieldId) {\r
+ return _Fields.findByThriftId(fieldId);\r
+ }\r
+\r
+ public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {\r
+ schemes.get(iprot.getScheme()).getScheme().read(iprot, this);\r
+ }\r
+\r
+ public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {\r
+ schemes.get(oprot.getScheme()).getScheme().write(oprot, this);\r
+ }\r
+\r
+ @Override\r
+ public String toString() {\r
+ StringBuilder sb = new StringBuilder("Update(");\r
+ boolean first = true;\r
+\r
+ sb.append("type:");\r
+ sb.append(this.type);\r
+ first = false;\r
+ if (!first) sb.append(", ");\r
+ sb.append("reserved:");\r
+ sb.append(this.reserved);\r
+ first = false;\r
+ if (!first) sb.append(", ");\r
+ sb.append("prefixlen:");\r
+ sb.append(this.prefixlen);\r
+ first = false;\r
+ if (!first) sb.append(", ");\r
+ sb.append("l3label:");\r
+ sb.append(this.l3label);\r
+ first = false;\r
+ if (!first) sb.append(", ");\r
+ sb.append("l2label:");\r
+ sb.append(this.l2label);\r
+ first = false;\r
+ if (!first) sb.append(", ");\r
+ sb.append("ethtag:");\r
+ sb.append(this.ethtag);\r
+ first = false;\r
+ if (!first) sb.append(", ");\r
+ sb.append("esi:");\r
+ if (this.esi == null) {\r
+ sb.append("null");\r
+ } else {\r
+ sb.append(this.esi);\r
+ }\r
+ first = false;\r
+ if (!first) sb.append(", ");\r
+ sb.append("macaddress:");\r
+ if (this.macaddress == null) {\r
+ sb.append("null");\r
+ } else {\r
+ sb.append(this.macaddress);\r
+ }\r
+ first = false;\r
+ if (!first) sb.append(", ");\r
+ sb.append("rd:");\r
+ if (this.rd == null) {\r
+ sb.append("null");\r
+ } else {\r
+ sb.append(this.rd);\r
+ }\r
+ first = false;\r
+ if (!first) sb.append(", ");\r
+ sb.append("prefix:");\r
+ if (this.prefix == null) {\r
+ sb.append("null");\r
+ } else {\r
+ sb.append(this.prefix);\r
+ }\r
+ first = false;\r
+ if (!first) sb.append(", ");\r
+ sb.append("nexthop:");\r
+ if (this.nexthop == null) {\r
+ sb.append("null");\r
+ } else {\r
+ sb.append(this.nexthop);\r
+ }\r
+ first = false;\r
+ if (!first) sb.append(", ");\r
+ sb.append("routermac:");\r
+ if (this.routermac == null) {\r
+ sb.append("null");\r
+ } else {\r
+ sb.append(this.routermac);\r
+ }\r
+ first = false;\r
+ sb.append(")");\r
+ return sb.toString();\r
+ }\r
+\r
+ public void validate() throws org.apache.thrift.TException {\r
+ // check for required fields\r
+ // check for sub-struct validity\r
+ }\r
+\r
+ private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {\r
+ try {\r
+ write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));\r
+ } catch (org.apache.thrift.TException te) {\r
+ throw new java.io.IOException(te);\r
+ }\r
+ }\r
+\r
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {\r
+ try {\r
+ // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.\r
+ __isset_bitfield = 0;\r
+ read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));\r
+ } catch (org.apache.thrift.TException te) {\r
+ throw new java.io.IOException(te);\r
+ }\r
+ }\r
+\r
+ private static class UpdateStandardSchemeFactory implements SchemeFactory {\r
+ public UpdateStandardScheme getScheme() {\r
+ return new UpdateStandardScheme();\r
+ }\r
+ }\r
+\r
+ private static class UpdateStandardScheme extends StandardScheme<Update> {\r
+\r
+ public void read(org.apache.thrift.protocol.TProtocol iprot, Update struct) throws org.apache.thrift.TException {\r
+ org.apache.thrift.protocol.TField schemeField;\r
+ iprot.readStructBegin();\r
+ while (true)\r
+ {\r
+ schemeField = iprot.readFieldBegin();\r
+ if (schemeField.type == org.apache.thrift.protocol.TType.STOP) {\r
+ break;\r
+ }\r
+ switch (schemeField.id) {\r
+ case 1: // TYPE\r
+ if (schemeField.type == org.apache.thrift.protocol.TType.I32) {\r
+ struct.type = iprot.readI32();\r
+ struct.setTypeIsSet(true);\r
+ } else {\r
+ org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);\r
+ }\r
+ break;\r
+ case 2: // RESERVED\r
+ if (schemeField.type == org.apache.thrift.protocol.TType.I32) {\r
+ struct.reserved = iprot.readI32();\r
+ struct.setReservedIsSet(true);\r
+ } else {\r
+ org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);\r
+ }\r
+ break;\r
+ case 3: // PREFIXLEN\r
+ if (schemeField.type == org.apache.thrift.protocol.TType.I32) {\r
+ struct.prefixlen = iprot.readI32();\r
+ struct.setPrefixlenIsSet(true);\r
+ } else {\r
+ org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);\r
+ }\r
+ break;\r
+ case 4: // L3LABEL\r
+ if (schemeField.type == org.apache.thrift.protocol.TType.I32) {\r
+ struct.l3label = iprot.readI32();\r
+ struct.setL3labelIsSet(true);\r
+ } else {\r
+ org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);\r
+ }\r
+ break;\r
+ case 5: // L2LABEL\r
+ if (schemeField.type == org.apache.thrift.protocol.TType.I32) {\r
+ struct.l2label = iprot.readI32();\r
+ struct.setL2labelIsSet(true);\r
+ } else {\r
+ org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);\r
+ }\r
+ break;\r
+ case 6: // ETHTAG\r
+ if (schemeField.type == org.apache.thrift.protocol.TType.I32) {\r
+ struct.ethtag = iprot.readI32();\r
+ struct.setEthtagIsSet(true);\r
+ } else {\r
+ org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);\r
+ }\r
+ break;\r
+ case 7: // ESI\r
+ if (schemeField.type == org.apache.thrift.protocol.TType.STRING) {\r
+ struct.esi = iprot.readString();\r
+ struct.setEsiIsSet(true);\r
+ } else {\r
+ org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);\r
+ }\r
+ break;\r
+ case 8: // MACADDRESS\r
+ if (schemeField.type == org.apache.thrift.protocol.TType.STRING) {\r
+ struct.macaddress = iprot.readString();\r
+ struct.setMacaddressIsSet(true);\r
+ } else {\r
+ org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);\r
+ }\r
+ break;\r
+ case 9: // RD\r
+ if (schemeField.type == org.apache.thrift.protocol.TType.STRING) {\r
+ struct.rd = iprot.readString();\r
+ struct.setRdIsSet(true);\r
+ } else {\r
+ org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);\r
+ }\r
+ break;\r
+ case 10: // PREFIX\r
+ if (schemeField.type == org.apache.thrift.protocol.TType.STRING) {\r
+ struct.prefix = iprot.readString();\r
+ struct.setPrefixIsSet(true);\r
+ } else {\r
+ org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);\r
+ }\r
+ break;\r
+ case 11: // NEXTHOP\r
+ if (schemeField.type == org.apache.thrift.protocol.TType.STRING) {\r
+ struct.nexthop = iprot.readString();\r
+ struct.setNexthopIsSet(true);\r
+ } else {\r
+ org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);\r
+ }\r
+ break;\r
+ case 12: // ROUTERMAC\r
+ if (schemeField.type == org.apache.thrift.protocol.TType.STRING) {\r
+ struct.routermac = iprot.readString();\r
+ struct.setRoutermacIsSet(true);\r
+ } else {\r
+ org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);\r
+ }\r
+ break;\r
+ default:\r
+ org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);\r
+ }\r
+ iprot.readFieldEnd();\r
+ }\r
+ iprot.readStructEnd();\r
+\r
+ // check for required fields of primitive type, which can't be checked in the validate method\r
+ struct.validate();\r
+ }\r
+\r
+ public void write(org.apache.thrift.protocol.TProtocol oprot, Update struct) throws org.apache.thrift.TException {\r
+ struct.validate();\r
+\r
+ oprot.writeStructBegin(STRUCT_DESC);\r
+ oprot.writeFieldBegin(TYPE_FIELD_DESC);\r
+ oprot.writeI32(struct.type);\r
+ oprot.writeFieldEnd();\r
+ oprot.writeFieldBegin(RESERVED_FIELD_DESC);\r
+ oprot.writeI32(struct.reserved);\r
+ oprot.writeFieldEnd();\r
+ oprot.writeFieldBegin(PREFIXLEN_FIELD_DESC);\r
+ oprot.writeI32(struct.prefixlen);\r
+ oprot.writeFieldEnd();\r
+ oprot.writeFieldBegin(L3LABEL_FIELD_DESC);\r
+ oprot.writeI32(struct.l3label);\r
+ oprot.writeFieldEnd();\r
+ oprot.writeFieldBegin(L2LABEL_FIELD_DESC);\r
+ oprot.writeI32(struct.l2label);\r
+ oprot.writeFieldEnd();\r
+ oprot.writeFieldBegin(ETHTAG_FIELD_DESC);\r
+ oprot.writeI32(struct.ethtag);\r
+ oprot.writeFieldEnd();\r
+ if (struct.esi != null) {\r
+ oprot.writeFieldBegin(ESI_FIELD_DESC);\r
+ oprot.writeString(struct.esi);\r
+ oprot.writeFieldEnd();\r
+ }\r
+ if (struct.macaddress != null) {\r
+ oprot.writeFieldBegin(MACADDRESS_FIELD_DESC);\r
+ oprot.writeString(struct.macaddress);\r
+ oprot.writeFieldEnd();\r
+ }\r
+ if (struct.rd != null) {\r
+ oprot.writeFieldBegin(RD_FIELD_DESC);\r
+ oprot.writeString(struct.rd);\r
+ oprot.writeFieldEnd();\r
+ }\r
+ if (struct.prefix != null) {\r
+ oprot.writeFieldBegin(PREFIX_FIELD_DESC);\r
+ oprot.writeString(struct.prefix);\r
+ oprot.writeFieldEnd();\r
+ }\r
+ if (struct.nexthop != null) {\r
+ oprot.writeFieldBegin(NEXTHOP_FIELD_DESC);\r
+ oprot.writeString(struct.nexthop);\r
+ oprot.writeFieldEnd();\r
+ }\r
+ if (struct.routermac != null) {\r
+ oprot.writeFieldBegin(ROUTERMAC_FIELD_DESC);\r
+ oprot.writeString(struct.routermac);\r
+ oprot.writeFieldEnd();\r
+ }\r
+ oprot.writeFieldStop();\r
+ oprot.writeStructEnd();\r
+ }\r
+\r
+ }\r
+\r
+ private static class UpdateTupleSchemeFactory implements SchemeFactory {\r
+ public UpdateTupleScheme getScheme() {\r
+ return new UpdateTupleScheme();\r
+ }\r
+ }\r
+\r
+ private static class UpdateTupleScheme extends TupleScheme<Update> {\r
+\r
+ @Override\r
+ public void write(org.apache.thrift.protocol.TProtocol prot, Update struct) throws org.apache.thrift.TException {\r
+ TTupleProtocol oprot = (TTupleProtocol) prot;\r
+ BitSet optionals = new BitSet();\r
+ if (struct.isSetType()) {\r
+ optionals.set(0);\r
+ }\r
+ if (struct.isSetReserved()) {\r
+ optionals.set(1);\r
+ }\r
+ if (struct.isSetPrefixlen()) {\r
+ optionals.set(2);\r
+ }\r
+ if (struct.isSetL3label()) {\r
+ optionals.set(3);\r
+ }\r
+ if (struct.isSetL2label()) {\r
+ optionals.set(4);\r
+ }\r
+ if (struct.isSetEthtag()) {\r
+ optionals.set(5);\r
+ }\r
+ if (struct.isSetEsi()) {\r
+ optionals.set(6);\r
+ }\r
+ if (struct.isSetMacaddress()) {\r
+ optionals.set(7);\r
+ }\r
+ if (struct.isSetRd()) {\r
+ optionals.set(8);\r
+ }\r
+ if (struct.isSetPrefix()) {\r
+ optionals.set(9);\r
+ }\r
+ if (struct.isSetNexthop()) {\r
+ optionals.set(10);\r
+ }\r
+ if (struct.isSetRoutermac()) {\r
+ optionals.set(11);\r
+ }\r
+ oprot.writeBitSet(optionals, 12);\r
+ if (struct.isSetType()) {\r
+ oprot.writeI32(struct.type);\r
+ }\r
+ if (struct.isSetReserved()) {\r
+ oprot.writeI32(struct.reserved);\r
+ }\r
+ if (struct.isSetPrefixlen()) {\r
+ oprot.writeI32(struct.prefixlen);\r
+ }\r
+ if (struct.isSetL3label()) {\r
+ oprot.writeI32(struct.l3label);\r
+ }\r
+ if (struct.isSetL2label()) {\r
+ oprot.writeI32(struct.l2label);\r
+ }\r
+ if (struct.isSetEthtag()) {\r
+ oprot.writeI32(struct.ethtag);\r
+ }\r
+ if (struct.isSetEsi()) {\r
+ oprot.writeString(struct.esi);\r
+ }\r
+ if (struct.isSetMacaddress()) {\r
+ oprot.writeString(struct.macaddress);\r
+ }\r
+ if (struct.isSetRd()) {\r
+ oprot.writeString(struct.rd);\r
+ }\r
+ if (struct.isSetPrefix()) {\r
+ oprot.writeString(struct.prefix);\r
+ }\r
+ if (struct.isSetNexthop()) {\r
+ oprot.writeString(struct.nexthop);\r
+ }\r
+ if (struct.isSetRoutermac()) {\r
+ oprot.writeString(struct.routermac);\r
+ }\r
+ }\r
+\r
+ @Override\r
+ public void read(org.apache.thrift.protocol.TProtocol prot, Update struct) throws org.apache.thrift.TException {\r
+ TTupleProtocol iprot = (TTupleProtocol) prot;\r
+ BitSet incoming = iprot.readBitSet(12);\r
+ if (incoming.get(0)) {\r
+ struct.type = iprot.readI32();\r
+ struct.setTypeIsSet(true);\r
+ }\r
+ if (incoming.get(1)) {\r
+ struct.reserved = iprot.readI32();\r
+ struct.setReservedIsSet(true);\r
+ }\r
+ if (incoming.get(2)) {\r
+ struct.prefixlen = iprot.readI32();\r
+ struct.setPrefixlenIsSet(true);\r
+ }\r
+ if (incoming.get(3)) {\r
+ struct.l3label = iprot.readI32();\r
+ struct.setL3labelIsSet(true);\r
+ }\r
+ if (incoming.get(4)) {\r
+ struct.l2label = iprot.readI32();\r
+ struct.setL2labelIsSet(true);\r
+ }\r
+ if (incoming.get(5)) {\r
+ struct.ethtag = iprot.readI32();\r
+ struct.setEthtagIsSet(true);\r
+ }\r
+ if (incoming.get(6)) {\r
+ struct.esi = iprot.readString();\r
+ struct.setEsiIsSet(true);\r
+ }\r
+ if (incoming.get(7)) {\r
+ struct.macaddress = iprot.readString();\r
+ struct.setMacaddressIsSet(true);\r
+ }\r
+ if (incoming.get(8)) {\r
+ struct.rd = iprot.readString();\r
+ struct.setRdIsSet(true);\r
+ }\r
+ if (incoming.get(9)) {\r
+ struct.prefix = iprot.readString();\r
+ struct.setPrefixIsSet(true);\r
+ }\r
+ if (incoming.get(10)) {\r
+ struct.nexthop = iprot.readString();\r
+ struct.setNexthopIsSet(true);\r
+ }\r
+ if (incoming.get(11)) {\r
+ struct.routermac = iprot.readString();\r
+ struct.setRoutermacIsSet(true);\r
+ }\r
+ }\r
+ }\r
+\r
+}\r
+\r
-/**
- * Autogenerated by Thrift Compiler (0.9.3)
- *
- * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
- * @generated
- */
- package org.opendaylight.netvirt.bgpmanager.thrift.gen;
-import java.util.Map;
-import java.util.HashMap;
-import org.apache.thrift.TEnum;
-
-public enum af_afi implements org.apache.thrift.TEnum {
- AFI_IP(1),
- AFI_IPV6(2),
- AFI_L2VPN(3);
-
- private final int value;
-
- private af_afi(int value) {
- this.value = value;
- }
-
- /**
- * Get the integer value of this enum value, as defined in the Thrift IDL.
- */
- public int getValue() {
- return value;
- }
-
- /**
- * Find a the enum type by its integer value, as defined in the Thrift IDL.
- * @return null if the value is not found.
- */
- public static af_afi findByValue(int value) {
- switch (value) {
- case 1:
- return AFI_IP;
- case 2:
- return AFI_IPV6;
- case 3:
- return AFI_L2VPN;
- default:
- return null;
- }
- }
-}
+/**\r
+ * Autogenerated by Thrift Compiler (0.9.3)\r
+ *\r
+ * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING\r
+ * @generated\r
+ */\r
+package org.opendaylight.netvirt.bgpmanager.thrift.gen;\r
+\r
+import java.util.Map;\r
+import java.util.HashMap;\r
+import org.apache.thrift.TEnum;\r
+\r
+public enum af_afi implements org.apache.thrift.TEnum {\r
+ AFI_IP(1),\r
+ AFI_IPV6(2),\r
+ AFI_L2VPN(3);\r
+\r
+ private final int value;\r
+\r
+ private af_afi(int value) {\r
+ this.value = value;\r
+ }\r
+\r
+ /**\r
+ * Get the integer value of this enum value, as defined in the Thrift IDL.\r
+ */\r
+ public int getValue() {\r
+ return value;\r
+ }\r
+\r
+ /**\r
+ * Find a the enum type by its integer value, as defined in the Thrift IDL.\r
+ * @return null if the value is not found.\r
+ */\r
+ public static af_afi findByValue(int value) {\r
+ switch (value) {\r
+ case 1:\r
+ return AFI_IP;\r
+ case 2:\r
+ return AFI_IPV6;\r
+ case 3:\r
+ return AFI_L2VPN;\r
+ default:\r
+ return null;\r
+ }\r
+ }\r
+}\r
-/**
- * Autogenerated by Thrift Compiler (0.9.3)
- *
- * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
- * @generated
- */
- package org.opendaylight.netvirt.bgpmanager.thrift.gen;
-import java.util.Map;
-import java.util.HashMap;
-import org.apache.thrift.TEnum;
-
-public enum af_safi implements org.apache.thrift.TEnum {
- SAFI_IPV4_LABELED_UNICAST(4),
- SAFI_MPLS_VPN(5),
- SAFI_EVPN(6);
-
- private final int value;
-
- private af_safi(int value) {
- this.value = value;
- }
-
- /**
- * Get the integer value of this enum value, as defined in the Thrift IDL.
- */
- public int getValue() {
- return value;
- }
-
- /**
- * Find a the enum type by its integer value, as defined in the Thrift IDL.
- * @return null if the value is not found.
- */
- public static af_safi findByValue(int value) {
- switch (value) {
- case 4:
- return SAFI_IPV4_LABELED_UNICAST;
- case 5:
- return SAFI_MPLS_VPN;
- case 6:
- return SAFI_EVPN;
- default:
- return null;
- }
- }
-}
+/**\r
+ * Autogenerated by Thrift Compiler (0.9.3)\r
+ *\r
+ * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING\r
+ * @generated\r
+ */\r
+package org.opendaylight.netvirt.bgpmanager.thrift.gen;\r
+\r
+\r
+import java.util.Map;\r
+import java.util.HashMap;\r
+import org.apache.thrift.TEnum;\r
+\r
+public enum af_safi implements org.apache.thrift.TEnum {\r
+ SAFI_IP_LABELED_UNICAST(4),\r
+ SAFI_MPLS_VPN(5),\r
+ SAFI_EVPN(6);\r
+\r
+ private final int value;\r
+\r
+ private af_safi(int value) {\r
+ this.value = value;\r
+ }\r
+\r
+ /**\r
+ * Get the integer value of this enum value, as defined in the Thrift IDL.\r
+ */\r
+ public int getValue() {\r
+ return value;\r
+ }\r
+\r
+ /**\r
+ * Find a the enum type by its integer value, as defined in the Thrift IDL.\r
+ * @return null if the value is not found.\r
+ */\r
+ public static af_safi findByValue(int value) {\r
+ switch (value) {\r
+ case 4:\r
+ return SAFI_IP_LABELED_UNICAST;\r
+ case 5:\r
+ return SAFI_MPLS_VPN;\r
+ case 6:\r
+ return SAFI_EVPN;\r
+ default:\r
+ return null;\r
+ }\r
+ }\r
+}\r
-/**
- * Autogenerated by Thrift Compiler (0.9.3)
- *
- * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
- * @generated
- */
- package org.opendaylight.netvirt.bgpmanager.thrift.gen;
-import java.util.Map;
-import java.util.HashMap;
-import org.apache.thrift.TEnum;
-
-public enum encap_type implements org.apache.thrift.TEnum {
- L2TPV3_OVER_IP(1),
- GRE(2),
- IP_IN_IP(7),
- VXLAN(8),
- MPLS(10);
-
- private final int value;
-
- private encap_type(int value) {
- this.value = value;
- }
-
- /**
- * Get the integer value of this enum value, as defined in the Thrift IDL.
- */
- public int getValue() {
- return value;
- }
-
- /**
- * Find a the enum type by its integer value, as defined in the Thrift IDL.
- * @return null if the value is not found.
- */
- public static encap_type findByValue(int value) {
- switch (value) {
- case 1:
- return L2TPV3_OVER_IP;
- case 2:
- return GRE;
- case 7:
- return IP_IN_IP;
- case 8:
- return VXLAN;
- case 10:
- return MPLS;
- default:
- return null;
- }
- }
-}
+/**\r
+ * Autogenerated by Thrift Compiler (0.9.3)\r
+ *\r
+ * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING\r
+ * @generated\r
+ */\r
+package org.opendaylight.netvirt.bgpmanager.thrift.gen;\r
+\r
+import java.util.Map;\r
+import java.util.HashMap;\r
+import org.apache.thrift.TEnum;\r
+\r
+public enum encap_type implements org.apache.thrift.TEnum {\r
+ L2TPV3_OVER_IP(1),\r
+ GRE(2),\r
+ IP_IN_IP(7),\r
+ VXLAN(8),\r
+ MPLS(10);\r
+\r
+ private final int value;\r
+\r
+ private encap_type(int value) {\r
+ this.value = value;\r
+ }\r
+\r
+ /**\r
+ * Get the integer value of this enum value, as defined in the Thrift IDL.\r
+ */\r
+ public int getValue() {\r
+ return value;\r
+ }\r
+\r
+ /**\r
+ * Find a the enum type by its integer value, as defined in the Thrift IDL.\r
+ * @return null if the value is not found.\r
+ */\r
+ public static encap_type findByValue(int value) {\r
+ switch (value) {\r
+ case 1:\r
+ return L2TPV3_OVER_IP;\r
+ case 2:\r
+ return GRE;\r
+ case 7:\r
+ return IP_IN_IP;\r
+ case 8:\r
+ return VXLAN;\r
+ case 10:\r
+ return MPLS;\r
+ default:\r
+ return null;\r
+ }\r
+ }\r
+}\r
-/**
- * Autogenerated by Thrift Compiler (0.9.3)
- *
- * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
- * @generated
- */
- package org.opendaylight.netvirt.bgpmanager.thrift.gen;
-import java.util.Map;
-import java.util.HashMap;
-import org.apache.thrift.TEnum;
-
-public enum layer_type implements org.apache.thrift.TEnum {
- LAYER_2(1),
- LAYER_3(2);
-
- private final int value;
-
- private layer_type(int value) {
- this.value = value;
- }
-
- /**
- * Get the integer value of this enum value, as defined in the Thrift IDL.
- */
- public int getValue() {
- return value;
- }
-
- /**
- * Find a the enum type by its integer value, as defined in the Thrift IDL.
- * @return null if the value is not found.
- */
- public static layer_type findByValue(int value) {
- switch (value) {
- case 1:
- return LAYER_2;
- case 2:
- return LAYER_3;
- default:
- return null;
- }
- }
-}
+/**\r
+ * Autogenerated by Thrift Compiler (0.9.3)\r
+ *\r
+ * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING\r
+ * @generated\r
+ */\r
+package org.opendaylight.netvirt.bgpmanager.thrift.gen;\r
+\r
+\r
+import java.util.Map;\r
+import java.util.HashMap;\r
+import org.apache.thrift.TEnum;\r
+\r
+public enum layer_type implements org.apache.thrift.TEnum {\r
+ LAYER_2(1),\r
+ LAYER_3(2);\r
+\r
+ private final int value;\r
+\r
+ private layer_type(int value) {\r
+ this.value = value;\r
+ }\r
+\r
+ /**\r
+ * Get the integer value of this enum value, as defined in the Thrift IDL.\r
+ */\r
+ public int getValue() {\r
+ return value;\r
+ }\r
+\r
+ /**\r
+ * Find a the enum type by its integer value, as defined in the Thrift IDL.\r
+ * @return null if the value is not found.\r
+ */\r
+ public static layer_type findByValue(int value) {\r
+ switch (value) {\r
+ case 1:\r
+ return LAYER_2;\r
+ case 2:\r
+ return LAYER_3;\r
+ default:\r
+ return null;\r
+ }\r
+ }\r
+}\r
--- /dev/null
+/**
+ * Autogenerated by Thrift Compiler (0.9.3)
+ *
+ * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
+ * @generated
+ */
+package org.opendaylight.netvirt.bgpmanager.thrift.gen;
+
+import java.util.Map;
+import java.util.HashMap;
+import org.apache.thrift.TEnum;
+
+public enum peer_status_type implements org.apache.thrift.TEnum {
+ PEER_UP(0),
+ PEER_DOWN(1),
+ PEER_UNKNOWN(2),
+ PEER_NOTCONFIGURED(3);
+
+ private final int value;
+
+ private peer_status_type(int value) {
+ this.value = value;
+ }
+
+ /**
+ * Get the integer value of this enum value, as defined in the Thrift IDL.
+ */
+ public int getValue() {
+ return value;
+ }
+
+ /**
+ * Find a the enum type by its integer value, as defined in the Thrift IDL.
+ * @return null if the value is not found.
+ */
+ public static peer_status_type findByValue(int value) {
+ switch (value) {
+ case 0:
+ return PEER_UP;
+ case 1:
+ return PEER_DOWN;
+ case 2:
+ return PEER_UNKNOWN;
+ case 3:
+ return PEER_NOTCONFIGURED;
+ default:
+ return PEER_UNKNOWN;
+ }
+ }
+}
-/**
- * Autogenerated by Thrift Compiler (0.9.3)
- *
- * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
- * @generated
- */
- package org.opendaylight.netvirt.bgpmanager.thrift.gen;
-import java.util.Map;
-import java.util.HashMap;
-import org.apache.thrift.TEnum;
-
-public enum protocol_type implements org.apache.thrift.TEnum {
- PROTOCOL_LU(1),
- PROTOCOL_L3VPN(2),
- PROTOCOL_EVPN(3),
- PROTOCOL_ANY(4);
-
- private final int value;
-
- private protocol_type(int value) {
- this.value = value;
- }
-
- /**
- * Get the integer value of this enum value, as defined in the Thrift IDL.
- */
- public int getValue() {
- return value;
- }
-
- /**
- * Find a the enum type by its integer value, as defined in the Thrift IDL.
- * @return null if the value is not found.
- */
- public static protocol_type findByValue(int value) {
- switch (value) {
- case 1:
- return PROTOCOL_LU;
- case 2:
- return PROTOCOL_L3VPN;
- case 3:
- return PROTOCOL_EVPN;
- case 4:
- return PROTOCOL_ANY;
- default:
- return null;
- }
- }
-}
+/**\r
+ * Autogenerated by Thrift Compiler (0.9.3)\r
+ *\r
+ * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING\r
+ * @generated\r
+ */\r
+package org.opendaylight.netvirt.bgpmanager.thrift.gen;\r
+\r
+\r
+import java.util.Map;\r
+import java.util.HashMap;\r
+import org.apache.thrift.TEnum;\r
+\r
+public enum protocol_type implements org.apache.thrift.TEnum {\r
+ PROTOCOL_LU(1),\r
+ PROTOCOL_L3VPN(2),\r
+ PROTOCOL_EVPN(3),\r
+ PROTOCOL_ANY(4);\r
+\r
+ private final int value;\r
+\r
+ private protocol_type(int value) {\r
+ this.value = value;\r
+ }\r
+\r
+ /**\r
+ * Get the integer value of this enum value, as defined in the Thrift IDL.\r
+ */\r
+ public int getValue() {\r
+ return value;\r
+ }\r
+\r
+ /**\r
+ * Find a the enum type by its integer value, as defined in the Thrift IDL.\r
+ * @return null if the value is not found.\r
+ */\r
+ public static protocol_type findByValue(int value) {\r
+ switch (value) {\r
+ case 1:\r
+ return PROTOCOL_LU;\r
+ case 2:\r
+ return PROTOCOL_L3VPN;\r
+ case 3:\r
+ return PROTOCOL_EVPN;\r
+ case 4:\r
+ return PROTOCOL_ANY;\r
+ default:\r
+ return null;\r
+ }\r
+ }\r
+}\r
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
- package org.opendaylight.netvirt.bgpmanager.thrift.gen;
+package org.opendaylight.netvirt.bgpmanager.thrift.gen;
+
import org.apache.thrift.scheme.IScheme;
import org.apache.thrift.scheme.SchemeFactory;
import org.apache.thrift.scheme.StandardScheme;
public static final int BGP_ERR_NOT_ITER = 15;
+ public static final int BGP_ERR_PEER_EXISTS = 19;
+
public static final int BGP_ERR_PARAM = 100;
public static final int BGP_ERR_NOT_SUPPORTED = 200;
+ public static final int BGP_ETHTAG_MAX_ET = 268435455;
+
}
-/*
- * Copyright (c) 2015, 2017 Ericsson India Global Services Pvt Ltd. and others. All rights reserved.
- *
- * This program and the accompanying materials are made available under the
- * terms of the Eclipse Public License v1.0 which accompanies this distribution,
- * and is available at http://www.eclipse.org/legal/epl-v10.html
- */
+ // https://wiki.opendaylight.org/view/Vpnservice:BGP_Stack_setup
+ //
+ // the label argument in pushRoute can use these consts
+ const i32 LBL_NO_LABEL = 0
+
+ /*
+ * mpls explicit null isn't 3, but this is not meant
+ * to be put in a packet but is used only between odl
+ * and bgp because zero is already used up for
+ * 'LBL_NO_LABEL'. besides, if this should accdientally
+ * leak into a packet header, it will at least be an
+ * implicit null
+ */
+ const i32 LBL_EXPLICIT_NULL = 3
+
+ // FIB entry type
+ const i32 BGP_RT_ADD = 0
+ const i32 BGP_RT_DEL = 1
+
+ // FIB table iteration op
+ const i32 GET_RTS_INIT = 0
+ const i32 GET_RTS_NEXT = 1
+
+ /*
+ * error codes.
+ * 0 is success.
+ * ERR_FAILED because something bad happens deeper
+ * inside BGP, such as deleting a route that
+ * doesn't exist.
+ * ERR_PARAM when params don't validate
+ * ERR_ACTIVE when routing instance is already
+ * running but ODL calls startBgp() anyway
+ * ERR_INACTIVE when an RPC is invkoed but there
+ * is no session.
+ * ERR_NOT_ITER when GET_RTS_NEXT is called without
+ * initializing with GET_RTS_INIT
+ */
+
+ const i32 BGP_ERR_FAILED = 1
+ const i32 BGP_ERR_ACTIVE = 10
+ const i32 BGP_ERR_INACTIVE = 11
+ const i32 BGP_ERR_NOT_ITER = 15
+ const i32 BGP_ERR_PEER_EXISTS = 19
+ const i32 BGP_ERR_PARAM = 100
+ const i32 BGP_ERR_NOT_SUPPORTED = 200
+
+ const i32 BGP_ETHTAG_MAX_ET = 0xfffffff
-// the label argument in pushRoute can use these
-const i32 LBL_NO_LABEL = 0
-const i32 LBL_EXPLICIT_NULL = 3
+ // supported afi-safi combinations
+ enum af_afi {
+ AFI_IP = 1,
+ AFI_IPV6 = 2,
+ AFI_L2VPN = 3
+ }
+
+ enum af_safi {
+ SAFI_IP_LABELED_UNICAST = 4,
+ SAFI_MPLS_VPN = 5,
+ SAFI_EVPN = 6
+ }
+
+ // supported encapsulation types - RFC 5512
+ enum encap_type {
+ L2TPV3_OVER_IP = 1,
+ GRE = 2,
+ IP_IN_IP = 7,
+ VXLAN = 8,
+ MPLS = 10
+ }
-// FIB entry type
-const i32 BGP_RT_ADD = 0
-const i32 BGP_RT_DEL = 1
+ // layer type
+ // used to mention to which layer a VRF belongs to.
+ enum layer_type {
+ LAYER_2 = 1,
+ LAYER_3 = 2
+ }
-// FIB table iteration op
-const i32 GET_RTS_INIT = 0
-const i32 GET_RTS_NEXT = 1
-
-/*
- * Error codes.
- * 0 is success.
- * ERR_FAILED because something not permitted
- * was attempted, such as deleting a route
- * that doesn't exist.
- * ERR_ACTIVE when session is sought to be created
- * when it is already running.
- * ERR_INACTIVE when an RPC is called but there is
- * no session.
- * ERR_NOT_ITER when GET_RTS_NEXT is called without
- * initializing with GET_RTS_INIT
- * ERR_PARAM when there is an issue with params
- * ERR_NOT_SUPPORTED when the server does not support
- * the operation.
- */
-
-const i32 BGP_ERR_FAILED = 1
-const i32 BGP_ERR_ACTIVE = 10
-const i32 BGP_ERR_INACTIVE = 11
-const i32 BGP_ERR_NOT_ITER = 15
-const i32 BGP_ERR_PARAM = 100
-const i32 BGP_ERR_NOT_SUPPORTED = 200
-
-// these are the supported afi-safi combinations
-enum af_afi {
- AFI_IP = 1,
- AFI_IPV6 = 2,
- AFI_L2VPN = 3
-}
-
-enum af_safi {
- SAFI_IPV4_LABELED_UNICAST = 4,
- SAFI_MPLS_VPN = 5,
- SAFI_EVPN = 6
-}
-
-// supported encapsulation types - RFC 5512
-enum encap_type {
- L2TPV3_OVER_IP = 1,
- GRE = 2,
- IP_IN_IP = 7,
- VXLAN = 8,
- MPLS = 10
-}
-// layer type
-// used to mention to which layer a VRF belongs to.
-enum layer_type {
- LAYER_2 = 1,
- LAYER_3 = 2
-}
-// protocol type
-// used to know to which route type is referred
+ // protocol type
+ // used to know to which route type is referred
enum protocol_type {
- PROTOCOL_LU = 1, // no overlay configuration
- PROTOCOL_L3VPN = 2, // MPLS over GRE overlay
- PROTOCOL_EVPN = 3 // VxLAN overlay
- PROTOCOL_ANY = 4 // used only for getRoutes()
+ PROTOCOL_LU = 1, // no overlay configuration
+ PROTOCOL_L3VPN = 2, // MPLS over GRE overlay
+ PROTOCOL_EVPN = 3 // VxLAN overlay
+ PROTOCOL_ANY = 4 // for getRoutes() only
}
+ // peer status type
+ // used for getPeerStatus()
+ enum peer_status_type {
+ PEER_UP = 0,
+ PEER_DOWN = 1,
+ PEER_UNKNOWN = 2,
+ PEER_NOTCONFIGURED = 3
+ }
-/*
- * FIB update.
- * type is either RT_ADD(0) or RT_DEL(1)
- */
-
-// FIB update
-struct Update {
- 1: i32 type, // either BGP_RT_ADD or RT_DEL
- 2: i32 reserved, // JNI impl used a RIB-version here
- 3: i32 prefixlen,
- 4: i32 l3label,
- 5: i32 l2label,
- 6: i32 ethtag,
- 7: string esi,
- 8: string macaddress,
- 9: string rd,
- 10: string prefix,
- 11: string nexthop,
- 12: string routermac
-}
-
+ // FIB update
+ struct Update {
+ 1: i32 type, // either BGP_RT_ADD or RT_DEL
+ 2: i32 reserved, // JNI impl used a RIB-version here
+ 3: i32 prefixlen,
+ 4: i32 l3label,
+ 5: i32 l2label,
+ 6: i32 ethtag,
+ 7: string esi,
+ 8: string macaddress,
+ 9: string rd,
+ 10: string prefix,
+ 11: string nexthop,
+ 12: string routermac,
+ }
+
+ /*
+ * a sequence of FIB updates, valid only if errcode
+ * is zero. returned by getRoutes(). more=0 means end
+ * of iteration.
+ */
+
+ struct Routes {
+ 1: i32 errcode, // one of the BGP_ERR's
+ 2: optional list<Update> updates,
+ 4: optional i32 more
+ }
-/*
- * A sequence of FIB updates, valid only if errcode
- is zero. Returned as a result of iteration using
- getRoutes() (ie, a database read). more=0 signals
- end of iteration.
- */
+ struct BfdConfigData {
+ 1: byte bfdConfigDataVersion,
+ 2: optional i32 bfdRxInterval,
+ 3: optional byte bfdFailureThreshold,
+ 4: optional i32 bfdTxInterval,
+ 5: optional i32 bfdDebounceDown,
+ 6: optional i32 bfdDebounceUp,
+ 7: optional bool bfdMultihop
+ }
-struct Routes {
- 1: i32 errcode,
- 2: optional list<Update> updates,
- 4: optional i32 more
-}
-
-service BgpConfigurator {
- /*
- * startBgp() starts a BGP instance on the BGP VM. Graceful Restart
- * also must be configured (stalepathTime > 0). If local BGP is
- * restarting, announceFlush tells neighbor to flush all routes
- * previously advertised by us. This is the F bit of RFC 4724.
- */
- i32 startBgp(1:i64 asNumber, 2:string routerId, 3: i32 port,
- 4:i32 holdTime, 5:i32 keepAliveTime,
- 6:i32 stalepathTime, 7:bool announceFlush),
- i32 stopBgp(1:i64 asNumber),
- i32 createPeer(1:string ipAddress, 2:i64 asNumber),
-
- /* 'setPeerSecret' sets the shared secret needed to protect the peer
- * connection using TCP MD5 Signature Option (see rfc 2385).
- *
- * Params:
- *
- * 'ipAddress' is the peer (neighbour) address. Mandatory.
- *
- * 'rfc2385_sharedSecret' is the secret. Mandatory. Length must be
- * greater than zero.
- *
- * Return codes:
- *
- * 0 on success.
- *
- * BGP_ERR_FAILED if 'ipAddress' is missing or unknown.
- *
- * BGP_ERR_PARAM if 'rfc2385_sharedSecret' is missing or invalid (e.g.
- * it is too short or too long).
- *
- * BGP_ERR_INACTIVE when there is no session.
- *
- * BGP_ERR_NOT_SUPPORTED when TCP MD5 Signature Option is not supported
- * (e.g. the underlying TCP stack does not support it)
- *
- */
- i32 setPeerSecret(1:string ipAddress, 2:string rfc2385_sharedSecret),
- i32 deletePeer(1:string ipAddress)
- i32 addVrf(1:layer_type l_type, 2:string rd, 3:list<string> irts, 4:list<string> erts, 5:af_afi afi, 6:af_safi safi),
- i32 delVrf(1:string rd, 2:af_afi afi, 3:af_safi safi),
- /*
- * pushRoute:
- * IPv6 is now supported through af_afi parameter, 'af_afi': indicates whether prefix is IPv4 or IPv6.
- * 'p_type' is mandatory
- * 'nexthop' cannot be null for VPNv4 and LU.
- * 'rd' is null for LU (and unicast).
- * 'label' cannot be NO_LABEL for VPNv4 MPLS and LU.
- * 'ethtag stands 32 bit value. only 24 bit value is used for now (VID of vxlan).
- * 'esi' is a 10 byte hexadecimal string. 1st byte defines the type. Only '00' is supported for
- now.
- * value should have 'colon' separators : 00:02:ab:de:45:23:54:75:fd:ab as example
- * encap_type: restricted for VXLAN if L3VPN-EVPN configured.
- * ignored if L3VPN-MPLS is configured.
- */
- i32 pushRoute(
- 1:protocol_type p_type,
- 2:string prefix,
- 3:string nexthop,
- 4:string rd,
- 5:i32 ethtag,
- 6:string esi,
- 7:string macaddress,
- 8:i32 l3label,
- 9:i32 l2label,
- 10:encap_type enc_type,
- 11:string routermac,
- 12:af_afi afi),
-
-
- /*
- * 'p_type' is mandatory
- * kludge: second argument is either 'rd' (VPNv4) or
- * label (v4LU) as a string (eg: "2500")
- * seventh argument is either ipv4 or ipv6
- */
- i32 withdrawRoute(
- 1:protocol_type p_type,
- 2:string prefix,
- 3:string rd,
- 4:i32 ethtag,
- 5:string esi,
- 6:string macaddress,
- 7:af_afi afi),
-
-
- i32 setEbgpMultihop(1:string peerIp, 2:i32 nHops),
- i32 unsetEbgpMultihop(1:string peerIp),
- i32 setUpdateSource(1:string peerIp, 2:string srcIp),
- i32 unsetUpdateSource(1:string peerIp),
- i32 enableAddressFamily(1:string peerIp, 2:af_afi afi, 3:af_safi safi),
- i32 disableAddressFamily(1:string peerIp, 2:af_afi afi, 3:af_safi safi),
- i32 setLogConfig(1:string logFileName, 2:string logLevel),
- i32 enableGracefulRestart(1:i32 stalepathTime),
- i32 disableGracefulRestart(),
-
- /*
- * getRoutes():
- * 'p_type' is mandatory. selects the VRF RIB to be dumped
- * if PROTOCOL_LU chosen ( no VRF RIBs implemented), global RIB will be dumped)
- * optype is one of: GET_RTS_INIT: start the iteration,
- * GET_RTS_NEXT: get next bunch of routes. winSize is
- * the size of the buffer that caller has allocated to
- * receive the array of routes. qbgp sends no more than
- * the number of routes that would fit in this buffer,
- * but not necessarily the maximum number that would fit
- * (we currently use min(winSize, tcpWindowSize) ).
- * calling INIT when NEXT is expected causes reinit.
- * both vpnv4 or vpnv6 RIBs are supported.
- */
- Routes getRoutes(1:protocol_type p_type, 2:i32 optype, 3:i32 winSize, 4:af_afi afi),
- i32 enableMultipath(1:af_afi afi, 2:af_safi safi),
- i32 disableMultipath(1:af_afi afi, 2:af_safi safi),
- i32 multipaths(1:string rd, 2:i32 maxPath),
- i32 enableEORDelay(1:i32 delay),
- i32 sendEOR()
-}
-
-service BgpUpdater {
- // 'p_type' is mandatory. indicates the origin of data
- oneway void onUpdatePushRoute(
- 1:protocol_type p_type,
- 2:string rd,
- 3:string prefix,
- 4:i32 prefixlen,
- 5:string nexthop,
- 6:i32 ethtag,
- 7:string esi,
- 8:string macaddress,
- 9:i32 l3label,
- 10:i32 l2label,
- 11:string routermac,
- 12:af_afi afi),
-
- oneway void onUpdateWithdrawRoute(
- 1:protocol_type p_type,
- 2:string rd,
- 3:string prefix,
- 4:i32 prefixlen,
- 5:string nexthop,
- 6:i32 ethtag,
- 7:string esi,
- 8:string macaddress,
- 9:i32 l3label,
- 10:i32 l2label,
- 11:af_afi afi),
-
- oneway void onStartConfigResyncNotification(),
- /* communicate to ODL a BGP Notification received from peer */
- oneway void onNotificationSendEvent(1:string prefix,
- 2:byte errCode, 3:byte errSubcode)
-}
+ service BgpConfigurator {
+ /*
+ * startBgp() starts a bgp instance on the bgp VM. Graceful
+ * Restart also must be configured (stalepathTime > 0). if
+ * local dataplane remains undisturbed relative to previous
+ * invocation, announceFbit tells neighbors to retain all
+ * routes advertised by us in our last incarnation. this is
+ * the F bit of RFC 4724.
+ */
+ i32 startBgp(1:i64 asNumber, 2:string routerId, 3: i32 port,
+ 4:i32 holdTime, 5:i32 keepAliveTime,
+ 6:i32 stalepathTime, 7:bool announceFbit),
+ i32 stopBgp(1:i64 asNumber),
+ i32 createPeer(1:string ipAddress, 2:i64 asNumber),
+ /* 'setPeerSecret' sets the shared secret needed to protect the peer
+ * connection using TCP MD5 Signature Option (see rfc 2385).
+ *
+ * Params:
+ *
+ * 'ipAddress' is the peer ( neighbour) address. Mandatory.
+ *
+ * 'rfc2385_sharedSecret' is the secret. Mandatory. Length must be
+ * greater than zero.
+ *
+ * Return codes:
+ *
+ * 0 on success.
+ *
+ * BGP_ERR_FAILED if 'ipAddress' is missing or unknown.
+ *
+ * BGP_ERR_PARAM if 'rfc2385_sharedSecret' is missing or invalid (e.g.
+ * it is too short or too long).
+ *
+ * BGP_ERR_INACTIVE when there is not session.
+ *
+ * BGP_ERR_NOT_SUPPORTED when TCP MD5 Signature Option is not supported
+ * (e.g. the underlying TCP stack does not support it)
+ *
+ */
+ i32 setPeerSecret(1:string ipAddress, 2:string rfc2385_sharedSecret),
+ i32 deletePeer(1:string ipAddress)
+ i32 addVrf(1:layer_type l_type, 2:string rd, 3:list<string> irts,
+ 4:list<string> erts, 5:af_afi afi, 6:af_safi safi),
+ i32 delVrf(1:string rd, 2:af_afi afi, 3:af_safi safi),
+ /*
+ * pushRoute:
+ * IPv6 is not supported.
+ * 'p_type' is mandatory
+ * 'nexthop' cannot be null for VPNv4 and LU.
+ * 'rd' is null for LU (and unicast).
+ * 'label' cannot be NO_LABEL for VPNv4 MPLS and LU.
+ * 'ethtag stands 32 bit value. only 24 bit value is used for now (VID of vxlan).
+ * 'esi' is a 10 byte hexadecimal string. 1st byte defines the type. Only '00' is supported for now.
+ * value should have 'colon' separators : 00:02:ab:de:45:23:54:75:fd:ab as example
+ * encap_type: restricted for VXLAN if L3VPN-EVPN configured.
+ * ignored if L3VPN-MPLS is configured.
+ * af_afi: indicates whether prefix is IPv4 or IPv6
+ */
+ i32 pushRoute(1:protocol_type p_type, 2:string prefix, 3:string nexthop, 4:string rd,
+ 5:i64 ethtag, 6:string esi, 7:string macaddress,
+ 8:i32 l3label, 9:i32 l2label, 10:encap_type enc_type,
+ 11:string routermac, 12:af_afi afi),
+ /*
+ * 'p_type' is mandatory
+ * kludge: second argument is either 'rd' (VPNv4) or
+ * label (v4LU) as a string (eg: "2500")
+ * af_afi: indicates whether prefix is IPv4 or IPv6
+ */
+ i32 withdrawRoute(1:protocol_type p_type, 2:string prefix, 3:string rd,
+ 4:i64 ethtag, 5:string esi, 6:string macaddress, 7:af_afi afi),
+ i32 setEbgpMultihop(1:string peerIp, 2:i32 nHops),
+ i32 unsetEbgpMultihop(1:string peerIp),
+ i32 setUpdateSource(1:string peerIp, 2:string srcIp),
+ i32 unsetUpdateSource(1:string peerIp),
+ i32 enableAddressFamily(1:string peerIp, 2:af_afi afi, 3:af_safi safi),
+ i32 disableAddressFamily(1:string peerIp, 2:af_afi afi, 3:af_safi safi),
+ i32 setLogConfig(1:string logFileName, 2:string logLevel),
+ i32 enableGracefulRestart(1:i32 stalepathTime),
+ i32 disableGracefulRestart(),
+ /*
+ * getRoutes():
+ * 'p_type' is mandatory. selects the VRF RIB to be dumped
+ * if PROTOCOL_LU chosen ( no VRF RIBs implemented), global RIB will be dumped)
+ * optype is one of: GET_RTS_INIT: start the iteration,
+ * GET_RTS_NEXT: get next bunch of routes. winSize is
+ * the size of the buffer that caller has allocated to
+ * receive the array of routes. qbgp sends no more than
+ * the number of routes that would fit in this buffer,
+ * but not necessarily the maximum number that would fit
+ * (we currently use min(winSize, tcpWindowSize) ).
+ * calling INIT when NEXT is expected causes reinit.
+ * only vpnv4 RIBs are supported.
+ */
+ Routes getRoutes(1:protocol_type p_type, 2:i32 optype, 3:i32 winSize, 4:af_afi afi),
+ i32 enableMultipath(1:af_afi afi, 2:af_safi safi),
+ i32 disableMultipath(1:af_afi afi, 2:af_safi safi),
+ i32 multipaths(1:string rd, 2:i32 maxPath),
+ i32 enableEORDelay(1:i32 delay),
+ i32 sendEOR(),
+ i32 enableBFDFailover(1:BfdConfigData bfdConfig),
+ i32 disableBFDFailover(),
+ peer_status_type getPeerStatus(1:string ipAddress, 2:i64 asNumber),
+ }
+
+ service BgpUpdater {
+ // 'p_type' is mandatory. indicates the origin of data
+ oneway void onUpdatePushRoute(1:protocol_type p_type, 2:string rd, 3:string prefix,
+ 4:i32 prefixlen, 5:string nexthop,
+ 6:i64 ethtag, 7:string esi, 8:string macaddress,
+ 9:i32 l3label, 10:i32 l2label,
+ 11:string routermac, 12:af_afi afi),
+ oneway void onUpdateWithdrawRoute(1:protocol_type p_type, 2:string rd, 3:string prefix,
+ 4:i32 prefixlen, 5:string nexthop,
+ 6:i64 ethtag, 7:string esi, 8:string macaddress,
+ 9:i32 l3label, 10:i32 l2label, 11:af_afi afi),
+ // tell them we're open for business
+ oneway void onStartConfigResyncNotification(),
+ // relay to odl a bgp Notification we got from peer
+ oneway void onNotificationSendEvent(1:string prefix,
+ 2:byte errCode, 3:byte errSubcode),
+ oneway void peerDown(1:string ipAddress, 2:i64 asNumber),
+ oneway void peerUp(1:string ipAddress, 2:i64 asNumber)
+}
String prefix,
int plen,
String nexthop,
- int ethtag,
+ long ethtag,
String esi,
String macaddress,
int l3label,
String prefix,
int plen,
String nexthop,
- int ethtag,
+ long ethtag,
String esi,
String macaddress,
int l3label,
macaddress);
}
+ @Override
+ public void peerDown(String ipAddress, long asNumber) {
+ LOG.info("PeerDown {} : {} From BGP", ipAddress, asNumber);
+ bgpConfigManager.peerDown(ipAddress, asNumber);
+ }
+
+ @Override
+ public void peerUp(String ipAddress, long asNumber) {
+ LOG.info("PeerUp {} : {} from BGP", ipAddress, asNumber);
+ bgpConfigManager.peerUp(ipAddress, asNumber);
+ }
+
@Override
public void onStartConfigResyncNotification() {
LOG.info("BGP (re)started");
}
public synchronized void start() {
+ if (isBgpThriftServiceStarted()) {
+ stop();
+ }
ft = threadPool.submit(new BgpUpdateServer());
}
odl:type="default" />
<reference id="entityOwnershipService"
interface="org.opendaylight.mdsal.eos.binding.api.EntityOwnershipService" />
+ <reference id="iFibManager"
+ interface="org.opendaylight.netvirt.fibmanager.api.IFibManager" />
<reference id="iVpnLinkService"
interface="org.opendaylight.netvirt.vpnmanager.api.intervpnlink.IVpnLinkService"
availability="optional" />
</action>
</command>
</command-bundle>
+ <command-bundle xmlns="http://karaf.apache.org/xmlns/shell/v1.1.0">
+ <command>
+ <action class="org.opendaylight.netvirt.bgpmanager.commands.BfdCache">
+ <argument ref="bgpUtil"/>
+ </action>
+ </command>
+ </command-bundle>
+ <command-bundle xmlns="http://karaf.apache.org/xmlns/shell/v1.1.0">
+ <command>
+ <action class="org.opendaylight.netvirt.bgpmanager.commands.Bfd">
+ <argument ref="bgpManager"/>
+ </action>
+ </command>
+ </command-bundle>
+ <command-bundle xmlns="http://karaf.apache.org/xmlns/shell/v1.1.0">
+ <command>
+ <action class="org.opendaylight.netvirt.bgpmanager.commands.DcgwTep">
+ <argument ref="bgpManager"/>
+ </action>
+ </command>
+ </command-bundle>
<command-bundle xmlns="http://karaf.apache.org/xmlns/shell/v1.1.0">
<command>
<action class="org.opendaylight.netvirt.bgpmanager.commands.Multipath">
import org.opendaylight.controller.md.sal.binding.test.AbstractConcurrentDataBrokerTest;
import org.opendaylight.netvirt.bgpmanager.BgpUtil;
import org.opendaylight.netvirt.bgpmanager.FibDSWriter;
+import org.opendaylight.netvirt.fibmanager.api.IFibManager;
import org.opendaylight.netvirt.fibmanager.api.RouteOrigin;
import org.opendaylight.yang.gen.v1.urn.opendaylight.netvirt.fibmanager.rev150330.vrfentries.VrfEntry;
private DataBroker dataBroker;
private FibDSWriter bgpFibWriter = null;
private MockFibManager fibManager = null;
+ private IFibManager ifibManager = null;
@Before
public void setUp() {
dataBroker = getDataBroker();
- bgpFibWriter = new FibDSWriter(dataBroker, new BgpUtil(dataBroker));
+ bgpFibWriter = new FibDSWriter(dataBroker, new BgpUtil(dataBroker, ifibManager));
fibManager = new MockFibManager(dataBroker);
}