Initial import.

This commit is contained in:
Erik C. Thauvin 2004-02-17 04:04:30 +00:00
commit cad709e484
42 changed files with 5961 additions and 0 deletions

6
.cvsignore Normal file
View file

@ -0,0 +1,6 @@
build
dist
log4j.properties
mobibot.properties
mobibot.ser
logs

1
build.properties Normal file
View file

@ -0,0 +1 @@
main.class=net.thauvin.erik.mobibot.Mobibot

49
build.xml Normal file
View file

@ -0,0 +1,49 @@
<?xml version="1.0" encoding="UTF-8"?>
<project name="mobibot" default="build" basedir=".">
<property file="${basedir}/build.properties" />
<property name="path.classes" value="build" />
<property name="path.src" value="src" />
<property name="path.dist" value="dist" />
<property name="path.lib" value="lib" />
<path id="path.source">
<pathelement location="${path.src}" />
</path>
<path id="path.class">
<fileset dir="${path.lib}">
<include name="**/*.jar"/>
</fileset>
</path>
<target name="init">
<tstamp />
<mkdir dir="${path.classes}"/>
<mkdir dir="${path.dist}"/>
</target>
<target name="compile" depends="init" description="Compiles sources">
<mkdir dir="${path.classes}" />
<javac sourcepathref="path.source" classpathref="path.class" destdir="${path.classes}" debug="off" deprecation="on">
<src refid="path.source" />
</javac>
</target>
<target name="build" depends="compile" description="Rebuilds project" />
<target name="jar" depends="compile" description="Builds the JAR">
<copy todir="${path.classes}">
<fileset dir="${path.src}" includes="*.properties" />
</copy>
<pathconvert targetos="unix" pathsep=" " property="mf.lib" refid="path.class">
<map from="${basedir}" to="."/>
</pathconvert>
<jar destfile="${basedir}/${path.dist}/${ant.project.name}.jar" basedir="${path.classes}" excludes="**/.dependency-info/**">
<manifest>
<attribute name="Main-Class" value="${main.class}"/>
<attribute name="Class-Path" value=". ${mf.lib}"/>
</manifest>
</jar>
</target>
<target name="clean" depends="init" description="Removes classses">
<delete quiet="true" includeEmptyDirs="true">
<fileset dir="${path.classes}" includes="*,*/**"/>
<fileset dir="${path.dist}" includes="*,*/**"/>
</delete>
</target>
</project>

BIN
lib/EXML.jar Normal file

Binary file not shown.

BIN
lib/MathEvaluator.jar Normal file

Binary file not shown.

Binary file not shown.

BIN
lib/commons-logging.jar Normal file

Binary file not shown.

BIN
lib/commons-net-1.1.0.jar Normal file

Binary file not shown.

BIN
lib/fetchrss.jar Normal file

Binary file not shown.

BIN
lib/google.jar Normal file

Binary file not shown.

BIN
lib/googleapi.jar Normal file

Binary file not shown.

BIN
lib/jakarta-oro-2.0.8.jar Normal file

Binary file not shown.

BIN
lib/jdom.jar Normal file

Binary file not shown.

BIN
lib/jweather-0.2.3.jar Normal file

Binary file not shown.

BIN
lib/log4j-1.2.8.jar Normal file

Binary file not shown.

BIN
lib/pircbot.jar Normal file

Binary file not shown.

BIN
lib/rsslibj.jar Normal file

Binary file not shown.

View file

@ -0,0 +1,56 @@
/*
* ====================================================================
*
* The Apache Software License, Version 1.1
*
* Copyright (c) 1999-2001 The Apache Software Foundation. All rights
* reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
* are met:
*
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright
* notice, this list of conditions and the following disclaimer in
* the documentation and/or other materials provided with the
* distribution.
*
* 3. The end-user documentation included with the redistribution, if
* any, must include the following acknowlegement:
* "This product includes software developed by the
* Apache Software Foundation (http://www.apache.org/)."
* Alternately, this acknowlegement may appear in the software itself,
* if and wherever such third-party acknowlegements normally appear.
*
* 4. The names "The Jakarta Project", "Commons", and "Apache Software
* Foundation" must not be used to endorse or promote products derived
* from this software without prior written permission. For written
* permission, please contact apache@apache.org.
*
* 5. Products derived from this software may not be called "Apache"
* nor may "Apache" appear in their names without prior written
* permission of the Apache Group.
*
* THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
* WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
* OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
* ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
* SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
* LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
* USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
* ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
* OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
* OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
* ====================================================================
*
* This software consists of voluntary contributions made by many
* individuals on behalf of the Apache Software Foundation. For more
* information on the Apache Software Foundation, please see
* <http://www.apache.org/>.
*
*/

57
licenses/EXML-license.txt Normal file
View file

@ -0,0 +1,57 @@
TERMS AND CONDITIONS FOR ELECTRIC XML
Please read this license agreement carefully. Your use of Electric XML or any
related documentation indicates your acceptance of the following terms and
conditions. If you do not agree to these terms and conditions, you may not
install or use Electric XML. The term Electric XML refers to both the basic
Electric XML software and Electric XML+.
1. Ownership and License. Electric XML is owned by The Mind Electric and is
copyrighted and licensed, not sold. The Mind Electric grants you a
non-exclusive, non-transferable license to use, modify and distribute Electric
XML in both binary and source form as long as all of the following conditions
are met:
You are not bundling Electric XML or a derivative of it as part of a software
development environment such as JBuilder, WebGain or VisualAge. Note that this
restriction is targeted at IDE vendors, and does not prevent developers from
loading Electric XML into an IDE and using it during everyday development.
You are not integrating Electric XML or a derivative of it into a distributed
computing infrastructure or database platform such as WebLogic, Apache SOAP,
WebSphere, Oracle application server, or HP e-speak. Note that this
restriction is targeted at software infrastructure vendors, and does not
prevent developers from using and bundling Electric XML with applications that
run on these platforms.
You are not integrating Electric XML or a derivative of it into an alternative
to Electric XML such as Xerces or JDOM.
You must not remove any of the copyright information from the Electric XML
source code or documentation.
If you cannot meet all of these conditions, please contact us to arrange a
special custom license.
2. Term and Termination
This Agreement is effective until terminated. You may terminate this Agreement
at any time by destroying all copies of Electric XML. This Agreement will
terminate immediately without notice from The Mind Electric if you fail to
comply with any provision of this Agreement. Upon termination, you must destroy
all copies of Electric XML.
3. Warranty Disclaimer and Limitation of Liability
The Mind Electric licenses the Software to you on an "as is" basis, without
warranty of any kind. The Mind Electric hereby expressly disclaims all
warranties or conditions, either express or implied, including, but not limited
to, the implied warranties or conditions of merchantability and fitness for a
particular purpose. You are solely responsible for determining the
appropriateness of using Electric XML and assume all risks associated with the
use of it, including but not limited to the risks of program errors, damage to
or loss of data, programs or equipment, and unavailability or interruption of
operations. Some jurisdictions do not allow for the exclusion or limitation of
implied warranties, so the above limitations or exclusions may not apply to you.
The Mind Electric will not be liable for any direct damages or for any special,
incidental, or indirect damages or for any economic consequential damages
(including lost profits or savings), even if The Mind Electric has been advised
of the possibility of such damages. The Mind Electric will not be liable for the
loss of, or damage to, your records or data, or any damages claimed by you based
on a third party claim. Some jurisdictions do not allow for the exclusion or
limitation of incidental or consequential damages, so the above limitations or
exclusions may not apply to you.
4. General
This Agreement is governed by the laws of the State of Texas. This Agreement is
the only understanding and agreement we have regarding your use of Electric XML.
It supersedes all other communications, understandings or agreements we may have
had prior to this Agreement.

150
licenses/Google License.txt Normal file
View file

@ -0,0 +1,150 @@
Thank you for using the Google Web APIs (TM) service! By using this
service ("Google Web APIs") you agree to be bound by the following
terms and conditions (the "Terms and Conditions").
PERSONAL AND LEGITIMATE USES ONLY
The Google Web APIs service is made available to you for your
personal, non-commercial use only (at home or at work). You may only
create a single account and must provide accurate identification,
contact, and other information required as part of the registration
process. You may not create any script or other automated tool that
attempts to create multiple Google Web APIs accounts. And you may not
use the search results provided by the Google Web APIs service with an
existing product or service that competes with products or services
offered by Google.
If you are interested in doing anything different than the foregoing,
you must first obtain Google's written consent. If you fail to do so,
Google reserves the right to take legal action against you.
Furthermore, you may not use Google Web APIs in any manner that either
directly or indirectly violates any laws or proprietary rights. This
includes laws and proprietary rights in the United States as well as
in other countries.
If you have questions on your contemplated use or if you have comments
on Google Web APIs or ideas on how to improve it, please email
api-support@google.com. Please note that by doing so, you also grant
Google permission to use and incorporate your ideas or comments into
Google Web APIs without further compensation.
INTELLECTUAL PROPERTY
You agree not to remove, obscure, or alter Google's copyright notice,
trademarks, or other proprietary rights notices affixed to or
contained within Google Web APIs. You also acknowledge that Google
owns all right, title and interest in and to Google Web APIs,
including without limitation all intellectual property rights (the
"Google Rights"). The Google Rights include rights to the following:
(1) the APIs developed and provided by Google, (2) all software
associated with the Google Web APIs server, and (3) the search results
and spell checking you obtain when you use Google Web APIs. The Google
Rights do not include the following: (1) third party components used
as part of Google Web APIs; or (2) software developed by you in
conjunction with using Google Web APIs.
PUBLICITY
So long as you comply with your obligations under this Agreement, you
may indicate that a product or service that you created either used or
is based on Google Web APIs provided that those products or services
do not in Google's reasonable opinion (1) tarnish, infringe, or dilute
Google's trademarks, (2) violate any applicable law, and (3) infringe
any third party rights. If you wish to use the GOOGLE trademark and/or
logo in any other manner, you must first obtain Google's written
consent.
DISCLAIMER OF WARRANTIES
The Google Web APIs service is presently in Beta form and has not been
fully tested or debugged. Accordingly, Google disclaims any
responsibility for any harm resulting from your use of Google Web APIs.
The Google Web APIs service is provided "as is," with no warranties
whatsoever. Google expressly disclaims to the fullest extent permitted
by law all express, implied, and statutory warranties, including,
without limitation, the warranties of merchantability, fitness for a
particular purpose, and non-infringement of proprietary rights. Google
disclaims any warranties regarding the security, reliability,
timeliness, availability, and performance of Google Web APIs.
You understand and agree that you use Google Web APIs at your own
discretion and risk and that you will be solely responsible for any
damages to your computer system or loss of data that results from the
download or use of Google Web APIs.
Some states or other jurisdictions do not allow the exclusion of
implied warranties, so the above exclusions may not apply to you. You
may also have other rights that vary from state to state and
jurisdiction to jurisdiction.
LIMITATION OF LIABILITY
The Google Web APIs service is being provided free of charge.
Accordingly, you agree that Google shall have no liability arising
from or based on your use of Google Web APIs.
Under no circumstances shall Google be liable to any user on account
of that user's use or misuse of Google Web APIs. Such limitation of
liability shall apply to prevent recovery of direct, indirect,
incidental, consequential, special, exemplary, and punitive damages
whether such claim is based on warranty, contract, tort (including
negligence), or otherwise, even if Google has been advised of the
possibility of such damages). Such limitation of liability shall apply
whether the damages arise from use or misuse of and reliance on the
Google Web APIs, from inability to use Google Web APIs, or from the
interruption, suspension, or termination of Google Web APIs (including
such damages incurred by third parties). Such limitation shall apply
notwithstanding a failure of essential purpose of any limited remedy
and to the fullest extent permitted by law.
Some states or other jurisdictions do not allow the exclusion or
limitation of liability for incidental or consequential damages, so
the above limitations and exclusions may not apply to you.
INDEMNIFICATION
You hereby agree to indemnify, defend and hold Google, and its
officers, directors, agents, licensors and licensees (collectively,
the "Indemnified Parties") harmless from and against any and all
liability and costs incurred by the Indemnified Parties in connection
with any claim arising out of your use of Google Web APIs, including,
without limitation, reasonable attorneys' fees. You shall cooperate as
fully as reasonably required in the defense of any claim. Google
reserves the right, at its own expense, to assume the exclusive
defense and control of any matter subject to indemnification by you.
GOOGLE'S SEARCH SERVICE
The Google Web APIs service is designed to be used in conjunction with
Google's search services. Accordingly, your use of Google Web APIs is
also defined by Google's Terms of Service and Privacy Policy. In the
event of a conflict between these Terms and Conditions and Google's
Terms of Service, these Terms and Conditions shall prevail.
TERM AND TERMINATION
If you wish to terminate this Agreement, you may simply cease using
the Google Web APIs service. In such a case, you must delete any
search result information that you may have obtained from the Google
Web APIs service. Google may terminate this Agreement (and your
account) at any time, with or without cause.
GENERAL PROVISIONS
These Terms and Conditions will be governed by and construed in
accordance with the laws of the State of California, without giving
effect to the conflict of laws provisions of California or your actual
state or country of residence. Any dispute arising from these Terms
and Conditions shall be adjudicated in the federal or state courts
located in Santa Clara County, California. If for any reason a court
of competent jurisdiction finds any provision or portion of these
Terms and Conditions to be unenforceable, the remainder of these Terms
and Conditions will continue in full force and effect. These Terms and
Conditions constitute the entire agreement between the parties with
respect to the subject matter hereof and supersede and replace all
prior or contemporaneous understandings or agreements, written or
oral, regarding such subject matter. Any waiver of any provision of
these Terms and Conditions will be effective only if in writing and
signed by Google.

View file

@ -0,0 +1,29 @@
Google Tag Library License
Copyright (c) 2002-2003, Erik C. Thauvin (erik@thauvin.net)
All rights reserved.
Redistribution and use in source and binary forms, with or without modification,
are permitted provided that the following conditions are met:
Redistributions of source code must retain the above copyright notice, this list
of conditions and the following disclaimer.
Redistributions in binary form must reproduce the above copyright notice, this
list of conditions and the following disclaimer in the documentation and/or
other materials provided with the distribution.
Neither the name of the author nor the names of its contributors may be used to
endorse or promote products derived from this software without specific prior
written permission.
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.

54
licenses/JDOM License.txt Normal file
View file

@ -0,0 +1,54 @@
/*--
Copyright (C) 2000-2004 Jason Hunter & Brett McLaughlin.
All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions
are met:
1. Redistributions of source code must retain the above copyright
notice, this list of conditions, and the following disclaimer.
2. Redistributions in binary form must reproduce the above copyright
notice, this list of conditions, and the disclaimer that follows
these conditions in the documentation and/or other materials
provided with the distribution.
3. The name "JDOM" must not be used to endorse or promote products
derived from this software without prior written permission. For
written permission, please contact <request_AT_jdom_DOT_org>.
4. Products derived from this software may not be called "JDOM", nor
may "JDOM" appear in their name, without prior written permission
from the JDOM Project Management <request_AT_jdom_DOT_org>.
In addition, we request (but do not require) that you include in the
end-user documentation provided with the redistribution and/or in the
software itself an acknowledgement equivalent to the following:
"This product includes software developed by the
JDOM Project (http://www.jdom.org/)."
Alternatively, the acknowledgment may be graphical using the logos
available at http://www.jdom.org/images/logos.
THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
DISCLAIMED. IN NO EVENT SHALL THE JDOM AUTHORS OR THE PROJECT
CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
SUCH DAMAGE.
This software consists of voluntary contributions made by many
individuals on behalf of the JDOM Project and was originally
created by Jason Hunter <jhunter_AT_jdom_DOT_org> and
Brett McLaughlin <brett_AT_jdom_DOT_org>. For more information
on the JDOM Project, please see <http://www.jdom.org/>.
*/

View file

@ -0,0 +1,340 @@
GNU GENERAL PUBLIC LICENSE
Version 2, June 1991
Copyright (C) 1989, 1991 Free Software Foundation, Inc.
59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
Everyone is permitted to copy and distribute verbatim copies
of this license document, but changing it is not allowed.
Preamble
The licenses for most software are designed to take away your
freedom to share and change it. By contrast, the GNU General Public
License is intended to guarantee your freedom to share and change free
software--to make sure the software is free for all its users. This
General Public License applies to most of the Free Software
Foundation's software and to any other program whose authors commit to
using it. (Some other Free Software Foundation software is covered by
the GNU Library General Public License instead.) You can apply it to
your programs, too.
When we speak of free software, we are referring to freedom, not
price. Our General Public Licenses are designed to make sure that you
have the freedom to distribute copies of free software (and charge for
this service if you wish), that you receive source code or can get it
if you want it, that you can change the software or use pieces of it
in new free programs; and that you know you can do these things.
To protect your rights, we need to make restrictions that forbid
anyone to deny you these rights or to ask you to surrender the rights.
These restrictions translate to certain responsibilities for you if you
distribute copies of the software, or if you modify it.
For example, if you distribute copies of such a program, whether
gratis or for a fee, you must give the recipients all the rights that
you have. You must make sure that they, too, receive or can get the
source code. And you must show them these terms so they know their
rights.
We protect your rights with two steps: (1) copyright the software, and
(2) offer you this license which gives you legal permission to copy,
distribute and/or modify the software.
Also, for each author's protection and ours, we want to make certain
that everyone understands that there is no warranty for this free
software. If the software is modified by someone else and passed on, we
want its recipients to know that what they have is not the original, so
that any problems introduced by others will not reflect on the original
authors' reputations.
Finally, any free program is threatened constantly by software
patents. We wish to avoid the danger that redistributors of a free
program will individually obtain patent licenses, in effect making the
program proprietary. To prevent this, we have made it clear that any
patent must be licensed for everyone's free use or not licensed at all.
The precise terms and conditions for copying, distribution and
modification follow.
GNU GENERAL PUBLIC LICENSE
TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
0. This License applies to any program or other work which contains
a notice placed by the copyright holder saying it may be distributed
under the terms of this General Public License. The "Program", below,
refers to any such program or work, and a "work based on the Program"
means either the Program or any derivative work under copyright law:
that is to say, a work containing the Program or a portion of it,
either verbatim or with modifications and/or translated into another
language. (Hereinafter, translation is included without limitation in
the term "modification".) Each licensee is addressed as "you".
Activities other than copying, distribution and modification are not
covered by this License; they are outside its scope. The act of
running the Program is not restricted, and the output from the Program
is covered only if its contents constitute a work based on the
Program (independent of having been made by running the Program).
Whether that is true depends on what the Program does.
1. You may copy and distribute verbatim copies of the Program's
source code as you receive it, in any medium, provided that you
conspicuously and appropriately publish on each copy an appropriate
copyright notice and disclaimer of warranty; keep intact all the
notices that refer to this License and to the absence of any warranty;
and give any other recipients of the Program a copy of this License
along with the Program.
You may charge a fee for the physical act of transferring a copy, and
you may at your option offer warranty protection in exchange for a fee.
2. You may modify your copy or copies of the Program or any portion
of it, thus forming a work based on the Program, and copy and
distribute such modifications or work under the terms of Section 1
above, provided that you also meet all of these conditions:
a) You must cause the modified files to carry prominent notices
stating that you changed the files and the date of any change.
b) You must cause any work that you distribute or publish, that in
whole or in part contains or is derived from the Program or any
part thereof, to be licensed as a whole at no charge to all third
parties under the terms of this License.
c) If the modified program normally reads commands interactively
when run, you must cause it, when started running for such
interactive use in the most ordinary way, to print or display an
announcement including an appropriate copyright notice and a
notice that there is no warranty (or else, saying that you provide
a warranty) and that users may redistribute the program under
these conditions, and telling the user how to view a copy of this
License. (Exception: if the Program itself is interactive but
does not normally print such an announcement, your work based on
the Program is not required to print an announcement.)
These requirements apply to the modified work as a whole. If
identifiable sections of that work are not derived from the Program,
and can be reasonably considered independent and separate works in
themselves, then this License, and its terms, do not apply to those
sections when you distribute them as separate works. But when you
distribute the same sections as part of a whole which is a work based
on the Program, the distribution of the whole must be on the terms of
this License, whose permissions for other licensees extend to the
entire whole, and thus to each and every part regardless of who wrote it.
Thus, it is not the intent of this section to claim rights or contest
your rights to work written entirely by you; rather, the intent is to
exercise the right to control the distribution of derivative or
collective works based on the Program.
In addition, mere aggregation of another work not based on the Program
with the Program (or with a work based on the Program) on a volume of
a storage or distribution medium does not bring the other work under
the scope of this License.
3. You may copy and distribute the Program (or a work based on it,
under Section 2) in object code or executable form under the terms of
Sections 1 and 2 above provided that you also do one of the following:
a) Accompany it with the complete corresponding machine-readable
source code, which must be distributed under the terms of Sections
1 and 2 above on a medium customarily used for software interchange; or,
b) Accompany it with a written offer, valid for at least three
years, to give any third party, for a charge no more than your
cost of physically performing source distribution, a complete
machine-readable copy of the corresponding source code, to be
distributed under the terms of Sections 1 and 2 above on a medium
customarily used for software interchange; or,
c) Accompany it with the information you received as to the offer
to distribute corresponding source code. (This alternative is
allowed only for noncommercial distribution and only if you
received the program in object code or executable form with such
an offer, in accord with Subsection b above.)
The source code for a work means the preferred form of the work for
making modifications to it. For an executable work, complete source
code means all the source code for all modules it contains, plus any
associated interface definition files, plus the scripts used to
control compilation and installation of the executable. However, as a
special exception, the source code distributed need not include
anything that is normally distributed (in either source or binary
form) with the major components (compiler, kernel, and so on) of the
operating system on which the executable runs, unless that component
itself accompanies the executable.
If distribution of executable or object code is made by offering
access to copy from a designated place, then offering equivalent
access to copy the source code from the same place counts as
distribution of the source code, even though third parties are not
compelled to copy the source along with the object code.
4. You may not copy, modify, sublicense, or distribute the Program
except as expressly provided under this License. Any attempt
otherwise to copy, modify, sublicense or distribute the Program is
void, and will automatically terminate your rights under this License.
However, parties who have received copies, or rights, from you under
this License will not have their licenses terminated so long as such
parties remain in full compliance.
5. You are not required to accept this License, since you have not
signed it. However, nothing else grants you permission to modify or
distribute the Program or its derivative works. These actions are
prohibited by law if you do not accept this License. Therefore, by
modifying or distributing the Program (or any work based on the
Program), you indicate your acceptance of this License to do so, and
all its terms and conditions for copying, distributing or modifying
the Program or works based on it.
6. Each time you redistribute the Program (or any work based on the
Program), the recipient automatically receives a license from the
original licensor to copy, distribute or modify the Program subject to
these terms and conditions. You may not impose any further
restrictions on the recipients' exercise of the rights granted herein.
You are not responsible for enforcing compliance by third parties to
this License.
7. If, as a consequence of a court judgment or allegation of patent
infringement or for any other reason (not limited to patent issues),
conditions are imposed on you (whether by court order, agreement or
otherwise) that contradict the conditions of this License, they do not
excuse you from the conditions of this License. If you cannot
distribute so as to satisfy simultaneously your obligations under this
License and any other pertinent obligations, then as a consequence you
may not distribute the Program at all. For example, if a patent
license would not permit royalty-free redistribution of the Program by
all those who receive copies directly or indirectly through you, then
the only way you could satisfy both it and this License would be to
refrain entirely from distribution of the Program.
If any portion of this section is held invalid or unenforceable under
any particular circumstance, the balance of the section is intended to
apply and the section as a whole is intended to apply in other
circumstances.
It is not the purpose of this section to induce you to infringe any
patents or other property right claims or to contest validity of any
such claims; this section has the sole purpose of protecting the
integrity of the free software distribution system, which is
implemented by public license practices. Many people have made
generous contributions to the wide range of software distributed
through that system in reliance on consistent application of that
system; it is up to the author/donor to decide if he or she is willing
to distribute software through any other system and a licensee cannot
impose that choice.
This section is intended to make thoroughly clear what is believed to
be a consequence of the rest of this License.
8. If the distribution and/or use of the Program is restricted in
certain countries either by patents or by copyrighted interfaces, the
original copyright holder who places the Program under this License
may add an explicit geographical distribution limitation excluding
those countries, so that distribution is permitted only in or among
countries not thus excluded. In such case, this License incorporates
the limitation as if written in the body of this License.
9. The Free Software Foundation may publish revised and/or new versions
of the General Public License from time to time. Such new versions will
be similar in spirit to the present version, but may differ in detail to
address new problems or concerns.
Each version is given a distinguishing version number. If the Program
specifies a version number of this License which applies to it and "any
later version", you have the option of following the terms and conditions
either of that version or of any later version published by the Free
Software Foundation. If the Program does not specify a version number of
this License, you may choose any version ever published by the Free Software
Foundation.
10. If you wish to incorporate parts of the Program into other free
programs whose distribution conditions are different, write to the author
to ask for permission. For software which is copyrighted by the Free
Software Foundation, write to the Free Software Foundation; we sometimes
make exceptions for this. Our decision will be guided by the two goals
of preserving the free status of all derivatives of our free software and
of promoting the sharing and reuse of software generally.
NO WARRANTY
11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY
FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN
OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES
PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED
OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS
TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE
PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING,
REPAIR OR CORRECTION.
12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR
REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES,
INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING
OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED
TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY
YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER
PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE
POSSIBILITY OF SUCH DAMAGES.
END OF TERMS AND CONDITIONS
How to Apply These Terms to Your New Programs
If you develop a new program, and you want it to be of the greatest
possible use to the public, the best way to achieve this is to make it
free software which everyone can redistribute and change under these terms.
To do so, attach the following notices to the program. It is safest
to attach them to the start of each source file to most effectively
convey the exclusion of warranty; and each file should have at least
the "copyright" line and a pointer to where the full notice is found.
<one line to give the program's name and a brief idea of what it does.>
Copyright (C) <year> <name of author>
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
Also add information on how to contact you by electronic and paper mail.
If the program is interactive, make it output a short notice like this
when it starts in an interactive mode:
Gnomovision version 69, Copyright (C) year name of author
Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'.
This is free software, and you are welcome to redistribute it
under certain conditions; type `show c' for details.
The hypothetical commands `show w' and `show c' should show the appropriate
parts of the General Public License. Of course, the commands you use may
be called something other than `show w' and `show c'; they could even be
mouse-clicks or menu items--whatever suits your program.
You should also get your employer (if you work as a programmer) or your
school, if any, to sign a "copyright disclaimer" for the program, if
necessary. Here is a sample; alter the names:
Yoyodyne, Inc., hereby disclaims all copyright interest in the program
`Gnomovision' (which makes passes at compilers) written by James Hacker.
<signature of Ty Coon>, 1 April 1989
Ty Coon, President of Vice
This General Public License does not permit incorporating your program into
proprietary programs. If your program is a subroutine library, you may
consider it more useful to permit linking proprietary applications with the
library. If this is what you want to do, use the GNU Library General
Public License instead of this License.

29
licenses/License.txt Normal file
View file

@ -0,0 +1,29 @@
Mobibot License
Copyright (c) 2004, Erik C. Thauvin (erik@thauvin.net)
All rights reserved.
Redistribution and use in source and binary forms, with or without modification,
are permitted provided that the following conditions are met:
Redistributions of source code must retain the above copyright notice, this list
of conditions and the following disclaimer.
Redistributions in binary form must reproduce the above copyright notice, this
list of conditions and the following disclaimer in the documentation and/or
other materials provided with the distribution.
Neither the name of the author nor the names of its contributors may be used to
endorse or promote products derived from this software without specific prior
written permission.
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.

View file

@ -0,0 +1,48 @@
/*
* ============================================================================
* The Apache Software License, Version 1.1
* ============================================================================
*
* Copyright (C) 1999 The Apache Software Foundation. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without modifica-
* tion, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright notice,
* this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* 3. The end-user documentation included with the redistribution, if any, must
* include the following acknowledgment: "This product includes software
* developed by the Apache Software Foundation (http://www.apache.org/)."
* Alternately, this acknowledgment may appear in the software itself, if
* and wherever such third-party acknowledgments normally appear.
*
* 4. The names "log4j" and "Apache Software Foundation" must not be used to
* endorse or promote products derived from this software without prior
* written permission. For written permission, please contact
* apache@apache.org.
*
* 5. Products derived from this software may not be called "Apache", nor may
* "Apache" appear in their name, without prior written permission of the
* Apache Software Foundation.
*
* THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED WARRANTIES,
* INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
* FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
* APACHE SOFTWARE FOUNDATION OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT,
* INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLU-
* DING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
* OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
* ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
* THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*
* This software consists of voluntary contributions made by many individuals
* on behalf of the Apache Software Foundation. For more information on the
* Apache Software Foundation, please see <http://www.apache.org/>.
*
*/

View file

@ -0,0 +1,60 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html>
<head>
<title>The GNU General Public License (GPL)</title>
</head>
<body>
<h1>The GNU General Public License (GPL)</h1>
<h2>Version 2, June 1991</h2>
<p> Copyright (C) 1989, 1991 Free Software Foundation, Inc.<br />
59 Temple Place, Suite 330, Boston, MA 02111-1307 USA</p>
<p> Everyone is permitted to copy and distribute verbatim copies<br />
of this license document, but changing it is not allowed.</p>
<p><strong>Preamble</strong></p>
<p>The licenses for most software are designed to take away your freedom to share and change it. By contrast, the GNU General Public License is intended to guarantee your freedom to share and change free software--to make sure the software is free for all its users. This General Public License applies to most of the Free Software Foundation's software and to any other program whose authors commit to using it. (Some other Free Software Foundation software is covered by the GNU Library General Public License instead.) You can apply it to your programs, too.</p>
<p>When we speak of free software, we are referring to freedom, not price. Our General Public Licenses are designed to make sure that you have the freedom to distribute copies of free software (and charge for this service if you wish), that you receive source code or can get it if you want it, that you can change the software or use pieces of it in new free programs; and that you know you can do these things.</p>
<p> To protect your rights, we need to make restrictions that forbid anyone to deny you these rights or to ask you to surrender the rights. These restrictions translate to certain responsibilities for you if you distribute copies of the software, or if you modify it.</p>
<p>For example, if you distribute copies of such a program, whether gratis or for a fee, you must give the recipients all the rights that you have. You must make sure that they, too, receive or can get the source code. And you must show them these terms so they know their rights.</p>
<p>We protect your rights with two steps: (1) copyright the software, and (2) offer you this license which gives you legal permission to copy, distribute and/or modify the software.</p>
<p>Also, for each author's protection and ours, we want to make certain that everyone understands that there is no warranty for this free software. If the software is modified by someone else and passed on, we want its recipients to know that what they have is not the original, so that any problems introduced by others will not reflect on the original authors' reputations.</p>
<p>Finally, any free program is threatened constantly by software patents. We wish to avoid the danger that redistributors of a free program will individually obtain patent licenses, in effect making the program proprietary. To prevent this, we have made it clear that any patent must be licensed for everyone's free use or not licensed at all.</p>
<p>The precise terms and conditions for copying, distribution and modification follow.</p>
<p><strong>TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION</strong></p>
<p><strong>0</strong>. This License applies to any program or other work which contains a notice placed by the copyright holder saying it may be distributed under the terms of this General Public License. The "Program", below, refers to any such program or work, and a "work based on the Program" means either the Program or any derivative work under copyright law: that is to say, a work containing the Program or a portion of it, either verbatim or with modifications and/or translated into another language. (Hereinafter, translation is included without limitation in the term "modification".) Each licensee is addressed as "you".</p>
<p>Activities other than copying, distribution and modification are not covered by this License; they are outside its scope. The act of running the Program is not restricted, and the output from the Program is covered only if its contents constitute a work based on the Program (independent of having been made by running the Program). Whether that is true depends on what the Program does.</p>
<p><strong>1</strong>. You may copy and distribute verbatim copies of the Program's source code as you receive it, in any medium, provided that you conspicuously and appropriately publish on each copy an appropriate copyright notice and disclaimer of warranty; keep intact all the notices that refer to this License and to the absence of any warranty; and give any other recipients of the Program a copy of this License along with the Program.</p>
<p>You may charge a fee for the physical act of transferring a copy, and you may at your option offer warranty protection in exchange for a fee.</p>
<p> <strong>2</strong>. You may modify your copy or copies of the Program or any portion of it, thus forming a work based on the Program, and copy and distribute such modifications or work under the terms of Section 1 above, provided that you also meet all of these conditions:</p>
<blockquote>
<p>a) You must cause the modified files to carry prominent notices stating that you changed the files and the date of any change.</p>
<p>b) You must cause any work that you distribute or publish, that in whole or in part contains or is derived from the Program or any part thereof, to be licensed as a whole at no charge to all third parties under the terms of this License.</p>
<p>c) If the modified program normally reads commands interactively when run, you must cause it, when started running for such interactive use in the most ordinary way, to print or display an announcement including an appropriate copyright notice and a notice that there is no warranty (or else, saying that you provide a warranty) and that users may redistribute the program under these conditions, and telling the user how to view a copy of this License. (Exception: if the Program itself is interactive but does not normally print such an announcement, your work based on the Program is not required to print an announcement.)</p>
</blockquote>
<p>These requirements apply to the modified work as a whole. If identifiable sections of that work are not derived from the Program, and can be reasonably considered independent and separate works in themselves, then this License, and its terms, do not apply to those sections when you distribute them as separate works. But when you distribute the same sections as part of a whole which is a work based on the Program, the distribution of the whole must be on the terms of this License, whose permissions for other licensees extend to the entire whole, and thus to each and every part regardless of who wrote it.</p>
<p>Thus, it is not the intent of this section to claim rights or contest your rights to work written entirely by you; rather, the intent is to exercise the right to control the distribution of derivative or collective works based on the Program.</p>
<p>In addition, mere aggregation of another work not based on the Program with the Program (or with a work based on the Program) on a volume of a storage or distribution medium does not bring the other work under the scope of this License.</p>
<p><strong>3</strong>. You may copy and distribute the Program (or a work based on it, under Section 2) in object code or executable form under the terms of Sections 1 and 2 above provided that you also do one of the following:</p>
<blockquote>
<p>a) Accompany it with the complete corresponding machine-readable source code, which must be distributed under the terms of Sections 1 and 2 above on a medium customarily used for software interchange; or,</p>
<p> b) Accompany it with a written offer, valid for at least three years, to give any third party, for a charge no more than your cost of physically performing source distribution, a complete machine-readable copy of the corresponding source code, to be distributed under the terms of Sections 1 and 2 above on a medium customarily used for software interchange; or,</p>
<p>c) Accompany it with the information you received as to the offer to distribute corresponding source code. (This alternative is allowed only for noncommercial distribution and only if you received the program in object code or executable form with such an offer, in accord with Subsection b above.)</p>
</blockquote>
<p>The source code for a work means the preferred form of the work for making modifications to it. For an executable work, complete source code means all the source code for all modules it contains, plus any associated interface definition files, plus the scripts used to control compilation and installation of the executable. However, as a special exception, the source code distributed need not include anything that is normally distributed (in either source or binary form) with the major components (compiler, kernel, and so on) of the operating system on which the executable runs, unless that component itself accompanies the executable.</p>
<p>If distribution of executable or object code is made by offering access to copy from a designated place, then offering equivalent access to copy the source code from the same place counts as distribution of the source code, even though third parties are not compelled to copy the source along with the object code.</p>
<p><strong>4</strong>. You may not copy, modify, sublicense, or distribute the Program except as expressly provided under this License. Any attempt otherwise to copy, modify, sublicense or distribute the Program is void, and will automatically terminate your rights under this License. However, parties who have received copies, or rights, from you under this License will not have their licenses terminated so long as such parties remain in full compliance.</p>
<p> <strong>5</strong>. You are not required to accept this License, since you have not signed it. However, nothing else grants you permission to modify or distribute the Program or its derivative works. These actions are prohibited by law if you do not accept this License. Therefore, by modifying or distributing the Program (or any work based on the Program), you indicate your acceptance of this License to do so, and all its terms and conditions for copying, distributing or modifying the Program or works based on it.</p>
<p><strong>6</strong>. Each time you redistribute the Program (or any work based on the Program), the recipient automatically receives a license from the original licensor to copy, distribute or modify the Program subject to these terms and conditions. You may not impose any further restrictions on the recipients' exercise of the rights granted herein. You are not responsible for enforcing compliance by third parties to this License.</p>
<p><strong>7</strong>. If, as a consequence of a court judgment or allegation of patent infringement or for any other reason (not limited to patent issues), conditions are imposed on you (whether by court order, agreement or otherwise) that contradict the conditions of this License, they do not excuse you from the conditions of this License. If you cannot distribute so as to satisfy simultaneously your obligations under this License and any other pertinent obligations, then as a consequence you may not distribute the Program at all. For example, if a patent license would not permit royalty-free redistribution of the Program by all those who receive copies directly or indirectly through you, then the only way you could satisfy both it and this License would be to refrain entirely from distribution of the Program.</p>
<p>If any portion of this section is held invalid or unenforceable under any particular circumstance, the balance of the section is intended to apply and the section as a whole is intended to apply in other circumstances.</p>
<p>It is not the purpose of this section to induce you to infringe any patents or other property right claims or to contest validity of any such claims; this section has the sole purpose of protecting the integrity of the free software distribution system, which is implemented by public license practices. Many people have made generous contributions to the wide range of software distributed through that system in reliance on consistent application of that system; it is up to the author/donor to decide if he or she is willing to distribute software through any other system and a licensee cannot impose that choice.</p>
<p> This section is intended to make thoroughly clear what is believed to be a consequence of the rest of this License.</p>
<p> <strong>8</strong>. If the distribution and/or use of the Program is restricted in certain countries either by patents or by copyrighted interfaces, the original copyright holder who places the Program under this License may add an explicit geographical distribution limitation excluding those countries, so that distribution is permitted only in or among countries not thus excluded. In such case, this License incorporates the limitation as if written in the body of this License.</p>
<p> <strong>9</strong>. The Free Software Foundation may publish revised and/or new versions of the General Public License from time to time. Such new versions will be similar in spirit to the present version, but may differ in detail to address new problems or concerns.</p>
<p>Each version is given a distinguishing version number. If the Program specifies a version number of this License which applies to it and "any later version", you have the option of following the terms and conditions either of that version or of any later version published by the Free Software Foundation. If the Program does not specify a version number of this License, you may choose any version ever published by the Free Software Foundation.</p>
<p><strong>10</strong>. If you wish to incorporate parts of the Program into other free programs whose distribution conditions are different, write to the author to ask for permission. For software which is copyrighted by the Free Software Foundation, write to the Free Software Foundation; we sometimes make exceptions for this. Our decision will be guided by the two goals of preserving the free status of all derivatives of our free software and of promoting the sharing and reuse of software generally.</p>
<p><strong>NO WARRANTY</strong></p>
<p><strong>11</strong>. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, REPAIR OR CORRECTION.</p>
<p><strong>12</strong>. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES.</p>
<p>END OF TERMS AND CONDITIONS</p>
</body>
</html>

View file

@ -0,0 +1,83 @@
Apache Software License
Version 1.1
Copyright (c) 2000 The Apache Software Foundation. All rights reserved.
Redistribution and use in source and binary forms, with or without modification,
are permitted provided that the following conditions are met:
1. Redistributions of source code must retain the above copyright notice, this
list of conditions and the following disclaimer.
2. Redistributions in binary form must reproduce the above copyright notice,
this list of conditions and the following disclaimer in the documentation and/or
other materials provided with the distribution.
3. The end-user documentation included with the redistribution, if any, must
include the following acknowledgment:
"This product includes software developed by the Apache Software Foundation
(http://www.apache.org/)."
Alternately, this acknowledgment may appear in the software itself, if and
wherever such third-party acknowledgments normally appear.
4. The names "Apache" and "Apache Software Foundation" must not be used to
endorse or promote products derived from this software without prior written
permission. For written permission, please contact apache@apache.org.
5. Products derived from this software may not be called "Apache", nor may
"Apache" appear in their name, without prior written permission of the Apache
Software Foundation.
THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESSED OR IMPLIED WARRANTIES,
INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE APACHE
SOFTWARE FOUNDATION OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
--------------------------------------------------------------------------------
This software consists of voluntary contributions made by many individuals on
behalf of the Apache Software Foundation. For more information on the Apache
Software Foundation, please see <http://www.apache.org/>.
Portions of this software are based upon public domain software originally
written at the National Center for Supercomputing Applications, University of
Illinois, Urbana-Champaign.
Electric XML is owned by The Mind Electric and is copyrighted and licensed, not
sold. The Mind Electric grants you a non-exclusive, non-transferable license to
use, modify and distribute Electric XML in both binary and source form as long
as all of the following conditions are met:
You are not bundling Electric XML or a derivative of it as part of a software
development environment such as JBuilder, WebGain or VisualAge. Note that this
restriction is targeted at IDE vendors, and does not prevent developers from
loading Electric XML into an IDE and using it during everyday development.
You are not integrating Electric XML or a derivative of it into a distributed
computing infrastructure or database platform such as WebLogic, Apache SOAP,
WebSphere, Oracle application server, or HP e-speak. Note that this restriction
is targeted at software infrastructure vendors, and does not prevent developers
from using and bundling Electric XML with applications that run on these
platforms.
You are not integrating Electric XML or a derivative of it into an alternative
to Electric XML such as Xerces or JDOM.
You must not remove any of the copyright information from the Electric XML
source code or documentation.

View file

@ -0,0 +1,502 @@
GNU LESSER GENERAL PUBLIC LICENSE
Version 2.1, February 1999
Copyright (C) 1991, 1999 Free Software Foundation, Inc.
59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
Everyone is permitted to copy and distribute verbatim copies
of this license document, but changing it is not allowed.
[This is the first released version of the Lesser GPL. It also counts
as the successor of the GNU Library Public License, version 2, hence
the version number 2.1.]
Preamble
The licenses for most software are designed to take away your
freedom to share and change it. By contrast, the GNU General Public
Licenses are intended to guarantee your freedom to share and change
free software--to make sure the software is free for all its users.
This license, the Lesser General Public License, applies to some
specially designated software packages--typically libraries--of the
Free Software Foundation and other authors who decide to use it. You
can use it too, but we suggest you first think carefully about whether
this license or the ordinary General Public License is the better
strategy to use in any particular case, based on the explanations below.
When we speak of free software, we are referring to freedom of use,
not price. Our General Public Licenses are designed to make sure that
you have the freedom to distribute copies of free software (and charge
for this service if you wish); that you receive source code or can get
it if you want it; that you can change the software and use pieces of
it in new free programs; and that you are informed that you can do
these things.
To protect your rights, we need to make restrictions that forbid
distributors to deny you these rights or to ask you to surrender these
rights. These restrictions translate to certain responsibilities for
you if you distribute copies of the library or if you modify it.
For example, if you distribute copies of the library, whether gratis
or for a fee, you must give the recipients all the rights that we gave
you. You must make sure that they, too, receive or can get the source
code. If you link other code with the library, you must provide
complete object files to the recipients, so that they can relink them
with the library after making changes to the library and recompiling
it. And you must show them these terms so they know their rights.
We protect your rights with a two-step method: (1) we copyright the
library, and (2) we offer you this license, which gives you legal
permission to copy, distribute and/or modify the library.
To protect each distributor, we want to make it very clear that
there is no warranty for the free library. Also, if the library is
modified by someone else and passed on, the recipients should know
that what they have is not the original version, so that the original
author's reputation will not be affected by problems that might be
introduced by others.
Finally, software patents pose a constant threat to the existence of
any free program. We wish to make sure that a company cannot
effectively restrict the users of a free program by obtaining a
restrictive license from a patent holder. Therefore, we insist that
any patent license obtained for a version of the library must be
consistent with the full freedom of use specified in this license.
Most GNU software, including some libraries, is covered by the
ordinary GNU General Public License. This license, the GNU Lesser
General Public License, applies to certain designated libraries, and
is quite different from the ordinary General Public License. We use
this license for certain libraries in order to permit linking those
libraries into non-free programs.
When a program is linked with a library, whether statically or using
a shared library, the combination of the two is legally speaking a
combined work, a derivative of the original library. The ordinary
General Public License therefore permits such linking only if the
entire combination fits its criteria of freedom. The Lesser General
Public License permits more lax criteria for linking other code with
the library.
We call this license the "Lesser" General Public License because it
does Less to protect the user's freedom than the ordinary General
Public License. It also provides other free software developers Less
of an advantage over competing non-free programs. These disadvantages
are the reason we use the ordinary General Public License for many
libraries. However, the Lesser license provides advantages in certain
special circumstances.
For example, on rare occasions, there may be a special need to
encourage the widest possible use of a certain library, so that it becomes
a de-facto standard. To achieve this, non-free programs must be
allowed to use the library. A more frequent case is that a free
library does the same job as widely used non-free libraries. In this
case, there is little to gain by limiting the free library to free
software only, so we use the Lesser General Public License.
In other cases, permission to use a particular library in non-free
programs enables a greater number of people to use a large body of
free software. For example, permission to use the GNU C Library in
non-free programs enables many more people to use the whole GNU
operating system, as well as its variant, the GNU/Linux operating
system.
Although the Lesser General Public License is Less protective of the
users' freedom, it does ensure that the user of a program that is
linked with the Library has the freedom and the wherewithal to run
that program using a modified version of the Library.
The precise terms and conditions for copying, distribution and
modification follow. Pay close attention to the difference between a
"work based on the library" and a "work that uses the library". The
former contains code derived from the library, whereas the latter must
be combined with the library in order to run.
GNU LESSER GENERAL PUBLIC LICENSE
TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
0. This License Agreement applies to any software library or other
program which contains a notice placed by the copyright holder or
other authorized party saying it may be distributed under the terms of
this Lesser General Public License (also called "this License").
Each licensee is addressed as "you".
A "library" means a collection of software functions and/or data
prepared so as to be conveniently linked with application programs
(which use some of those functions and data) to form executables.
The "Library", below, refers to any such software library or work
which has been distributed under these terms. A "work based on the
Library" means either the Library or any derivative work under
copyright law: that is to say, a work containing the Library or a
portion of it, either verbatim or with modifications and/or translated
straightforwardly into another language. (Hereinafter, translation is
included without limitation in the term "modification".)
"Source code" for a work means the preferred form of the work for
making modifications to it. For a library, complete source code means
all the source code for all modules it contains, plus any associated
interface definition files, plus the scripts used to control compilation
and installation of the library.
Activities other than copying, distribution and modification are not
covered by this License; they are outside its scope. The act of
running a program using the Library is not restricted, and output from
such a program is covered only if its contents constitute a work based
on the Library (independent of the use of the Library in a tool for
writing it). Whether that is true depends on what the Library does
and what the program that uses the Library does.
1. You may copy and distribute verbatim copies of the Library's
complete source code as you receive it, in any medium, provided that
you conspicuously and appropriately publish on each copy an
appropriate copyright notice and disclaimer of warranty; keep intact
all the notices that refer to this License and to the absence of any
warranty; and distribute a copy of this License along with the
Library.
You may charge a fee for the physical act of transferring a copy,
and you may at your option offer warranty protection in exchange for a
fee.
2. You may modify your copy or copies of the Library or any portion
of it, thus forming a work based on the Library, and copy and
distribute such modifications or work under the terms of Section 1
above, provided that you also meet all of these conditions:
a) The modified work must itself be a software library.
b) You must cause the files modified to carry prominent notices
stating that you changed the files and the date of any change.
c) You must cause the whole of the work to be licensed at no
charge to all third parties under the terms of this License.
d) If a facility in the modified Library refers to a function or a
table of data to be supplied by an application program that uses
the facility, other than as an argument passed when the facility
is invoked, then you must make a good faith effort to ensure that,
in the event an application does not supply such function or
table, the facility still operates, and performs whatever part of
its purpose remains meaningful.
(For example, a function in a library to compute square roots has
a purpose that is entirely well-defined independent of the
application. Therefore, Subsection 2d requires that any
application-supplied function or table used by this function must
be optional: if the application does not supply it, the square
root function must still compute square roots.)
These requirements apply to the modified work as a whole. If
identifiable sections of that work are not derived from the Library,
and can be reasonably considered independent and separate works in
themselves, then this License, and its terms, do not apply to those
sections when you distribute them as separate works. But when you
distribute the same sections as part of a whole which is a work based
on the Library, the distribution of the whole must be on the terms of
this License, whose permissions for other licensees extend to the
entire whole, and thus to each and every part regardless of who wrote
it.
Thus, it is not the intent of this section to claim rights or contest
your rights to work written entirely by you; rather, the intent is to
exercise the right to control the distribution of derivative or
collective works based on the Library.
In addition, mere aggregation of another work not based on the Library
with the Library (or with a work based on the Library) on a volume of
a storage or distribution medium does not bring the other work under
the scope of this License.
3. You may opt to apply the terms of the ordinary GNU General Public
License instead of this License to a given copy of the Library. To do
this, you must alter all the notices that refer to this License, so
that they refer to the ordinary GNU General Public License, version 2,
instead of to this License. (If a newer version than version 2 of the
ordinary GNU General Public License has appeared, then you can specify
that version instead if you wish.) Do not make any other change in
these notices.
Once this change is made in a given copy, it is irreversible for
that copy, so the ordinary GNU General Public License applies to all
subsequent copies and derivative works made from that copy.
This option is useful when you wish to copy part of the code of
the Library into a program that is not a library.
4. You may copy and distribute the Library (or a portion or
derivative of it, under Section 2) in object code or executable form
under the terms of Sections 1 and 2 above provided that you accompany
it with the complete corresponding machine-readable source code, which
must be distributed under the terms of Sections 1 and 2 above on a
medium customarily used for software interchange.
If distribution of object code is made by offering access to copy
from a designated place, then offering equivalent access to copy the
source code from the same place satisfies the requirement to
distribute the source code, even though third parties are not
compelled to copy the source along with the object code.
5. A program that contains no derivative of any portion of the
Library, but is designed to work with the Library by being compiled or
linked with it, is called a "work that uses the Library". Such a
work, in isolation, is not a derivative work of the Library, and
therefore falls outside the scope of this License.
However, linking a "work that uses the Library" with the Library
creates an executable that is a derivative of the Library (because it
contains portions of the Library), rather than a "work that uses the
library". The executable is therefore covered by this License.
Section 6 states terms for distribution of such executables.
When a "work that uses the Library" uses material from a header file
that is part of the Library, the object code for the work may be a
derivative work of the Library even though the source code is not.
Whether this is true is especially significant if the work can be
linked without the Library, or if the work is itself a library. The
threshold for this to be true is not precisely defined by law.
If such an object file uses only numerical parameters, data
structure layouts and accessors, and small macros and small inline
functions (ten lines or less in length), then the use of the object
file is unrestricted, regardless of whether it is legally a derivative
work. (Executables containing this object code plus portions of the
Library will still fall under Section 6.)
Otherwise, if the work is a derivative of the Library, you may
distribute the object code for the work under the terms of Section 6.
Any executables containing that work also fall under Section 6,
whether or not they are linked directly with the Library itself.
6. As an exception to the Sections above, you may also combine or
link a "work that uses the Library" with the Library to produce a
work containing portions of the Library, and distribute that work
under terms of your choice, provided that the terms permit
modification of the work for the customer's own use and reverse
engineering for debugging such modifications.
You must give prominent notice with each copy of the work that the
Library is used in it and that the Library and its use are covered by
this License. You must supply a copy of this License. If the work
during execution displays copyright notices, you must include the
copyright notice for the Library among them, as well as a reference
directing the user to the copy of this License. Also, you must do one
of these things:
a) Accompany the work with the complete corresponding
machine-readable source code for the Library including whatever
changes were used in the work (which must be distributed under
Sections 1 and 2 above); and, if the work is an executable linked
with the Library, with the complete machine-readable "work that
uses the Library", as object code and/or source code, so that the
user can modify the Library and then relink to produce a modified
executable containing the modified Library. (It is understood
that the user who changes the contents of definitions files in the
Library will not necessarily be able to recompile the application
to use the modified definitions.)
b) Use a suitable shared library mechanism for linking with the
Library. A suitable mechanism is one that (1) uses at run time a
copy of the library already present on the user's computer system,
rather than copying library functions into the executable, and (2)
will operate properly with a modified version of the library, if
the user installs one, as long as the modified version is
interface-compatible with the version that the work was made with.
c) Accompany the work with a written offer, valid for at
least three years, to give the same user the materials
specified in Subsection 6a, above, for a charge no more
than the cost of performing this distribution.
d) If distribution of the work is made by offering access to copy
from a designated place, offer equivalent access to copy the above
specified materials from the same place.
e) Verify that the user has already received a copy of these
materials or that you have already sent this user a copy.
For an executable, the required form of the "work that uses the
Library" must include any data and utility programs needed for
reproducing the executable from it. However, as a special exception,
the materials to be distributed need not include anything that is
normally distributed (in either source or binary form) with the major
components (compiler, kernel, and so on) of the operating system on
which the executable runs, unless that component itself accompanies
the executable.
It may happen that this requirement contradicts the license
restrictions of other proprietary libraries that do not normally
accompany the operating system. Such a contradiction means you cannot
use both them and the Library together in an executable that you
distribute.
7. You may place library facilities that are a work based on the
Library side-by-side in a single library together with other library
facilities not covered by this License, and distribute such a combined
library, provided that the separate distribution of the work based on
the Library and of the other library facilities is otherwise
permitted, and provided that you do these two things:
a) Accompany the combined library with a copy of the same work
based on the Library, uncombined with any other library
facilities. This must be distributed under the terms of the
Sections above.
b) Give prominent notice with the combined library of the fact
that part of it is a work based on the Library, and explaining
where to find the accompanying uncombined form of the same work.
8. You may not copy, modify, sublicense, link with, or distribute
the Library except as expressly provided under this License. Any
attempt otherwise to copy, modify, sublicense, link with, or
distribute the Library is void, and will automatically terminate your
rights under this License. However, parties who have received copies,
or rights, from you under this License will not have their licenses
terminated so long as such parties remain in full compliance.
9. You are not required to accept this License, since you have not
signed it. However, nothing else grants you permission to modify or
distribute the Library or its derivative works. These actions are
prohibited by law if you do not accept this License. Therefore, by
modifying or distributing the Library (or any work based on the
Library), you indicate your acceptance of this License to do so, and
all its terms and conditions for copying, distributing or modifying
the Library or works based on it.
10. Each time you redistribute the Library (or any work based on the
Library), the recipient automatically receives a license from the
original licensor to copy, distribute, link with or modify the Library
subject to these terms and conditions. You may not impose any further
restrictions on the recipients' exercise of the rights granted herein.
You are not responsible for enforcing compliance by third parties with
this License.
11. If, as a consequence of a court judgment or allegation of patent
infringement or for any other reason (not limited to patent issues),
conditions are imposed on you (whether by court order, agreement or
otherwise) that contradict the conditions of this License, they do not
excuse you from the conditions of this License. If you cannot
distribute so as to satisfy simultaneously your obligations under this
License and any other pertinent obligations, then as a consequence you
may not distribute the Library at all. For example, if a patent
license would not permit royalty-free redistribution of the Library by
all those who receive copies directly or indirectly through you, then
the only way you could satisfy both it and this License would be to
refrain entirely from distribution of the Library.
If any portion of this section is held invalid or unenforceable under any
particular circumstance, the balance of the section is intended to apply,
and the section as a whole is intended to apply in other circumstances.
It is not the purpose of this section to induce you to infringe any
patents or other property right claims or to contest validity of any
such claims; this section has the sole purpose of protecting the
integrity of the free software distribution system which is
implemented by public license practices. Many people have made
generous contributions to the wide range of software distributed
through that system in reliance on consistent application of that
system; it is up to the author/donor to decide if he or she is willing
to distribute software through any other system and a licensee cannot
impose that choice.
This section is intended to make thoroughly clear what is believed to
be a consequence of the rest of this License.
12. If the distribution and/or use of the Library is restricted in
certain countries either by patents or by copyrighted interfaces, the
original copyright holder who places the Library under this License may add
an explicit geographical distribution limitation excluding those countries,
so that distribution is permitted only in or among countries not thus
excluded. In such case, this License incorporates the limitation as if
written in the body of this License.
13. The Free Software Foundation may publish revised and/or new
versions of the Lesser General Public License from time to time.
Such new versions will be similar in spirit to the present version,
but may differ in detail to address new problems or concerns.
Each version is given a distinguishing version number. If the Library
specifies a version number of this License which applies to it and
"any later version", you have the option of following the terms and
conditions either of that version or of any later version published by
the Free Software Foundation. If the Library does not specify a
license version number, you may choose any version ever published by
the Free Software Foundation.
14. If you wish to incorporate parts of the Library into other free
programs whose distribution conditions are incompatible with these,
write to the author to ask for permission. For software which is
copyrighted by the Free Software Foundation, write to the Free
Software Foundation; we sometimes make exceptions for this. Our
decision will be guided by the two goals of preserving the free status
of all derivatives of our free software and of promoting the sharing
and reuse of software generally.
NO WARRANTY
15. BECAUSE THE LIBRARY IS LICENSED FREE OF CHARGE, THERE IS NO
WARRANTY FOR THE LIBRARY, TO THE EXTENT PERMITTED BY APPLICABLE LAW.
EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR
OTHER PARTIES PROVIDE THE LIBRARY "AS IS" WITHOUT WARRANTY OF ANY
KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE
IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE
LIBRARY IS WITH YOU. SHOULD THE LIBRARY PROVE DEFECTIVE, YOU ASSUME
THE COST OF ALL NECESSARY SERVICING, REPAIR OR CORRECTION.
16. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN
WRITING WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY
AND/OR REDISTRIBUTE THE LIBRARY AS PERMITTED ABOVE, BE LIABLE TO YOU
FOR DAMAGES, INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR
CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OR INABILITY TO USE THE
LIBRARY (INCLUDING BUT NOT LIMITED TO LOSS OF DATA OR DATA BEING
RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD PARTIES OR A
FAILURE OF THE LIBRARY TO OPERATE WITH ANY OTHER SOFTWARE), EVEN IF
SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH
DAMAGES.
END OF TERMS AND CONDITIONS
How to Apply These Terms to Your New Libraries
If you develop a new library, and you want it to be of the greatest
possible use to the public, we recommend making it free software that
everyone can redistribute and change. You can do so by permitting
redistribution under these terms (or, alternatively, under the terms of the
ordinary General Public License).
To apply these terms, attach the following notices to the library. It is
safest to attach them to the start of each source file to most effectively
convey the exclusion of warranty; and each file should have at least the
"copyright" line and a pointer to where the full notice is found.
<one line to give the library's name and a brief idea of what it does.>
Copyright (C) <year> <name of author>
This library is free software; you can redistribute it and/or
modify it under the terms of the GNU Lesser General Public
License as published by the Free Software Foundation; either
version 2.1 of the License, or (at your option) any later version.
This library is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
Lesser General Public License for more details.
You should have received a copy of the GNU Lesser General Public
License along with this library; if not, write to the Free Software
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
Also add information on how to contact you by electronic and paper mail.
You should also get your employer (if you work as a programmer) or your
school, if any, to sign a "copyright disclaimer" for the library, if
necessary. Here is a sample; alter the names:
Yoyodyne, Inc., hereby disclaims all copyright interest in the
library `Frob' (a library for tweaking knobs) written by James Random Hacker.
<signature of Ty Coon>, 1 April 1990
Ty Coon, President of Vice
That's all there is to it!

20
mobibot.fb Normal file
View file

@ -0,0 +1,20 @@
[Jar files]
D:\projects\java\mobibot\build
[Source dirs]
D:\projects\java\mobibot\src
[Aux classpath entries]
D:\projects\java\mobibot\lib\commons-httpclient-2.0-final.jar
D:\projects\java\mobibot\lib\commons-logging.jar
D:\projects\java\mobibot\lib\commons-net-1.1.0.jar
D:\projects\java\mobibot\lib\EXML.jar
D:\projects\java\mobibot\lib\fetchrss.jar
D:\projects\java\mobibot\lib\google.jar
D:\projects\java\mobibot\lib\googleapi.jar
D:\projects\java\mobibot\lib\jakarta-oro-2.0.7.jar
D:\projects\java\mobibot\lib\jakarta-oro-2.0.8.jar
D:\projects\java\mobibot\lib\jdom.jar
D:\projects\java\mobibot\lib\jweather-0.2.3.jar
D:\projects\java\mobibot\lib\log4j-1.2.8.jar
D:\projects\java\mobibot\lib\MathEvaluator.jar
D:\projects\java\mobibot\lib\pircbot.jar
D:\projects\java\mobibot\lib\rsslibj.jar

149
mobibot.iml Normal file
View file

@ -0,0 +1,149 @@
<?xml version="1.0" encoding="UTF-8"?>
<module version="4" relativePaths="false">
<component name="ModuleRootManager" />
<component name="NewModuleRootManager">
<output url="file://$MODULE_DIR$/build" />
<exclude-output />
<content url="file://$MODULE_DIR$">
<sourceFolder url="file://$MODULE_DIR$/src" isTestSource="false" />
</content>
<orderEntry type="inheritedJdk" />
<orderEntry type="sourceFolder" forTests="false" />
<orderEntry type="module-library">
<library>
<CLASSES>
<root url="jar://$MODULE_DIR$/lib/fetchrss.jar!/" />
</CLASSES>
<JAVADOC />
<SOURCES />
</library>
</orderEntry>
<orderEntry type="module-library">
<library>
<CLASSES>
<root url="jar://$MODULE_DIR$/lib/jdom.jar!/" />
</CLASSES>
<JAVADOC />
<SOURCES />
</library>
</orderEntry>
<orderEntry type="module-library">
<library>
<CLASSES>
<root url="jar://$MODULE_DIR$/lib/pircbot.jar!/" />
</CLASSES>
<JAVADOC />
<SOURCES />
</library>
</orderEntry>
<orderEntry type="module-library">
<library>
<CLASSES>
<root url="jar://$MODULE_DIR$/lib/commons-logging.jar!/" />
</CLASSES>
<JAVADOC />
<SOURCES />
</library>
</orderEntry>
<orderEntry type="module-library">
<library>
<CLASSES>
<root url="jar://$MODULE_DIR$/lib/google.jar!/" />
</CLASSES>
<JAVADOC />
<SOURCES />
</library>
</orderEntry>
<orderEntry type="module-library">
<library>
<CLASSES>
<root url="jar://$MODULE_DIR$/lib/googleapi.jar!/" />
</CLASSES>
<JAVADOC />
<SOURCES />
</library>
</orderEntry>
<orderEntry type="module-library">
<library>
<CLASSES>
<root url="jar://$MODULE_DIR$/lib/EXML.jar!/" />
</CLASSES>
<JAVADOC />
<SOURCES />
</library>
</orderEntry>
<orderEntry type="module-library">
<library>
<CLASSES>
<root url="jar://$MODULE_DIR$/lib/rsslibj.jar!/" />
</CLASSES>
<JAVADOC />
<SOURCES />
</library>
</orderEntry>
<orderEntry type="module-library">
<library>
<CLASSES>
<root url="jar://$MODULE_DIR$/lib/jweather-0.2.3.jar!/" />
</CLASSES>
<JAVADOC />
<SOURCES />
</library>
</orderEntry>
<orderEntry type="module-library">
<library>
<CLASSES>
<root url="jar://$MODULE_DIR$/lib/log4j-1.2.8.jar!/" />
</CLASSES>
<JAVADOC />
<SOURCES />
</library>
</orderEntry>
<orderEntry type="module-library">
<library>
<CLASSES>
<root url="file://$MODULE_DIR$" />
</CLASSES>
<JAVADOC />
<SOURCES />
</library>
</orderEntry>
<orderEntry type="module-library">
<library>
<CLASSES>
<root url="jar://$MODULE_DIR$/lib/MathEvaluator.jar!/" />
</CLASSES>
<JAVADOC />
<SOURCES />
</library>
</orderEntry>
<orderEntry type="module-library">
<library>
<CLASSES>
<root url="jar://$MODULE_DIR$/lib/commons-net-1.1.0.jar!/" />
</CLASSES>
<JAVADOC />
<SOURCES />
</library>
</orderEntry>
<orderEntry type="module-library">
<library>
<CLASSES>
<root url="jar://$MODULE_DIR$/lib/commons-httpclient-2.0-final.jar!/" />
</CLASSES>
<JAVADOC />
<SOURCES />
</library>
</orderEntry>
<orderEntry type="module-library">
<library>
<CLASSES>
<root url="jar://$MODULE_DIR$/lib/jakarta-oro-2.0.8.jar!/" />
</CLASSES>
<JAVADOC />
<SOURCES />
</library>
</orderEntry>
</component>
</module>

119
mobibot.ipr Normal file
View file

@ -0,0 +1,119 @@
<?xml version="1.0" encoding="UTF-8"?>
<project version="4" relativePaths="false">
<component name="AntConfiguration">
<buildFile url="file://$PROJECT_DIR$/build.xml">
<useEmacsModeOutput value="true" />
<maximumHeapSize value="128" />
<useCustomJdk value="false" />
<useJavaw value="false" />
<includeProjectClasspath value="false" />
<includeParser value="true" />
</buildFile>
</component>
<component name="BSFConsole">
<restoresystemstreams>false</restoresystemstreams>
<outwaitsforerr>false</outwaitsforerr>
<errwaitsforout>false</errwaitsforout>
<languages>
<language name="ant" engine="org.kos.bsfconsoleplugin.AntConsoleBSFEngine" />
<language name="beanshell" engine="bsh.util.BeanShellBSFEngine" />
<language name="netrexx" engine="org.apache.bsf.engines.netrexx.NetRexxEngine" />
<language name="xslt" engine="org.apache.bsf.engines.xslt.XSLTEngine" />
<language name="beanbasic" engine="org.apache.bsf.engines.beanbasic.BeanBasicEngine" />
<language name="bml" engine="org.apache.bml.ext.BMLEngine" />
<language name="groovy" engine="org.codehaus.groovy.bsf.GroovyEngine" />
<language name="jacl" engine="org.apache.bsf.engines.jacl.JaclEngine" />
<language name="java" engine="org.apache.bsf.engines.java.JavaEngine" />
<language name="javaclass" engine="org.apache.bsf.engines.javaclass.JavaClassEngine" />
<language name="javascript" engine="org.apache.bsf.engines.javascript.JavaScriptEngine" />
<language name="jpython" engine="org.apache.bsf.engines.jpython.JPythonEngine" />
<language name="jscript" engine="org.apache.bsf.engines.activescript.ActiveScriptEngine" />
<language name="judoscript" engine="com.judoscript.BSFJudoEngine" />
<language name="jython" engine="org.apache.bsf.engines.jython.JythonEngine" />
<language name="lotusscript" engine="org.apache.bsf.engines.lotusscript.LsEngine" />
<language name="perl" engine="org.apache.bsf.engines.perl.PerlEngine" />
<language name="perlscript" engine="org.apache.bsf.engines.activescript.ActiveScriptEngine" />
<language name="pnuts" engine="pnuts.ext.PnutsBSFEngine" />
<language name="ruby" engine="org.jruby.javasupport.bsf.JRubyEngine" />
<language name="vbscript" engine="org.apache.bsf.engines.activescript.ActiveScriptEngine" />
</languages>
<startupscripts />
<BSFConsoleSearchOptions searchfromcursor="false">
<recentsearches />
</BSFConsoleSearchOptions>
</component>
<component name="CodeStyleSettingsManager">
<option name="PER_PROJECT_SETTINGS" />
<option name="USE_PER_PROJECT_SETTINGS" value="false" />
</component>
<component name="CompilerConfiguration">
<option name="DEFAULT_COMPILER" value="Javac" />
<option name="CLEAR_OUTPUT_DIRECTORY" value="false" />
<resourceExtensions>
<entry name=".+\.(properties|xml|html|dtd|tld)" />
<entry name=".+\.(gif|png|jpeg|jpg)" />
</resourceExtensions>
</component>
<component name="DataSourceManager" />
<component name="EntryPointsManager">
<entry_points />
</component>
<component name="ExportToHTMLSettings">
<option name="PRINT_LINE_NUMBERS" value="false" />
<option name="OPEN_IN_BROWSER" value="false" />
<option name="OUTPUT_DIRECTORY" />
</component>
<component name="GUI Designer component loader factory" />
<component name="JavacSettings">
<option name="DEBUGGING_INFO" value="true" />
<option name="GENERATE_NO_WARNINGS" value="false" />
<option name="DEPRECATION" value="true" />
<option name="ADDITIONAL_OPTIONS_STRING" value="" />
<option name="MAXIMUM_HEAP_SIZE" value="128" />
<option name="USE_GENERICS_COMPILER" value="false" />
</component>
<component name="JavadocGenerationManager">
<option name="OUTPUT_DIRECTORY" />
<option name="OPTION_SCOPE" value="protected" />
<option name="OPTION_HIERARCHY" value="true" />
<option name="OPTION_NAVIGATOR" value="true" />
<option name="OPTION_INDEX" value="true" />
<option name="OPTION_SEPARATE_INDEX" value="true" />
<option name="OPTION_DOCUMENT_TAG_USE" value="true" />
<option name="OPTION_DOCUMENT_TAG_AUTHOR" value="true" />
<option name="OPTION_DOCUMENT_TAG_VERSION" value="true" />
<option name="OPTION_DOCUMENT_TAG_DEPRECATED" value="true" />
<option name="OPTION_DEPRECATED_LIST" value="true" />
<option name="OTHER_OPTIONS" />
<option name="HEAP_SIZE" />
<option name="OPEN_IN_BROWSER" value="true" />
</component>
<component name="JikesSettings">
<option name="JIKES_PATH" value="" />
<option name="DEBUGGING_INFO" value="true" />
<option name="DEPRECATION" value="true" />
<option name="GENERATE_NO_WARNINGS" value="false" />
<option name="IS_EMACS_ERRORS_MODE" value="true" />
<option name="ADDITIONAL_OPTIONS_STRING" value="" />
</component>
<component name="ProjectModuleManager">
<modules>
<module fileurl="file://$PROJECT_DIR$/mobibot.iml" filepath="$PROJECT_DIR$/mobibot.iml" />
</modules>
</component>
<component name="ProjectRootManager" version="2" assert-keyword="false" project-jdk-name="1.4.x" />
<component name="Regex">
<option name="pos1" value="218" />
<option name="pos2" value="218" />
<option name="pos3" value="116" />
<option name="pos4" value="444" />
<option name="pos5" value="117" />
<option name="pos6" value="707" />
</component>
<component name="libraryTable" />
<component name="uidesigner-configuration">
<option name="INSTRUMENT_CLASSES" value="true" />
<option name="COPY_FORMS_RUNTIME_TO_OUTPUT" value="true" />
</component>
</project>

588
mobibot.iws Normal file
View file

@ -0,0 +1,588 @@
<?xml version="1.0" encoding="UTF-8"?>
<project version="4" relativePaths="false">
<component name="AspectsView" />
<component name="BookmarkManager" />
<component name="CheckinPanelState" />
<component name="Commander">
<leftPanel />
<rightPanel />
<splitter proportion="0.5" />
</component>
<component name="CompilerWorkspaceConfiguration">
<option name="COMPILE_IN_BACKGROUND" value="false" />
<option name="AUTO_SHOW_ERRORS_IN_EDITOR" value="true" />
</component>
<component name="Cvs2Configuration">
<option name="ON_FILE_ADDING" value="0" />
<option name="ON_FILE_REMOVING" value="0" />
<option name="PRUNE_EMPTY_DIRECTORIES" value="true" />
<option name="SHOW_UPDATE_OPTIONS" value="true" />
<option name="SHOW_ADD_OPTIONS" value="true" />
<option name="SHOW_REMOVE_OPTIONS" value="true" />
<option name="MERGING_MODE" value="0" />
<option name="MERGE_WITH_BRANCH1_NAME" value="HEAD" />
<option name="MERGE_WITH_BRANCH2_NAME" value="HEAD" />
<option name="RESET_STICKY" value="false" />
<option name="CREATE_NEW_DIRECTORIES" value="true" />
<option name="DEFAULT_TEXT_FILE_SUBSTITUTION" value="v" />
<option name="PROCESS_UNKNOWN_FILES" value="false" />
<option name="PROCESS_DELETED_FILES" value="false" />
<option name="SHOW_EDIT_DIALOG" value="false" />
<option name="RESERVED_EDIT" value="false" />
<option name="FILE_HISTORY_SPLITTER_PROPORTION" value="0.6" />
<option name="SHOW_CHECKOUT_OPTIONS" value="true" />
<option name="CHECKOUT_DATE_OR_REVISION_SETTINGS">
<value>
<option name="BRANCH" value="" />
<option name="DATE" value="" />
<option name="USE_BRANCH" value="false" />
<option name="USE_DATE" value="false" />
</value>
</option>
<option name="UPDATE_DATE_OR_REVISION_SETTINGS">
<value>
<option name="BRANCH" value="" />
<option name="DATE" value="" />
<option name="USE_BRANCH" value="false" />
<option name="USE_DATE" value="false" />
</value>
</option>
<option name="SHOW_CHANGES_REVISION_SETTINGS">
<value>
<option name="BRANCH" value="" />
<option name="DATE" value="" />
<option name="USE_BRANCH" value="false" />
<option name="USE_DATE" value="false" />
</value>
</option>
<option name="SHOW_OUTPUT" value="false" />
<option name="SHOW_FILE_HISTORY_AS_TREE" value="false" />
<option name="UPDATE_GROUP_BY_PACKAGES" value="false" />
<option name="ADD_WATCH_INDEX" value="0" />
<option name="REMOVE_WATCH_INDEX" value="0" />
<option name="UPDATE_KEYWORD_SUBSTITUTION" />
<option name="MAKE_NEW_FILES_READONLY" value="false" />
<option name="PUT_FOCUS_INTO_COMMENT" value="false" />
<option name="SHOW_CHECKIN_OPTIONS" value="true" />
<option name="FORCE_NON_EMPTY_COMMENT" value="false" />
<option name="LAST_COMMIT_MESSAGE" value="" />
<option name="SAVE_LAST_COMMIT_MESSAGE" value="true" />
<option name="CHECKIN_DIALOG_SPLITTER_PROPORTION" value="0.8" />
<option name="OPTIMIZE_IMPORTS_BEFORE_PROJECT_COMMIT" value="false" />
<option name="OPTIMIZE_IMPORTS_BEFORE_FILE_COMMIT" value="false" />
<option name="REFORMAT_BEFORE_PROJECT_COMMIT" value="false" />
<option name="REFORMAT_BEFORE_FILE_COMMIT" value="false" />
<option name="FILE_HISTORY_DIALOG_COMMENTS_SPLITTER_PROPORTION" value="0.8" />
<option name="FILE_HISTORY_DIALOG_SPLITTER_PROPORTION" value="0.5" />
</component>
<component name="DaemonCodeAnalyzer">
<disable_hints />
</component>
<component name="DebuggerManager">
<line_breakpoints />
<exception_breakpoints>
<breakpoint_any>
<option name="NOTIFY_CAUGHT" value="true" />
<option name="NOTIFY_UNCAUGHT" value="true" />
<option name="ENABLED" value="false" />
<option name="SUSPEND_VM" value="true" />
<option name="LOG_ENABLED" value="false" />
<option name="LOG_EXPRESSION_ENABLED" value="false" />
<option name="LOG_MESSAGE" value="" />
<option name="COUNT_FILTER_ENABLED" value="false" />
<option name="COUNT_FILTER" value="0" />
<option name="CONDITION_ENABLED" value="false" />
<option name="CONDITION" value="" />
<option name="CLASS_FILTERS_ENABLED" value="false" />
<option name="INSTANCE_FILTERS_ENABLED" value="false" />
</breakpoint_any>
</exception_breakpoints>
<field_breakpoints />
<method_breakpoints />
</component>
<component name="ErrorTreeViewConfiguration">
<option name="IS_AUTOSCROLL_TO_SOURCE" value="false" />
<option name="HIDE_WARNINGS" value="false" />
</component>
<component name="FileEditorManager" split-orientation="vertical" split-proportion="0.5">
<first-group selected-file="file://$PROJECT_DIR$/src/net/thauvin/erik/mobibot/Mobibot.java">
<entry file="file://$PROJECT_DIR$/src/net/thauvin/erik/mobibot/CurrencyConverter.java" pinned="false">
<provider selected="true" editor-type-id="text-editor">
<state line="66" column="13" selection-start="2138" selection-end="2138" vertical-scroll-proportion="1.518732">
<folding>
<element signature="imports" expanded="true" />
</folding>
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/net/thauvin/erik/mobibot/EntryComment.java" pinned="false">
<provider selected="true" editor-type-id="text-editor">
<state line="45" column="66" selection-start="1803" selection-end="1803" vertical-scroll-proportion="0.4364641">
<folding>
<element signature="imports" expanded="true" />
</folding>
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/net/thauvin/erik/mobibot/EntryLink.java" pinned="false">
<provider selected="true" editor-type-id="text-editor">
<state line="47" column="40" selection-start="1825" selection-end="1825" vertical-scroll-proportion="0.160221">
<folding>
<element signature="imports" expanded="true" />
</folding>
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/net/thauvin/erik/mobibot/FeedReader.java" pinned="false">
<provider selected="true" editor-type-id="text-editor">
<state line="64" column="13" selection-start="2145" selection-end="2145" vertical-scroll-proportion="0.6023055">
<folding>
<element signature="imports" expanded="true" />
</folding>
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/net/thauvin/erik/mobibot/GoogleSearch.java" pinned="false">
<provider selected="true" editor-type-id="text-editor">
<state line="54" column="13" selection-start="1958" selection-end="1958" vertical-scroll-proportion="0.6023055">
<folding />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/net/thauvin/erik/mobibot/Mobibot.java" pinned="false">
<provider selected="true" editor-type-id="text-editor">
<state line="1441" column="47" selection-start="37111" selection-end="37111" vertical-scroll-proportion="67.129684">
<folding>
<element signature="imports" expanded="true" />
</folding>
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/net/thauvin/erik/mobibot/StockQuote.java" pinned="false">
<provider selected="true" editor-type-id="text-editor">
<state line="53" column="13" selection-start="1948" selection-end="1948" vertical-scroll-proportion="0.5821326">
<folding />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/net/thauvin/erik/mobibot/Weather.java" pinned="false">
<provider selected="true" editor-type-id="text-editor">
<state line="54" column="13" selection-start="1981" selection-end="1981" vertical-scroll-proportion="0.556196">
<folding />
</state>
</provider>
</entry>
</first-group>
<second-group />
</component>
<component name="HierarchyBrowserManager">
<option name="IS_AUTOSCROLL_TO_SOURCE" value="false" />
<option name="SORT_ALPHABETICALLY" value="false" />
<option name="HIDE_CLASSES_WHERE_METHOD_NOT_IMPLEMENTED" value="false" />
</component>
<component name="InspectionManager">
<option name="AUTOSCROLL_TO_SOURCE" value="false" />
<option name="SPLITTER_PROPORTION" value="0.452356" />
<profile name="Erik's Inspection Profile" />
</component>
<component name="J2EEProjectPane" />
<component name="PackagesPane">
<expanded_node url="net" module="mobibot" type="package" />
<expanded_node url="net.thauvin.erik.mobibot" module="mobibot" type="package" />
<expanded_node url="" module="mobibot" type="module" />
<expanded_node url="net.thauvin.erik" module="mobibot" type="package" />
<expanded_node url="net.thauvin" module="mobibot" type="package" />
</component>
<component name="ProjectPane">
<expanded_node url="file://$PROJECT_DIR$/src/net/thauvin/erik" module="mobibot" type="directory" />
<expanded_node url="file://$PROJECT_DIR$/src/net/thauvin" module="mobibot" type="directory" />
<expanded_node url="file://$PROJECT_DIR$/src/net" module="mobibot" type="directory" />
<expanded_node url="file://$PROJECT_DIR$" module="mobibot" type="directory" />
<expanded_node url="file://$PROJECT_DIR$/src" module="mobibot" type="directory" />
<expanded_node url="file://$PROJECT_DIR$/src/net/thauvin/erik/mobibot" module="mobibot" type="directory" />
<expanded_node url="" module="mobibot" type="module" />
</component>
<component name="ProjectView">
<navigator currentView="ProjectPane" splitterProportion="0.5">
<flattenPackages />
<showMembers />
<showModules />
<showLibraryContents />
<hideEmptyPackages />
<showStructure PackagesPane="false" ProjectPane="false" />
<autoscrollToSource />
</navigator>
</component>
<component name="PropertiesComponent">
<property name="MemberChooser.copyJavadoc" value="false" />
<property name="GoToClass.includeLibraries" value="false" />
<property name="MemberChooser.showClasses" value="true" />
<property name="MemberChooser.sorted" value="false" />
<property name="GoToFile.includeJavaFiles" value="false" />
<property name="last_opened_file_path" value="C:\Documents and Settings\erik\My Documents\My Received Files\src\MathEvaluator" />
<property name="GoToClass.toSaveIncludeLibraries" value="false" />
</component>
<component name="RunManager">
<activeType name="Application" />
<configuration name="&lt;template&gt;" type="Application" default="true" selected="false">
<option name="MAIN_CLASS_NAME" />
<option name="VM_PARAMETERS" />
<option name="PROGRAM_PARAMETERS" />
<option name="WORKING_DIRECTORY" value="$PROJECT_DIR$" />
<module name="" />
</configuration>
<configuration name="&lt;template&gt;" type="Applet" default="true" selected="false">
<module name="" />
<option name="MAIN_CLASS_NAME" />
<option name="HTML_FILE_NAME" />
<option name="HTML_USED" value="false" />
<option name="WIDTH" value="400" />
<option name="HEIGHT" value="300" />
<option name="POLICY_FILE" value="C:/IntelliJ-IDEA/bin/appletviewer.policy" />
<option name="VM_PARAMETERS" />
</configuration>
<configuration name="&lt;template&gt;" type="JUnit" default="true" selected="false">
<module name="" />
<option name="PACKAGE_NAME" />
<option name="MAIN_CLASS_NAME" />
<option name="METHOD_NAME" />
<option name="TEST_OBJECT" />
<option name="VM_PARAMETERS" />
<option name="PARAMETERS" />
<option name="WORKING_DIRECTORY" value="$PROJECT_DIR$" />
<option name="ADDITIONAL_CLASS_PATH" />
</configuration>
<configuration name="&lt;template&gt;" type="Remote" default="true" selected="false">
<option name="USE_SOCKET_TRANSPORT" value="true" />
<option name="SERVER_MODE" value="false" />
<option name="SHMEM_ADDRESS" value="javadebug" />
<option name="HOST" value="localhost" />
<option name="PORT" value="5005" />
</configuration>
<configuration name="&lt;template&gt;" type="WebApp" default="true" selected="false">
<module name="" />
<WebServerIntegration name="" />
<Host>localhost</Host>
<Port>5050</Port>
<LaunchServer>false</LaunchServer>
</configuration>
<configuration name="&lt;template&gt;" type="WebLogic Instance" default="true" selected="false">
<setting name="WEBLOGIC_INSTANCE_CONFIGURATION_NAME" value="" />
</configuration>
<configuration name="Mobibot" type="Application" default="false" selected="true">
<option name="MAIN_CLASS_NAME" value="net.thauvin.erik.mobibot.Mobibot" />
<option name="VM_PARAMETERS" value="" />
<option name="PROGRAM_PARAMETERS" value="-debug" />
<option name="WORKING_DIRECTORY" value="D:\projects\java\mobibot" />
<module name="mobibot" />
</configuration>
</component>
<component name="SelectInManager">
<target name="J2EE View" />
<target name="File Structure" />
<target name="Project" />
<target name="Packages" />
<target name="Commander" />
</component>
<component name="StarteamConfiguration">
<option name="SERVER" value="" />
<option name="PORT" value="49201" />
<option name="USER" value="" />
<option name="PASSWORD" value="" />
<option name="PROJECT" value="" />
<option name="VIEW" value="" />
<option name="ALTERNATIVE_WORKING_PATH" value="" />
<option name="PUT_FOCUS_INTO_COMMENT" value="false" />
<option name="SHOW_CHECKIN_OPTIONS" value="true" />
<option name="FORCE_NON_EMPTY_COMMENT" value="false" />
<option name="LAST_COMMIT_MESSAGE" value="" />
<option name="SAVE_LAST_COMMIT_MESSAGE" value="true" />
<option name="CHECKIN_DIALOG_SPLITTER_PROPORTION" value="0.8" />
<option name="OPTIMIZE_IMPORTS_BEFORE_PROJECT_COMMIT" value="false" />
<option name="OPTIMIZE_IMPORTS_BEFORE_FILE_COMMIT" value="false" />
<option name="REFORMAT_BEFORE_PROJECT_COMMIT" value="false" />
<option name="REFORMAT_BEFORE_FILE_COMMIT" value="false" />
<option name="FILE_HISTORY_DIALOG_COMMENTS_SPLITTER_PROPORTION" value="0.8" />
<option name="FILE_HISTORY_DIALOG_SPLITTER_PROPORTION" value="0.5" />
</component>
<component name="StructureViewFactory">
<option name="SORT_MODE" value="0" />
<option name="GROUP_INHERITED" value="true" />
<option name="AUTOSCROLL_MODE" value="true" />
<option name="SHOW_FIELDS" value="true" />
<option name="AUTOSCROLL_FROM_SOURCE" value="true" />
<option name="GROUP_GETTERS_AND_SETTERS" value="true" />
<option name="SHOW_INHERITED" value="false" />
<option name="HIDE_NOT_PUBLIC" value="false" />
</component>
<component name="TodoView" selected-index="0">
<todo-panel id="selected-file">
<are-packages-shown value="false" />
<flatten-packages value="false" />
<is-autoscroll-to-source value="true" />
</todo-panel>
<todo-panel id="all">
<are-packages-shown value="true" />
<flatten-packages value="false" />
<is-autoscroll-to-source value="true" />
</todo-panel>
</component>
<component name="ToolWindowManager">
<frame x="-4" y="-4" width="1032" height="776" extended-state="0" />
<editor active="false" />
<layout>
<window_info id="CVS" active="false" anchor="bottom" auto_hide="false" internal_type="docked" type="docked" visible="false" weight="0.33" order="8" />
<window_info id="Regex" active="false" anchor="bottom" auto_hide="false" internal_type="docked" type="docked" visible="false" weight="0.44135803" order="10" x="22" y="277" width="980" height="214" />
<window_info id="TODO" active="false" anchor="bottom" auto_hide="false" internal_type="docked" type="docked" visible="false" weight="0.33024693" order="7" />
<window_info id="Project" active="false" anchor="left" auto_hide="false" internal_type="docked" type="docked" visible="false" weight="0.25918368" order="0" />
<window_info id="Find" active="false" anchor="bottom" auto_hide="false" internal_type="docked" type="docked" visible="false" weight="0.33024693" order="1" />
<window_info id="Structure" active="false" anchor="left" auto_hide="false" internal_type="docked" type="docked" visible="false" weight="0.16836734" order="1" />
<window_info id="Messages" active="true" anchor="bottom" auto_hide="false" internal_type="docked" type="docked" visible="true" weight="0.33024693" order="9" />
<window_info id="Inspection" active="false" anchor="bottom" auto_hide="false" internal_type="docked" type="docked" visible="false" weight="0.39969134" order="6" />
<window_info id="Ant Build" active="false" anchor="right" auto_hide="false" internal_type="docked" type="docked" visible="true" weight="0.08265306" order="1" />
<window_info id="Run" active="false" anchor="bottom" auto_hide="true" internal_type="docked" type="docked" visible="false" weight="0.39660493" order="2" x="22" y="277" width="980" height="213" />
<window_info id="Hierarchy" active="false" anchor="right" auto_hide="false" internal_type="docked" type="docked" visible="false" weight="0.25" order="2" />
<window_info id="CVS File View" active="false" anchor="right" auto_hide="false" internal_type="docked" type="docked" visible="false" weight="0.33" order="3" />
<window_info id="Debug" active="false" anchor="bottom" auto_hide="false" internal_type="docked" type="docked" visible="false" weight="0.39969134" order="4" />
<window_info id="BSFConsole" active="false" anchor="bottom" auto_hide="false" internal_type="docked" type="docked" visible="false" weight="0.33024693" order="11" />
<window_info id="Commander" active="false" anchor="right" auto_hide="false" internal_type="sliding" type="sliding" visible="false" weight="0.4" order="0" />
<window_info id="Web" active="false" anchor="left" auto_hide="false" internal_type="docked" type="docked" visible="false" weight="0.25" order="2" />
<window_info id="Message" active="false" anchor="bottom" auto_hide="false" internal_type="docked" type="docked" visible="false" weight="0.33" order="0" />
<window_info id="EJB" active="false" anchor="bottom" auto_hide="false" internal_type="docked" type="docked" visible="false" weight="0.25" order="3" />
<window_info id="Cvs" active="false" anchor="bottom" auto_hide="false" internal_type="docked" type="docked" visible="false" weight="0.25" order="5" />
</layout>
</component>
<component name="VCS.FileViewConfiguration">
<option name="SELECTED_STATUSES" value="DEFAULT" />
<option name="SELECTED_COLUMNS" value="DEFAULT" />
<option name="SHOW_FILTERS" value="true" />
<option name="CUSTOMIZE_VIEW" value="true" />
<option name="SHOW_FILE_HISTORY_AS_TREE" value="true" />
</component>
<component name="VcsManagerConfiguration">
<option name="ACTIVE_VCS_NAME" value="CVS" />
</component>
<component name="VssConfiguration">
<CheckoutOptions>
<option name="COMMENT" value="" />
<option name="DO_NOT_GET_LATEST_VERSION" value="false" />
<option name="REPLACE_WRITABLE" value="false" />
<option name="RECURSIVE" value="false" />
</CheckoutOptions>
<CheckinOptions>
<option name="COMMENT" value="" />
<option name="KEEP_CHECKED_OUT" value="false" />
<option name="RECURSIVE" value="false" />
</CheckinOptions>
<AddOptions>
<option name="COMMENT" value="" />
<option name="STORE_ONLY_LATEST_VERSION" value="false" />
<option name="CHECK_OUT_IMMEDIATELY" value="false" />
<option name="FILE_TYPE" value="0" />
</AddOptions>
<UndocheckoutOptions>
<option name="MAKE_WRITABLE" value="false" />
<option name="REPLACE_LOCAL_COPY" value="0" />
<option name="RECURSIVE" value="false" />
</UndocheckoutOptions>
<GetOptions>
<option name="REPLACE_WRITABLE" value="0" />
<option name="MAKE_WRITABLE" value="false" />
<option name="RECURSIVE" value="false" />
</GetOptions>
<option name="CLIENT_PATH" value="" />
<option name="SRCSAFEINI_PATH" value="" />
<option name="USER_NAME" value="" />
<option name="PWD" value="" />
<option name="SHOW_CHECKOUT_OPTIONS" value="true" />
<option name="SHOW_ADD_OPTIONS" value="true" />
<option name="VSS_IS_INITIALIZED" value="false" />
<option name="SHOW_UNDOCHECKOUT_OPTIONS" value="true" />
<option name="SHOW_DIFF_OPTIONS" value="true" />
<option name="SHOW_GET_OPTIONS" value="true" />
<option name="REUSE_LAST_COMMENT" value="false" />
<option name="PUT_FOCUS_INTO_COMMENT" value="false" />
<option name="SHOW_CHECKIN_OPTIONS" value="true" />
<option name="FORCE_NON_EMPTY_COMMENT" value="false" />
<option name="LAST_COMMIT_MESSAGE" value="" />
<option name="SAVE_LAST_COMMIT_MESSAGE" value="true" />
<option name="CHECKIN_DIALOG_SPLITTER_PROPORTION" value="0.8" />
<option name="OPTIMIZE_IMPORTS_BEFORE_PROJECT_COMMIT" value="false" />
<option name="OPTIMIZE_IMPORTS_BEFORE_FILE_COMMIT" value="false" />
<option name="REFORMAT_BEFORE_PROJECT_COMMIT" value="false" />
<option name="REFORMAT_BEFORE_FILE_COMMIT" value="false" />
<option name="FILE_HISTORY_DIALOG_COMMENTS_SPLITTER_PROPORTION" value="0.8" />
<option name="FILE_HISTORY_DIALOG_SPLITTER_PROPORTION" value="0.5" />
</component>
<component name="antWorkspaceConfiguration">
<option name="IS_AUTOSCROLL_TO_SOURCE" value="false" />
<option name="FILTER_TARGETS" value="false" />
<buildFile url="file://$PROJECT_DIR$/build.xml">
<runInBackground value="false" />
<viewClosedWhenNoErrors value="false" />
<treeView value="true" />
<verbose value="true" />
</buildFile>
</component>
<component name="editorHistoryManager">
<entry file="jar://$PROJECT_DIR$/lib/commons-logging.jar!/org/apache/commons/logging/impl/Log4JLogger.class">
<provider selected="true" editor-type-id="text-editor">
<state line="28" column="16" selection-start="652" selection-end="657" vertical-scroll-proportion="0.33333334">
<folding />
</state>
</provider>
</entry>
<entry file="jar://C:/j2sdk1.4.2_03/src.zip!/java/io/Serializable.java">
<provider selected="true" editor-type-id="text-editor">
<state line="44" column="52" selection-start="200" selection-end="4427" vertical-scroll-proportion="0.3567753">
<folding />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/build.xml">
<provider selected="true" editor-type-id="text-editor">
<state line="22" column="105" selection-start="865" selection-end="865" vertical-scroll-proportion="0.6584507">
<folding />
</state>
</provider>
</entry>
<entry file="jar://C:/j2sdk1.4.2_03/src.zip!/java/lang/Runnable.java">
<provider selected="true" editor-type-id="text-editor">
<state line="37" column="10" selection-start="1508" selection-end="1508" vertical-scroll-proportion="0.41680962">
<folding />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/build.properties">
<provider selected="true" editor-type-id="text-editor">
<state line="0" column="0" selection-start="0" selection-end="0" vertical-scroll-proportion="0.0">
<folding />
</state>
</provider>
</entry>
<entry file="jar://$PROJECT_DIR$/lib/pircbot.jar!/org/jibble/pircbot/InputThread.class">
<provider selected="true" editor-type-id="text-editor">
<state line="24" column="0" selection-start="760" selection-end="760" vertical-scroll-proportion="1.2615894">
<folding />
</state>
</provider>
</entry>
<entry file="jar://$PROJECT_DIR$/lib/pircbot.jar!/org/jibble/pircbot/PircBot.class">
<provider selected="true" editor-type-id="text-editor">
<state line="372" column="24" selection-start="12156" selection-end="12156" vertical-scroll-proportion="0.33274648">
<folding />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/net/thauvin/erik/mobibot/CurrencyConverter.java">
<provider selected="true" editor-type-id="text-editor">
<state line="66" column="13" selection-start="2138" selection-end="2138" vertical-scroll-proportion="1.518732">
<folding>
<element signature="imports" expanded="true" />
</folding>
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/net/thauvin/erik/mobibot/EntryComment.java">
<provider selected="true" editor-type-id="text-editor">
<state line="45" column="66" selection-start="1803" selection-end="1803" vertical-scroll-proportion="0.4364641">
<folding>
<element signature="imports" expanded="true" />
</folding>
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/net/thauvin/erik/mobibot/EntryLink.java">
<provider selected="true" editor-type-id="text-editor">
<state line="47" column="40" selection-start="1825" selection-end="1825" vertical-scroll-proportion="0.160221">
<folding>
<element signature="imports" expanded="true" />
</folding>
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/net/thauvin/erik/mobibot/FeedReader.java">
<provider selected="true" editor-type-id="text-editor">
<state line="64" column="13" selection-start="2145" selection-end="2145" vertical-scroll-proportion="0.6023055">
<folding>
<element signature="imports" expanded="true" />
</folding>
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/net/thauvin/erik/mobibot/Mobibot.java">
<provider selected="true" editor-type-id="text-editor">
<state line="1441" column="47" selection-start="37111" selection-end="37111" vertical-scroll-proportion="67.129684">
<folding>
<element signature="imports" expanded="true" />
</folding>
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/net/thauvin/erik/mobibot/StockQuote.java">
<provider selected="true" editor-type-id="text-editor">
<state line="53" column="13" selection-start="1948" selection-end="1948" vertical-scroll-proportion="0.5821326">
<folding />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/net/thauvin/erik/mobibot/Weather.java">
<provider selected="true" editor-type-id="text-editor">
<state line="54" column="13" selection-start="1981" selection-end="1981" vertical-scroll-proportion="0.556196">
<folding />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/net/thauvin/erik/mobibot/GoogleSearch.java">
<provider selected="true" editor-type-id="text-editor">
<state line="54" column="13" selection-start="1958" selection-end="1958" vertical-scroll-proportion="0.6023055">
<folding />
</state>
</provider>
</entry>
</component>
<component name="ideajad">
<property name="annotate" value="false" />
<property name="annotateFully" value="false" />
<property name="braces" value="false" />
<property name="clear" value="false" />
<property name="confirmNavigationTriggeredDecompile" value="true" />
<property name="dead" value="true" />
<property name="defaultInitializers" value="false" />
<property name="dissassemblerOnly" value="false" />
<property name="fieldsFirst" value="true" />
<property name="fileExtension" value="java" />
<property name="fullyQualifiedNames" value="false" />
<property name="indentation" value="4" />
<property name="intRadix" value="10" />
<property name="lineNumbersAsComments" value="true" />
<property name="longRadix" value="10" />
<property name="maxStringLength" value="64" />
<property name="nocast" value="false" />
<property name="noclass" value="false" />
<property name="nocode" value="false" />
<property name="noconv" value="false" />
<property name="noctor" value="false" />
<property name="nodos" value="false" />
<property name="nofd" value="false" />
<property name="noinner" value="false" />
<property name="nolvt" value="false" />
<property name="nonlb" value="false" />
<property name="outputDirectory" value="D:\projects\ect\java\mobibot\src" />
<property name="packFields" value="3" />
<property name="packImports" value="7" />
<property name="prefixNumericalClasses" value="_cls" />
<property name="prefixNumericalFields" value="_fld" />
<property name="prefixNumericalLocals" value="_lcl" />
<property name="prefixNumericalMethods" value="_mth" />
<property name="prefixNumericalParameters" value="_prm" />
<property name="prefixUnusedExceptions" value="_ex" />
<property name="readonly" value="false" />
<property name="safe" value="false" />
<property name="sort" value="false" />
<property name="spaceAfterKeyword" value="false" />
<property name="splitStringsAtNewline" value="false" />
<property name="useTabs" value="false" />
</component>
</project>

View file

@ -0,0 +1,207 @@
/*
* @(#)CurrencyConverter.java
*
* Copyright (c) 2004, Erik C. Thauvin (erik@thauvin.net)
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are
* met:
*
* Redistributions of source code must retain the above copyright notice,
* this list of conditions and the following disclaimer.
*
* Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* Neither the name of the author nor the names of its contributors may be
* used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS
* IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
* THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
* PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
* CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
* EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
* PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
* PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*
* $Id$
*
*/
package net.thauvin.erik.mobibot;
import org.jdom.Document;
import org.jdom.Element;
import org.jdom.JDOMException;
import org.jdom.Namespace;
import org.jdom.input.SAXBuilder;
import java.io.IOException;
import java.net.URL;
import java.text.NumberFormat;
import java.util.List;
import java.util.Locale;
import java.util.Map;
import java.util.TreeMap;
/**
* Converts various currencies.
*
* @author Erik C. Thauvin
* @version $Revision$, $Date$
*
* @created Feb 11, 2004
* @since 1.0
*/
public class CurrencyConverter implements Runnable
{
/**
* The exchange rates table URL.
*/
public static final String EXCHANGE_TABLE_URL = "http://www.ecb.int/stats/eurofxref/eurofxref-daily.xml";
/**
* The exchange rates.
*/
private static final Map EXCHANGE_RATES = new TreeMap();
/**
* The last exchange rates table publication date.
*/
private static String s_date = "";
/**
* The bot.
*/
private final Mobibot _bot;
/**
* The actual currency _query.
*/
private final String _query;
/**
* The nick of the person who sent the message.
*/
private final String _sender;
/**
* Creates a new CurrencyConverter object.
*
* @param bot The bot.
* @param sender The nick of the person who sent the message.
* @param query The currency query.
* @param date The current date.
*/
public CurrencyConverter(Mobibot bot, String sender, String query, String date)
{
_bot = bot;
_sender = sender;
_query = query;
if (!s_date.equals(date))
{
EXCHANGE_RATES.clear();
}
}
// Converts specified currencies.
public void run()
{
if (EXCHANGE_RATES.isEmpty())
{
try
{
final SAXBuilder builder = new SAXBuilder();
builder.setIgnoringElementContentWhitespace(true);
final Document doc = builder.build(new URL(EXCHANGE_TABLE_URL));
final Element root = doc.getRootElement();
final Namespace ns = root.getNamespace("");
final Element cubeRoot = root.getChild("Cube", ns);
final Element cubeTime = cubeRoot.getChild("Cube", ns);
s_date = cubeTime.getAttribute("time").getValue();
final List cubes = cubeTime.getChildren();
Element cube;
for (int i = 0; i < cubes.size(); i++)
{
cube = (Element) cubes.get(i);
EXCHANGE_RATES.put(cube.getAttribute("currency").getValue(), cube.getAttribute("rate").getValue());
}
EXCHANGE_RATES.put("EUR", "1");
}
catch (JDOMException e)
{
_bot.getLogger().debug("Unable to parse the exchange rates table.", e);
_bot.sendNotice(_sender, "An error has occurred while parsing the exchange rates table.");
}
catch (IOException e)
{
_bot.getLogger().debug("Unable to fetch the exchange rates table.", e);
_bot.sendNotice(_sender,
"An error has occurred while fetching the exchange rates table: " + e.getMessage());
}
}
if (!EXCHANGE_RATES.isEmpty())
{
if (_query.matches("\\d+([,\\d]+)?(\\.\\d+)? [a-z]{3}+ to [a-z]{3}+"))
{
final String[] cmds = _query.split(" ");
if (cmds.length == 4)
{
if (cmds[3].equals(cmds[1]))
{
_bot.sendNotice(_sender, "You're kidding, right?");
}
else
{
try
{
final double amt = Double.parseDouble(cmds[0].replaceAll(",", ""));
final double from = Double.parseDouble((String) EXCHANGE_RATES.get(cmds[1].toUpperCase()));
double to = Double.parseDouble((String) EXCHANGE_RATES.get(cmds[3].toUpperCase()));
_bot.sendNotice(_bot.getChannel(),
NumberFormat.getCurrencyInstance(Locale.US).format(amt).substring(1) + ' ' +
cmds[1].toUpperCase() + " = " +
NumberFormat.getCurrencyInstance(Locale.US).format((amt * to) / from)
.substring(1) + ' ' + cmds[3].toUpperCase());
}
catch (NullPointerException e)
{
_bot.sendNotice(_sender,
"The supported currencies are: " + EXCHANGE_RATES.keySet().toString());
}
}
}
}
else
{
_bot.helpResponse(_sender, Mobibot.CURRENCY_CMD + ' ' + _query);
_bot.sendNotice(_sender, "The supported currencies are: " + EXCHANGE_RATES.keySet().toString());
}
}
else
{
_bot.getLogger().debug("The exchange rate table is empty.");
_bot.sendNotice(_sender, "Sorry, but the exchange rate table is empty.");
}
}
}

View file

@ -0,0 +1,137 @@
/*
* @(#)EntryComment.java
*
* Copyright (c) 2004, Erik C. Thauvin (erik@thauvin.net)
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are
* met:
*
* Redistributions of source code must retain the above copyright notice,
* this list of conditions and the following disclaimer.
*
* Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* Neither the name of the author nor the names of its contributors may be
* used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS
* IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
* THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
* PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
* CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
* EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
* PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
* PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*
* $Id$
*
*/
package net.thauvin.erik.mobibot;
import java.io.Serializable;
import java.util.Calendar;
import java.util.Date;
/**
* The class used to store comments associated to a specific entry.
*
* @author Erik C. Thauvin
* @version $Revision$, $Date$
*
* @created Jan 31, 2004
* @since 1.0
*/
public class EntryComment implements Serializable
{
/**
* The serial version UID.
*/
static final long serialVersionUID = 6957415292233553224L;
/**
* The creation date.
*/
private final Date _date = Calendar.getInstance().getTime();
private String _comment = "";
private String _nick = "";
/**
* Creates a new comment.
*
* @param comment The new comment.
* @param nick The nickname of the comment's author.
*/
public EntryComment(String comment, String nick)
{
_comment = comment;
_nick = nick;
}
/**
* Creates a new comment.
*/
protected EntryComment()
{
; // Required for serialization.
}
/**
* Sets the comment.
*
* @param comment The actual comment.
*/
public final void setComment(String comment)
{
_comment = comment;
}
/**
* Returns the comment.
*
* @return The comment.
*/
public final String getComment()
{
return _comment;
}
/**
* Returns the comment's creation date.
*
* @return The date.
*/
public final Date getDate()
{
return _date;
}
/**
* Sets the nickname of the author of the comment.
*
* @param nick The new nickname.
*/
public final void setNick(String nick)
{
_nick = nick;
}
/**
* Returns the nickname of the author of the comment.
*
* @return The nickname.
*/
public final String getNick()
{
return _nick;
}
}

View file

@ -0,0 +1,289 @@
/*
* @(#)EntryLink.java
*
* Copyright (c) 2004, Erik C. Thauvin (erik@thauvin.net)
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are
* met:
*
* Redistributions of source code must retain the above copyright notice,
* this list of conditions and the following disclaimer.
*
* Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* Neither the name of the author nor the names of its contributors may be
* used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS
* IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
* THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
* PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
* CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
* EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
* PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
* PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*
* $Id$
*
*/
package net.thauvin.erik.mobibot;
import java.io.Serializable;
import java.util.ArrayList;
import java.util.Calendar;
import java.util.Date;
import java.util.List;
/**
* The class used to store link entries.
*
* @author Erik C. Thauvin
* @version $Revision$, $Date$
*
* @created Jan 31, 2004
* @since 1.0
*/
public class EntryLink implements Serializable
{
/**
* The serial version UID.
*/
static final long serialVersionUID = 3676245542270899086L;
/**
* The creation date.
*/
private final Date _date = Calendar.getInstance().getTime();
/**
* The comments.
*/
private final List _comments = new ArrayList(0);
private String _link = "";
private String _login = "";
private String _nick = "";
private String _title = "No Title";
/**
* Creates a new entry.
*
* @param link The new entry's link.
* @param nick The nickname of the author of the link.
* @param login The login of the author of the link.
*/
public EntryLink(String link, String nick, String login)
{
_link = link;
_nick = nick;
_login = login;
}
/**
* Creates a new entry.
*
* @param link The new entry's link.
* @param title The new entry's title.
* @param nick The nickname of the author of the link.
* @param login The login of the author of the link.
*/
public EntryLink(String link, String title, String nick, String login)
{
_link = link;
_title = title;
_nick = nick;
_login = login;
}
/**
* Creates a new EntryLink object.
*/
protected EntryLink()
{
; // Required for serialization.
}
/**
* Sets a comment.
*
* @param index The comment's index.
* @param comment The actual comment.
* @param nick The nickname of the author of the comment.
*/
public final synchronized void setComment(int index, String comment, String nick)
{
if (index < _comments.size())
{
_comments.set(index, new EntryComment(comment, nick));
}
}
/**
* Returns a comment.
*
* @param index The comment's index.
*
* @return The specific comment.
*/
public final synchronized EntryComment getComment(int index)
{
return ((EntryComment) _comments.get(index));
}
/**
* Returns all the comments.
*
* @return The comments.
*/
public final synchronized EntryComment[] getComments()
{
return ((EntryComment[]) _comments.toArray(new EntryComment[0]));
}
/**
* Returns the total number of comments.
*
* @return The count of comments.
*/
public final synchronized int getCommentsCount()
{
return _comments.size();
}
/**
* Returns the comment's creation date.
*
* @return The date.
*/
public final synchronized Date getDate()
{
return _date;
}
/**
* Sets the comment's link.
*
* @param link The new link.
*/
public final synchronized void setLink(String link)
{
this._link = link;
}
/**
* Returns the comment's link.
*
* @return The link.
*/
public final synchronized String getLink()
{
return _link;
}
/**
* Set the comment's author login.
*
* @param login The new login.
*/
public final synchronized void setLogin(String login)
{
this._login = login;
}
/**
* Return's the comment's author login.
*
* @return The login;
*/
public final synchronized String getLogin()
{
return _login;
}
/**
* Sets the comment's author nickname.
*
* @param nick The new nickname.
*/
public final synchronized void setNick(String nick)
{
this._nick = nick;
}
/**
* Returns the comment's author nickname.
*
* @return The nickname.
*/
public final synchronized String getNick()
{
return _nick;
}
/**
* Sets the comment's title.
*
* @param title The new title.
*/
public final synchronized void setTitle(String title)
{
this._title = title;
}
/**
* Returns the comment's title.
*
* @return The title.
*/
public final synchronized String getTitle()
{
return _title;
}
/**
* Adds a new comment.
*
* @param comment The actual comment.
* @param nick The nickname of the author of the comment.
*
* @return The total number of comments for this entry.
*/
public final synchronized int addComment(String comment, String nick)
{
_comments.add(new EntryComment(comment, nick));
return (_comments.size() - 1);
}
/**
* Deletes a specific comment.
*
* @param index The index of the comment to delete.
*/
public final synchronized void deleteComment(int index)
{
if (index < _comments.size())
{
_comments.remove(index);
}
}
/**
* Returns true if the entry has comments.
*
* @return true if there are comments, false otherwise.
*/
public final synchronized boolean hasComments()
{
return (_comments.size() > 0);
}
}

View file

@ -0,0 +1,163 @@
/*
* @(#)FeedReader.java
*
* Copyright (c) 2004, Erik C. Thauvin (erik@thauvin.net)
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are
* met:
*
* Redistributions of source code must retain the above copyright notice,
* this list of conditions and the following disclaimer.
*
* Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* Neither the name of the author nor the names of its contributors may be
* used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS
* IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
* THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
* PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
* CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
* EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
* PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
* PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*
* $Id$
*
*/
package net.thauvin.erik.mobibot;
import org.crazybob.rss.Channel;
import org.crazybob.rss.Item;
import org.crazybob.rss.Parser;
import org.crazybob.rss.UrlLoader;
import org.crazybob.rss.UrlLoader.Response;
import org.jdom.JDOMException;
import org.jdom.input.SAXBuilder;
import java.io.IOException;
import java.io.StringReader;
import java.util.Iterator;
import java.util.List;
/**
* Reads a RSS feed.
*
* @author Erik C. Thauvin
* @version $Revision$, $Date$
*
* @created Feb 1, 2004
* @since 1.0
*/
public class FeedReader implements Runnable
{
/**
* The maximum number of feed items to display.
*/
private static final int MAX_ITEMS = 5;
/**
* The tab indent (4 spaces).
*/
private static final String TAB_INDENT = " ";
/**
* The bot.
*/
private final Mobibot _bot;
/**
* The nick of the person who sent the message.
*/
private final String _sender;
/**
* The URL to fetch.
*/
private final String _url;
/**
* Creates a new FeedReader object.
*
* @param bot The bot.
* @param sender The nick of the person who sent the message.
* @param url The URL to fetch.
*/
public FeedReader(Mobibot bot, String sender, String url)
{
_bot = bot;
_sender = sender;
_url = url;
}
/**
* Fetches the Feed's items.
*/
public void run()
{
List items = null;
try
{
final Response response = new UrlLoader().load(_url, _bot.getFeedLastMod());
if (response != null)
{
_bot.setFeedLastMod(response.getLastModified());
final Channel chan = new Parser().parse(new SAXBuilder().build(new StringReader(response.getBody())));
items = chan.getItems();
_bot.setFeedItems(items);
}
}
catch (JDOMException e)
{
_bot.getLogger().debug("Unable to parse the feed.", e);
_bot.sendNotice(_sender, "An error has occurred while parsing the feed.");
}
catch (IOException e)
{
_bot.getLogger().debug("Unable to fetch the feed.", e);
_bot.sendNotice(_sender, "An error has occurred while fetching the feed: " + e.getMessage());
}
if (items == null)
{
items = _bot.getFeedItems();
}
if ((items != null) && (!items.isEmpty()))
{
Item item;
int i = 0;
final Iterator it = items.iterator();
while (it.hasNext() && (i < MAX_ITEMS))
{
item = (Item) it.next();
_bot.sendNotice(_sender, item.getTitle());
_bot.sendNotice(_sender, TAB_INDENT + '<' + item.getLink() + '>');
i++;
}
if (_bot.getFeedLastMod().length() > 0)
{
_bot.sendNotice(_sender, "Last Updated: " + _bot.getFeedLastMod());
}
}
}
}

View file

@ -0,0 +1,170 @@
/*
* @(#)GoogleSearch.java
*
* Copyright (c) 2004, Erik C. Thauvin (erik@thauvin.net)
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are
* met:
*
* Redistributions of source code must retain the above copyright notice,
* this list of conditions and the following disclaimer.
*
* Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* Neither the name of the author nor the names of its contributors may be
* used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS
* IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
* THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
* PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
* CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
* EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
* PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
* PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*
* $Id$
*
*/
package net.thauvin.erik.mobibot;
import com.google.soap.search.GoogleSearchFault;
import net.thauvin.google.GoogleSearchBean;
import org.jibble.pircbot.Colors;
/**
* Performs a Google search or spell checking query.
*
* @author Erik C. Thauvin
* @version $Revision$, $Date$
*
* @created Feb 7, 2004
* @since 1.0
*/
public class GoogleSearch implements Runnable
{
/**
* The maximum number of Google results to display.
*/
private static final int MAX_GOOGLE = 5;
/**
* The Google search bean.
*/
private static final GoogleSearchBean GOOGLE_BEAN = new GoogleSearchBean();
/**
* The tab indent (4 spaces).
*/
private static final String TAB_INDENT = " ";
/**
* The bot.
*/
private final Mobibot _bot;
/**
* The Google API key.
*/
private final String _key;
/**
* The search query.
*/
private final String _query;
/**
* The nick of the person who sent the message.
*/
private final String _sender;
/**
* Spell Checking query flag.
*/
private final boolean _isSpellQuery;
/**
* Creates a new GoogleSearch object.
*
* @param bot The bot.
* @param key The Google API key.
* @param sender The nick of the person who sent the message.
* @param query The Google query
* @param isSpellQuery Set to true if the query is a Spell Checking query
*/
public GoogleSearch(Mobibot bot, String key, String sender, String query, boolean isSpellQuery)
{
_bot = bot;
_key = key;
_sender = sender;
_query = query;
_isSpellQuery = isSpellQuery;
}
/**
* Main processing method.
*/
public void run()
{
GOOGLE_BEAN.setKey(_key);
if (_isSpellQuery)
{
try
{
final String r = GOOGLE_BEAN.getSpellingSuggestion(_query);
if ((r != null) && (r.length() > 0))
{
_bot.sendNotice(_sender, Mobibot.unescapeXml(r));
}
else
{
_bot.sendNotice(_sender, "You've just won our spelling bee contest.");
}
}
catch (GoogleSearchFault e)
{
_bot.getLogger().warn("Unable to spell: " + _query, e);
_bot.sendNotice(_sender, "An error has occurred: " + e.getMessage());
}
}
else
{
try
{
GOOGLE_BEAN.getGoogleSearch(_query, GoogleSearchBean.DEFAULT_START, MAX_GOOGLE,
GoogleSearchBean.DEFAULT_FILTER, GoogleSearchBean.DEFAULT_RESTRICT,
GoogleSearchBean.DEFAULT_SAFE_SEARCH, GoogleSearchBean.DEFAULT_LR);
if (GOOGLE_BEAN.isValidResult())
{
for (int i = 0; i < GOOGLE_BEAN.getResultElementsCount(); i++)
{
_bot.sendNotice(_sender,
GOOGLE_BEAN.getResultElementProperty(i, "title").replaceAll("<([bB]|/[bB])>",
Colors.BOLD));
_bot.sendNotice(_sender, TAB_INDENT + '<' + GOOGLE_BEAN.getResultElementProperty(i, "url") +
'>');
}
}
}
catch (GoogleSearchFault e)
{
_bot.getLogger().warn("Unable to search in Google for: " + _query, e);
_bot.sendNotice(_sender, "An error has occurred: " + e.getMessage());
}
}
}
}

File diff suppressed because it is too large Load diff

View file

@ -0,0 +1,160 @@
/*
* @(#)StockQuote.java
*
* Copyright (c) 2004, Erik C. Thauvin (erik@thauvin.net)
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are
* met:
*
* Redistributions of source code must retain the above copyright notice,
* this list of conditions and the following disclaimer.
*
* Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* Neither the name of the author nor the names of its contributors may be
* used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS
* IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
* THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
* PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
* CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
* EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
* PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
* PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*
* $Id$
*
*/
package net.thauvin.erik.mobibot;
import org.apache.commons.httpclient.HttpClient;
import org.apache.commons.httpclient.methods.GetMethod;
import java.io.IOException;
/**
* Retrieves a stock quote from Yahoo!.
*
* @author Erik C. Thauvin
* @version $Revision$, $Date$
*
* @created Feb 7, 2004
* @since 1.0
*/
public class StockQuote implements Runnable
{
/**
* The Yahoo! stock quote URL.
*/
private static final String YAHOO_URL = "http://finance.yahoo.com/d/quotes.csv?&f=snl1d1t1c1oghv&e=.csv&s=";
/**
* The bot.
*/
private final Mobibot _bot;
/**
* The nick of the person who sent the message.
*/
private final String _sender;
/**
* The stock symbol.
*/
private final String _symbol;
/**
* Creates a new StockQuote object.
*
* @param bot The bot.
* @param sender The nick of the person who sent the message.
* @param symbol The stock symbol.
*/
public StockQuote(Mobibot bot, String sender, String symbol)
{
_bot = bot;
_sender = sender;
_symbol = symbol;
}
/**
* Returns the specified stock quote.
*/
public void run()
{
try
{
final HttpClient client = new HttpClient();
client.setConnectionTimeout(Mobibot.CONNECT_TIMEOUT);
client.setTimeout(Mobibot.CONNECT_TIMEOUT);
final GetMethod getMethod = new GetMethod(YAHOO_URL + _symbol.toUpperCase());
client.executeMethod(getMethod);
final String[] quote = getMethod.getResponseBodyAsString().split(",");
if (quote.length > 0)
{
if ((quote.length > 3) && (!"\"N/A\"".equalsIgnoreCase(quote[3])))
{
_bot.sendNotice(_bot.getChannel(),
"Symbol: " + quote[0].replaceAll("\"", "") + " [" + quote[1].replaceAll("\"", "") +
']');
if (quote.length > 5)
{
_bot.sendNotice(_bot.getChannel(), "Last Trade: " + quote[2] + " (" + quote[5] + ')');
}
else
{
_bot.sendNotice(_bot.getChannel(), "Last Trade: " + quote[2]);
}
if (quote.length > 4)
{
_bot.sendNotice(_sender,
"Time: " + quote[3].replaceAll("\"", "") + ' ' + quote[4].replaceAll("\"", ""));
}
if (quote.length > 6)
{
_bot.sendNotice(_sender, "Open: " + quote[6]);
}
if (quote.length > 7)
{
_bot.sendNotice(_sender, "Day's Range: " + quote[7] + " - " + quote[8]);
}
if (quote.length > 9)
{
_bot.sendNotice(_sender, "Volume: " + quote[9]);
}
}
else
{
_bot.sendNotice(_sender, "Invalid ticker symbol.");
}
}
else
{
_bot.sendNotice(_sender, "No data returned.");
}
}
catch (IOException e)
{
_bot.getLogger().debug("Unable to retrieve stock quote for: " + _symbol, e);
_bot.sendNotice(_sender, "An error has occurred: " + e.getMessage());
}
}
}

View file

@ -0,0 +1,180 @@
/*
* @(#)Weather.java
*
* Copyright (c) 2004, Erik C. Thauvin (erik@thauvin.net)
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are
* met:
*
* Redistributions of source code must retain the above copyright notice,
* this list of conditions and the following disclaimer.
*
* Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* Neither the name of the author nor the names of its contributors may be
* used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS
* IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
* THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
* PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
* CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
* EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
* PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
* PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*
* $Id$
*
*/
package net.thauvin.erik.mobibot;
import net.sf.jweather.metar.Metar;
import net.sf.jweather.metar.SkyCondition;
import net.sf.jweather.metar.WeatherCondition;
import java.util.Iterator;
/**
* Fetches the weather data from a specific station ID.
*
* @author Erik C. Thauvin
* @version $Revision$, $Date$
*
* @created Feb 7, 2004
* @since 1.0
*/
public class Weather implements Runnable
{
/**
* The URL where the stations are listed.
*/
public static final String STATIONS_URL = "http://www.rap.ucar.edu/weather/surface/stations.txt";
/**
* The bot.
*/
private final Mobibot _bot;
/**
* The nick of the person who sent the message.
*/
private final String _sender;
/**
* The station ID.
*/
private final String _station;
/**
* The private message flag.
*/
private final boolean _isPrivate;
/**
* Creates a new Weather object.
*
* @param bot The bot.
* @param sender The nick of the person who sent the message.
* @param station The station ID.
* @param isPrivate Set to true is the response should be send as a private message.
*/
public Weather(Mobibot bot, String sender, String station, boolean isPrivate)
{
_bot = bot;
_sender = sender;
_station = station;
_isPrivate = isPrivate;
}
/**
* Main processing method.
*/
public void run()
{
if (_station.length() == 4)
{
final Metar metar = net.sf.jweather.Weather.getMetar(_station);
if (metar != null)
{
Float result;
_bot.send(_sender, "Station ID: " + metar.getStationID(), _isPrivate);
result = metar.getWindSpeedInMPH();
if (result != null)
{
_bot.send(_sender, "Wind Speed: " + result + " mph, " + metar.getWindSpeedInKnots() + " knots",
_isPrivate);
}
result = metar.getVisibility();
if (result != null)
{
if (!metar.getVisibilityLessThan())
{
_bot.send(_sender, "Visibility: " + result + " mile(s)", _isPrivate);
}
else
{
_bot.send(_sender, "Visibility: < " + result + " mile(s)", _isPrivate);
}
}
result = metar.getPressure();
if (result != null)
{
_bot.send(_sender, "Pressure: " + result + " in Hg", _isPrivate);
}
result = metar.getTemperatureInCelsius();
if (result != null)
{
_bot.send(_sender, "Temperature: " + result + " C, " + metar.getTemperatureInFahrenheit() + " F",
_isPrivate);
}
if (metar.getWeatherConditions() != null)
{
final Iterator it = metar.getWeatherConditions().iterator();
while (it.hasNext())
{
final WeatherCondition weatherCondition = (WeatherCondition) it.next();
_bot.send(_sender, weatherCondition.getNaturalLanguageString(), _isPrivate);
}
}
if (metar.getSkyConditions() != null)
{
final Iterator it = metar.getSkyConditions().iterator();
while (it.hasNext())
{
final SkyCondition skyCondition = (SkyCondition) it.next();
_bot.send(_sender, skyCondition.getNaturalLanguageString(), _isPrivate);
}
}
return;
}
}
_bot.send(_sender,
"For a listing of the supported ICAO weather station IDs please visit: <" + STATIONS_URL + '>',
_isPrivate);
}
}

53
website/index.html Normal file
View file

@ -0,0 +1,53 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>mobibot</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<link rel="stylesheet" type="text/css" href="simple.css" />
</head>
<body>
<div id="content">
<h1>mobibot</h1>
<h2>The #mobitopia bot</h2>
<p class="note"> The latest version of mobibot is always available via <a href="http://www.thauvin.net/cgi-bin/viewcvs.cgi/java/mobibot/"><strong>CVS</strong></a>. </p>
<h3>About mobibot</h3>
<p><strong>mobibot</strong> is the <a href="http://www.mobitopia.com/"><strong>#mobitopia</strong></a> IRC channel bot. It is built on Paul Mutton's <a href="http://www.jibble.org/pircbot.php"><strong>PircBot Java-based Framework</strong></a>.</p>
<p>mobibot is making extensive use of various <strong>open source libraries</strong>, including:</p>
<ul>
<li><a href="http://jakarta.apache.org/commons/httpclient/">Commons HTTPClient</a></li>
<li><a href="http://jakarta.apache.org/commons/logging/">Commons Logging</a></li>
<li><a href="http://jakarta.apache.org/commons/net/">Commons Net</a></li>
<li><a href="https://fetchrss.dev.java.net/">fetchrss</a></li>
<li><a href="http://google-taglib.sourceforge.net">Google Tag Library</a></li>
<li><a href="http://sourceforge.net/projects/jweather/">JWeather</a></li>
<li><a href="http://lts.online.fr/dev/java/math.evaluator/">MathEvaluator</a></li>
<li><a href="http://enigmastation.com/rsslibj/">RSSLibJ</a></li>
</ul>
<p>mobibot was written by <a href="http://www.thauvin.net/erik/"><strong>Erik C. Thauvin</strong></a> as a replacement for the channel's original <a href="http://usefulinc.com/chump/">ChumpBot</a>. </p>
<h3>Features</h3>
<p>mobibot's main functionality is to <strong>capture URLs</strong> posted on the channel. The URLs are automatically gathered into a publishable <a href="http://www.mobitopia.com/ircrss.jsp"><strong>RSS feed</strong></a>. </p>
<p>Other features include:</p>
<ul>
<li>Performing calculations</li>
<li>Converting between currencies</li>
<li>Rolling dice</li>
<li>Performing Google searches</li>
<li>Displaying the latest entries on Mobitopia.</li>
<li>Performing DNS lookups</li>
<li>Recapping public channel messages</li>
<li>Performing Google spelling queries</li>
<li>Retrieving stock quotes</li>
<li>Displaying the time in various time zones</li>
<li>Listing the users on the channel</li>
<li>Displaying weather information</li>
</ul>
<p>Some of the internal features include RSS feed backlogs, rolling logs, debugging toggle and much more.</p>
<h3>Using mobibot</h3>
<p>To use mobibot, simply <strong>join <a href="irc://irc.freenode.net/#mobitopia">#mobitopia</a></strong> on <strong>irc.freenode.net</strong> and type:</p>
<p><code>mobibot: help</code></p>
<p>mobibot will reply with a listing of the commands currently supported.</p>
<h3>Licenses</h3>
<p>There are various open source licenses attached to mobibot. Please refer to the <strong><a href="http://www.thauvin.net/cgi-bin/viewcvs.cgi/java/mobibot/licenses/">licenses</a></strong> directory in the CVS tree for more details.</p>
</div>
</body>
</html>

52
website/simple.css Normal file
View file

@ -0,0 +1,52 @@
body {
background: #ffffff;
font-family: Verdana, Arial, Helvetica, sans-serif;
font-size: 13px;
color: #000000;
margin: 0px;
}
h1 {
color: #333399;
}
h2 {
border-bottom: 2px solid #9999cc;
}
h3 {
padding-top: 25px;
border-bottom: 1px solid #9999cc;
}
code {
font-family: Courier New, Courier, mono, monospace;
font-size: 12px;
color: #000066;
background-color: #ffeedd;
}
a:hover {
color: #ff0000;
background: #eeeeff;
}
#content {
float: none;
position: relative;
margin: 0px 10px 10px 10px;
padding: 0px 10px 10px 10px;
}
#content p {
padding-left: 10px;
}
#content p.note {
padding: 5px;
border: 1px solid #9999cc;
border-right: 2px solid #666699;
border-bottom: 2px solid #666699;
background: #eeeeff;
margin: 20px 50px;
}