com.netflix.loadbalancer
Class PingConstant

java.lang.Object
  extended by com.netflix.loadbalancer.PingConstant
All Implemented Interfaces:
IPing

public class PingConstant
extends java.lang.Object
implements IPing

A utility Ping Implementation that returns whatever its been set to return (alive or dead)


Constructor Summary
PingConstant()
           
 
Method Summary
 boolean getConstant()
           
 boolean isAlive(Server server)
          Checks whether the given Server is "alive" i.e.
 void setConstant(boolean constant)
           
 void setConstant(java.lang.String constantStr)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

PingConstant

public PingConstant()
Method Detail

setConstant

public void setConstant(java.lang.String constantStr)

setConstant

public void setConstant(boolean constant)

getConstant

public boolean getConstant()

isAlive

public boolean isAlive(Server server)
Description copied from interface: IPing
Checks whether the given Server is "alive" i.e. should be considered a candidate while loadbalancing

Specified by:
isAlive in interface IPing
Returns: