Updated libraries dependencies.
More code cleanup.
This commit is contained in:
parent
9d67b34354
commit
3e0bef10d7
22 changed files with 71 additions and 74 deletions
|
@ -40,7 +40,7 @@ package net.thauvin.erik.mobibot;
|
|||
* @created 2014-04-26
|
||||
* @since 1.0
|
||||
*/
|
||||
public class Commands
|
||||
class Commands
|
||||
{
|
||||
/**
|
||||
* The add (back)log command.
|
||||
|
|
|
@ -51,7 +51,7 @@ import java.util.*;
|
|||
* @created Feb 11, 2004
|
||||
* @since 1.0
|
||||
*/
|
||||
public class CurrencyConverter implements Runnable
|
||||
class CurrencyConverter implements Runnable
|
||||
{
|
||||
/**
|
||||
* The exchange rates.
|
||||
|
|
|
@ -42,8 +42,7 @@ import del.icio.us.Delicious;
|
|||
* @created Mar 5, 2005
|
||||
* @since 1.0
|
||||
*/
|
||||
@SuppressWarnings("UnnecessaryBoxing")
|
||||
public class DeliciousPoster
|
||||
class DeliciousPoster
|
||||
{
|
||||
private final Delicious delicious;
|
||||
|
||||
|
@ -73,11 +72,11 @@ public class DeliciousPoster
|
|||
{
|
||||
public Object construct()
|
||||
{
|
||||
return Boolean.valueOf(delicious.addPost(entry.getLink(),
|
||||
entry.getTitle(),
|
||||
postedBy(entry),
|
||||
entry.getDeliciousTags(),
|
||||
entry.getDate()));
|
||||
return delicious.addPost(entry.getLink(),
|
||||
entry.getTitle(),
|
||||
postedBy(entry),
|
||||
entry.getDeliciousTags(),
|
||||
entry.getDate());
|
||||
}
|
||||
};
|
||||
|
||||
|
@ -109,7 +108,7 @@ public class DeliciousPoster
|
|||
{
|
||||
public Object construct()
|
||||
{
|
||||
return Boolean.valueOf(delicious.deletePost(link));
|
||||
return delicious.deletePost(link);
|
||||
}
|
||||
};
|
||||
|
||||
|
@ -132,21 +131,21 @@ public class DeliciousPoster
|
|||
{
|
||||
delicious.deletePost(oldUrl);
|
||||
|
||||
return Boolean.valueOf(delicious.addPost(entry.getLink(),
|
||||
entry.getTitle(),
|
||||
postedBy(entry),
|
||||
entry.getDeliciousTags(),
|
||||
entry.getDate()));
|
||||
return delicious.addPost(entry.getLink(),
|
||||
entry.getTitle(),
|
||||
postedBy(entry),
|
||||
entry.getDeliciousTags(),
|
||||
entry.getDate());
|
||||
}
|
||||
else
|
||||
{
|
||||
return Boolean.valueOf(delicious.addPost(entry.getLink(),
|
||||
entry.getTitle(),
|
||||
postedBy(entry),
|
||||
entry.getDeliciousTags(),
|
||||
entry.getDate(),
|
||||
true,
|
||||
true));
|
||||
return delicious.addPost(entry.getLink(),
|
||||
entry.getTitle(),
|
||||
postedBy(entry),
|
||||
entry.getDeliciousTags(),
|
||||
entry.getDate(),
|
||||
true,
|
||||
true);
|
||||
}
|
||||
}
|
||||
};
|
||||
|
|
|
@ -42,7 +42,7 @@ import java.util.Random;
|
|||
* @created 2014-04-28
|
||||
* @since 1.0
|
||||
*/
|
||||
public class Dice
|
||||
class Dice
|
||||
{
|
||||
/**
|
||||
* Disables the default constructor.
|
||||
|
|
|
@ -50,7 +50,7 @@ import java.util.List;
|
|||
* @created 2014-04-28
|
||||
* @since 1.0
|
||||
*/
|
||||
public class EntriesMgr
|
||||
class EntriesMgr
|
||||
{
|
||||
/**
|
||||
* The name of the file containing the current entries.
|
||||
|
|
|
@ -361,7 +361,7 @@ public class EntryLink implements Serializable
|
|||
*
|
||||
* @param tags The tags.
|
||||
*/
|
||||
final void setTags(List<SyndCategoryImpl> tags)
|
||||
private void setTags(List<SyndCategoryImpl> tags)
|
||||
{
|
||||
this.tags.addAll(tags);
|
||||
}
|
||||
|
|
|
@ -50,7 +50,7 @@ import java.util.List;
|
|||
* @created Feb 1, 2004
|
||||
* @since 1.0
|
||||
*/
|
||||
public class FeedReader implements Runnable
|
||||
class FeedReader implements Runnable
|
||||
{
|
||||
/**
|
||||
* The maximum number of feed items to display.
|
||||
|
|
|
@ -49,7 +49,7 @@ import java.net.URLEncoder;
|
|||
* @created Feb 7, 2004
|
||||
* @since 1.0
|
||||
*/
|
||||
public class GoogleSearch implements Runnable
|
||||
class GoogleSearch implements Runnable
|
||||
{
|
||||
/**
|
||||
* The tab indent (4 spaces).
|
||||
|
|
|
@ -48,7 +48,7 @@ import java.net.URLConnection;
|
|||
* @created 2014-04-20
|
||||
* @since 1.0
|
||||
*/
|
||||
public class Joke implements Runnable
|
||||
class Joke implements Runnable
|
||||
{
|
||||
|
||||
/**
|
||||
|
|
|
@ -46,14 +46,13 @@ import java.net.UnknownHostException;
|
|||
* @created 2014-04-26
|
||||
* @since 1.0
|
||||
*/
|
||||
public class Lookup
|
||||
class Lookup
|
||||
{
|
||||
|
||||
/**
|
||||
* The whois host.
|
||||
*/
|
||||
@SuppressWarnings("WeakerAccess")
|
||||
public static final String WHOIS_HOST = "whois.arin.net";
|
||||
private static final String WHOIS_HOST = "whois.arin.net";
|
||||
|
||||
/**
|
||||
* Disables the default constructor.
|
||||
|
|
|
@ -773,8 +773,7 @@ public class Mobibot extends PircBot
|
|||
*
|
||||
* @return The file location.
|
||||
*/
|
||||
@SuppressWarnings("WeakerAccess")
|
||||
public String getSerializedObject()
|
||||
private String getSerializedObject()
|
||||
{
|
||||
return serializedObject;
|
||||
}
|
||||
|
@ -828,7 +827,7 @@ public class Mobibot extends PircBot
|
|||
* @param channel The channel.
|
||||
* @param action The action.
|
||||
*/
|
||||
final void action(String channel, String action)
|
||||
private void action(String channel, String action)
|
||||
{
|
||||
if (Utils.isValidString(channel) && Utils.isValidString(action))
|
||||
{
|
||||
|
|
|
@ -46,7 +46,7 @@ import java.io.IOException;
|
|||
* @created Feb 7, 2004
|
||||
* @since 1.0
|
||||
*/
|
||||
public class StockQuote implements Runnable
|
||||
class StockQuote implements Runnable
|
||||
{
|
||||
/**
|
||||
* The Yahoo! stock quote URL.
|
||||
|
|
|
@ -46,7 +46,6 @@ import java.util.Date;
|
|||
*/
|
||||
public class TellMessage implements Serializable
|
||||
{
|
||||
@SuppressWarnings({"UnusedDeclaration"})
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
private final String id;
|
||||
|
|
|
@ -48,7 +48,7 @@ import java.util.List;
|
|||
* @created 2014-04-26
|
||||
* @since 1.0
|
||||
*/
|
||||
public class TellMessagesMgr
|
||||
class TellMessagesMgr
|
||||
{
|
||||
/**
|
||||
* Disables the default constructor.
|
||||
|
@ -132,7 +132,7 @@ public class TellMessagesMgr
|
|||
logger.getLogger().error("An error occurred loading the messages queue.", e);
|
||||
}
|
||||
|
||||
return (List<TellMessage>) new ArrayList();
|
||||
return new ArrayList<TellMessage>();
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
@ -44,7 +44,7 @@ import twitter4j.conf.ConfigurationBuilder;
|
|||
* @created Sept 10, 2008
|
||||
* @since 1.0
|
||||
*/
|
||||
public class Twitter implements Runnable
|
||||
class Twitter implements Runnable
|
||||
{
|
||||
/**
|
||||
* The Twitter access token.
|
||||
|
|
|
@ -50,7 +50,7 @@ import java.util.Calendar;
|
|||
* @created 2014-04-26
|
||||
* @since 1.0
|
||||
*/
|
||||
public class Utils
|
||||
class Utils
|
||||
{
|
||||
/**
|
||||
* The timestamp simple date format.
|
||||
|
|
|
@ -42,7 +42,7 @@ import java.util.Random;
|
|||
* @created 2014-04-28
|
||||
* @since 1.0
|
||||
*/
|
||||
public class War
|
||||
class War
|
||||
{
|
||||
/**
|
||||
* The deck of card for the {@link net.thauvin.erik.mobibot.Commands#WAR_CMD war} command.
|
||||
|
|
|
@ -47,7 +47,7 @@ import java.util.Date;
|
|||
* @created Feb 7, 2004
|
||||
* @since 1.0
|
||||
*/
|
||||
public class Weather implements Runnable
|
||||
class Weather implements Runnable
|
||||
{
|
||||
/**
|
||||
* The URL where the stations are listed.
|
||||
|
|
|
@ -46,7 +46,7 @@ import java.util.TreeMap;
|
|||
* @created 2014-04-27
|
||||
* @since 1.0
|
||||
*/
|
||||
public class WorldTime
|
||||
class WorldTime
|
||||
{
|
||||
/**
|
||||
* The beats (Internet Time) keyword.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue