com.twitter
Class Validator

java.lang.Object
  extended by com.twitter.Validator

public class Validator
extends Object

A class for validating Tweet texts.


Field Summary
static int MAX_TWEET_LENGTH
           
protected  int shortUrlLength
           
protected  int shortUrlLengthHttps
           
 
Constructor Summary
Validator()
           
 
Method Summary
 int getShortUrlLength()
           
 int getShortUrlLengthHttps()
           
 int getTweetLength(String text)
           
 boolean isValidTweet(String text)
           
 void setShortUrlLength(int shortUrlLength)
           
 void setShortUrlLengthHttps(int shortUrlLengthHttps)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

MAX_TWEET_LENGTH

public static final int MAX_TWEET_LENGTH
See Also:
Constant Field Values

shortUrlLength

protected int shortUrlLength

shortUrlLengthHttps

protected int shortUrlLengthHttps
Constructor Detail

Validator

public Validator()
Method Detail

getTweetLength

public int getTweetLength(String text)

isValidTweet

public boolean isValidTweet(String text)

getShortUrlLength

public int getShortUrlLength()

setShortUrlLength

public void setShortUrlLength(int shortUrlLength)

getShortUrlLengthHttps

public int getShortUrlLengthHttps()

setShortUrlLengthHttps

public void setShortUrlLengthHttps(int shortUrlLengthHttps)


Copyright © 2014. All Rights Reserved.