input
stringlengths
10
828
output
stringlengths
5
107
public void ask motd this out send motd
sends the motd command to the server which makes the server
protected void set secure final boolean secure this secure secure
changes whether this server is using ssl
public char get prefix return this prefix
returns this users prefix
protected void close throws ioexception this in close
closes the input stream
public void ban final user user final boolean kick if user get host name null this set mode b user get host name else this set mode b user get nick kick if requested if kick this kick user banned
bans a user from this channel
protected buffered reader get reader return this in
returns the reader used in this input thread
private void handle line final string line transform the raw line into an easier format final irc decoder parser new irc decoder line this irc handle numeric server replies if parser is numeric irc parser parse numeric this irc parser return handle different commands irc parser parse command this irc parser
handles a line received by the irc server
public void change topic final string topic this irc get output send topic this get name topic
changes the topic of this channel
public boolean has admin return this get prefix user prefix admin
checks whether this user has admin privileges
protected void add final string line synchronized this queue this queue add last line this queue notify
adds raw message to queue
protected void add to front final string line synchronized this queue this queue add first line this queue notify
adds raw message to the front of the queue
protected void ask names final channel channel this out send names channel get name
asks the userlist for a certain channel
protected string take string line synchronized this queue if this queue is empty try this queue wait catch final interrupted exception e return null line this queue get first this queue remove first return line
takes a raw line from the queue
public boolean has founder return this get prefix user prefix founder
checks whether this user has founder privileges
public boolean has half op return this get prefix user prefix half op
checks whether this user has halfop privileges
public boolean has operator return this get prefix user prefix operator
checks whether this user has operator privileges
private void close try close input stream this in close close output stream this out close close socket if this socket is connected this socket close catch final exception ex ignore
closes all streams
protected user get user final string nick lower return this users get nick lower
retrieves a global user object for a user in this channel
public boolean has voice return this get prefix user prefix voice
checks whether this user has voice privileges
public void give admin final user user this set mode user mode admin user true
give a user admin privileges in this channel
public boolean is us return this irc is us this
checks if this
public void give founder final user user this set mode user mode founder user true
give a user founder privileges in this channel
public void send final string message this send message message
send message to user
public void give halfop final user user this set mode user mode half op user true
give a user halfop privileges in this channel
public void send action final string action this send ctcp action action
sends an action
public void give operator final user user this set mode user mode operator user true
give a user operator privileges in this channel
public void give voice final user user this set mode user mode voice user true
give a user voice privileges in this channel
private void send ctcp final string command this irc get output send privmsg this get nick irc decoder ctcp command irc decoder ctcp
sends ctcp request
public boolean has user final string nick return this users null this users contains key nick to lower case
checks whether given user is in this channel
protected void send ctcp action final string action if action null action length 0 this send ctcp action action
sends a ctcp action command
public boolean has user final user user return this has user user get nick lower
checks whether given user is in this channel
public void send ctcp client info this send ctcp clientinfo
sends a ctcp clientinfo command
public boolean is global return this users null
checks whether this channel object is shared
public long send ctcp ping final long time system current time millis this send ctcp ping time to string return time
sends a ctcp ping command
public void join this irc get output send join this get name
attempts to join this channel
public void join final string password this irc get output send join this get name password
attempts to join this channel using given password
protected void send ctcp reply final string command this send ctcp reply command false
sends ctcp reply using notices
protected void send ctcp reply final string command final boolean skip queue if skip queue this irc get output send now notice this get nick irc decoder ctcp command irc decoder ctcp else this irc get output send notice this get nick irc decoder ctcp command irc decoder ctcp
sends ctcp reply using notices
public void kick final user user this irc get output send kick this get name user get nick
kicks given user from this channel
public void send ctcp version this send ctcp version
sends a ctcp version command to this user
public void send message final string message this irc get output send privmsg this get nick message
send message to this user
public void kick final user user final string reason this irc get output send kick this get name user get nick reason
kicks given user from this channel with reason
public void send notice final string message this irc get output send notice this get nick message
send notice to this user
protected void set nick string nick if user user prefix index of nick char at 0 0 this prefix nick char at 0 nick nick substring 1 this nick nick this nick lower nick to lower case
changes the nickname of this user
public void part this irc get output send part this get name
attempts to leave part this channel
public void remove admin final user user this set mode user mode admin user false
remove admin privileges from a user in this channel
public void remove founder final user user this set mode user mode founder user false
remove founder privileges from a user in this channel
public void remove halfop final user user this set mode user mode half op user false
remove halfop privileges from a user in this channel
public void remove operator final user user this set mode user mode operator user false
remove operator privileges from a user in this channel
protected void remove user final user user if this users null this users contains key user get nick lower this users remove user get nick lower
removes a user from the user list in this channel
public void remove voice final user user this set mode user mode voice user false
remove voice privileges from a user in this channel
public void disconnect this disconnect null
disconnects from the server
protected void rename user final string old final string neww if this users null this users contains key old final user user this users get old this users remove old user set nick neww this users put user get nick lower user
changes the nickname of a user in this channel
public void disconnect final string message if this is connected if message null message trim is empty this out send now quit else this out send now quit message else this close this get state remove all this garbage collection
disconnects from the server
private void send ctcp final string command this irc get output send privmsg this get name irc decoder ctcp command irc decoder ctcp
sends ctcp request
public void send message final string message this irc get output send privmsg this get name message
send message to channel
protected advanced listener get advanced listener return this advanced listener
gives the advanced listener used by this
public void send notice final string message this irc get output send notice this get name message
send notice to channel
public void set mode final char mode final user user final boolean toggle if toggle this set mode mode user get nick else this set mode mode user get nick
changes a channel mode for given user
public void set mode final string mode this irc get output send mode this get name mode
changes a channel mode
protected void set topic final string topic this topic topic
changes the topic of this channel
public user get client return this state get client
returns the client used by this
protected user update user final user user final boolean create new if this has user user get nick lower update user if it exists final user shared this get user user get nick lower shared update user user return shared else if create new create a new one this add user user return user return null
updates the current shared user object with changes in a fresh
public int get message delay return this message delay
returns the outgoing message delay in milliseconds
protected irc output get output return this out
returns the output thread used for sending messages through
public irc server get server return this server
returns the server this
public string get server address return this server get address
gives the server address this
public int get server port return this server get port
gives the port number this
protected string get version if this version null return this version return irc connection about
gives the version string used
public boolean is bounce allowed return this bounce allowed
returns whether this connection is allowed to be redirected
public boolean is us final user user return user equals this state get client
checks if given
public boolean is using ssl return this server is secure
checks whether this connection is using ssl
public void remove message listener final message listener listener if listener null this message listeners contains listener this message listeners remove listener
removes a message listener from this irc connection
public void remove mode listener final mode listener listener if listener null this mode listeners contains listener this mode listeners remove listener
removes a mode listener from this irc connection
public void remove server listener final server listener listener if listener null this server listeners contains listener this server listeners remove listener
removes a server listener from this irc connection
public void remove service final sircservice service if service null this services contains service service unload this this services remove service
remove a service
public void set advanced listener final advanced listener listener this advanced listener listener
sets the advanced listener used in this
public void set away final string message if message null message trim length 1 this out send away message else this out send away
marks you as away on the server
public void set bounce allowed final boolean bounce allowed this bounce allowed bounce allowed
sets whether this connection is allowed to be redirected
public void set charset final charset charset this charset charset
sets the character set to use for the connectionss encoding
protected void set connected final boolean connected this connected connected
changes the connection state of the client
public void set message delay final int message delay if message delay 0 throw new illegal argument exception message delay can t be negative this message delay message delay
sets the outgoing message delay in milliseconds
public void set nick final string nick if this is connected if nick null if this state get client null this state set client new user nick s irc null this return this state get client set nick nick else this out send now nick nick
changes the nickname of this client
public void set not away this set away null
removes the away mark
public void set server final irc server server if this is connected this server server
sets the server details to use while connecting
public void set server final string address final int port this set server address address this set server port port
sets the server details to use while connecting
public void set server address final string address if this is connected address null this server set address address
sets the server address to use while connecting
public void set server port final int port if this is connected port 0 this server set port port
sets the server address to use while connecting
public void set using ssl final boolean using ssl if this is connected this server set secure using ssl
sets whether this connection should use ssl to connect
public double resolution int zoom return 180 256 0 math pow 2 zoom
resolution arc pixel for given zoom level measured at equator
protected void ensure directory file dir new file filename map get directory if dir exists dir mkdirs
ensures that filename parent directory exists
public double resolution int zoom return 2 math pi 6378137 this tile size 2 zoom return initial resolution math pow 2 zoom
resolution meters pixel for given zoom level measured at equator
public int zoom for pixel size int pixel size for int i 0 i 30 i if pixel size resolution i if i 0 return i 1 else return 0 we don t want to scale up return 0
maximal scaledown zoom of the pyramid closest to the pixel size
public string quad tree int tx int ty int zoom string quad key ty int math pow 2 zoom 1 ty for int i zoom i 0 i int digit 0 int mask 1 i 1 if tx mask 0 digit 1 if ty mask 0 digit 2 quad key digit return quad key
converts tms tile coordinates to microsoft quad tree
public void stop system out println mpegdemux stop
shut down mpeg file
public time get duration system out println mpegdemux get duration return new time 0
return duration of the mpeg file
public boolean is positionable return seek is random access
can this stream be repositioned
public boolean is random access return seek is random access
can this stream be arbitrarily repositioned
public time get duration return demux get duration
return duration from demultiplexer
public time get start time return new time 0
return start time of this track always 0