Updated to PircBot 1.5.0

Added support for 2 chars tags, and removal of commas in tags.
This commit is contained in:
Erik C. Thauvin 2010-04-02 10:07:11 +00:00
parent f2cea94844
commit 26dae0eb8a
8 changed files with 642 additions and 560 deletions

View file

@ -380,7 +380,7 @@ public class EntryLink implements Serializable
{
if (tags != null)
{
final String[] parts = tags.split(" ");
final String[] parts = tags.replaceAll(", ", " ").replaceAll(",", " ").split(" ");
SyndCategoryImpl tag;
String part;
@ -390,7 +390,7 @@ public class EntryLink implements Serializable
{
part = parts[i].trim();
if (part.length() > 2)
if (part.length() >= 2)
{
tag = new SyndCategoryImpl();
tag.setName(part.substring(1).toLowerCase());

View file

@ -810,7 +810,7 @@ public class Mobibot extends PircBot
{
bot.connect(server, port);
}
catch (Exception ex)
catch (Exception ignore)
{
if (retries == MAX_RECONNECT)
{
@ -2675,7 +2675,7 @@ public class Mobibot extends PircBot
{
send(getChannel(), lookup(query));
}
catch (UnknownHostException e)
catch (UnknownHostException ignore)
{
if (query.matches(
"(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\\.(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\\.(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\\.(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)"))

View file

@ -1,5 +1,5 @@
/* Created by JReleaseInfo AntTask from Open Source Competence Group */
/* Creation date Wed Sep 10 20:04:51 PDT 2008 */
/* Creation date Fri Apr 02 02:49:45 PDT 2010 */
package net.thauvin.erik.mobibot;
import java.util.Date;
@ -20,21 +20,21 @@ public class ReleaseInfo {
}
/** buildDate (set during build process to 1221102291797L). */
private static final Date buildDate = new Date(1221102291797L);
/** buildDate (set during build process to 1270201785391L). */
private static final Date buildDate = new Date(1270201785391L);
/**
* Get buildDate (set during build process to Wed Sep 10 20:04:51 PDT 2008).
* Get buildDate (set during build process to Fri Apr 02 02:49:45 PDT 2010).
* @return Date buildDate
*/
public static Date getBuildDate() { return buildDate; }
/**
* Get buildNumber (set during build process to 3).
* Get buildNumber (set during build process to 4).
* @return int buildNumber
*/
public static int getBuildNumber() { return 3; }
public static int getBuildNumber() { return 4; }
/** project (set during build process to "mobibot"). */