This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
* Creating classes to learn a bit about java | |
*/ | |
/** | |
* Super hero classes | |
*/ | |
/** | |
* All our super heros belong to this class |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/python | |
# File: save_file.py | |
# Writes the file read from a POST method to | |
# a specified directory | |
# | |
# Use it with | |
# <form enctype="multipart/form-data" action="../cgi-bin/save_file.py" method="post"> | |
# | |
# Kish |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<html><body> | |
<form enctype="multipart/form-data" action="../cgi-bin/save_file.py" method="post"> | |
<p>File: <input type="file" name="file"></p> | |
<p><input type="submit" value="Upload"></p> | |
</form> | |
</body></html> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
server]# ls | |
AdminPortalServiceImpl.java commons-configuration-1.6.jar commons-logging-1.1.1.jar ConfReader.java README User.java | |
commons-collections-3.2.jar commons-lang-2.6.jar ConfReader.class global.xml UCService.java UserService.java | |
server]# pwd | |
/root/workspace/Conf_Reader/server | |
server]# javac ConfReader.java -cp commons-configuration-1.6.jar -cp commons-collections-3.2.jar -cp commons-lang-2.6.jar -cp commons-logging-1.1.1.jar | |
ConfReader.java:12: package org.apache.commons.configuration does not exist | |
import org.apache.commons.configuration.*; | |
^ | |
ConfReader.java:13: package org.apache.commons.lang.exception does not exist |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* Reads the configuration from the settings XML File | |
* This is for providing the params needed in the | |
* server side | |
* Created Tue Feb 15 18:59:31 IST 2011: Kish | |
* Updated to include Sipx changes Feb 25 2011: Kish | |
* | |
* | |
Needed | |
commons-collections-3.2.jar | |
commons-configuration-1.6.jar |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
List <UCService> list_ucs ; | |
/* add the subscribed services to a list */ | |
list_ucs.add(ucs) ; | |
Gives local variable list_ucs may not have been initialized. | |
List in java needs to be initiallised like | |
List <UCService> list_ucs = new ArrayList<UCService>(); /** WTF **/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
mysql> insert into user values ( 'host' , 'user', PASSWORD('SOMEPASS') ) ; | |
Query OK, 1 row affected (0.18 sec) | |
mysql> select * from user; | |
+------+------+-------------------------------------------+ | |
| Host | User | Password | | |
+------+------+-------------------------------------------+ | |
| host | user | *E16D008B9B8AD7E8509A5655514EC731A0F9A6A6 | | |
+------+------+-------------------------------------------+ | |
1 row in set (0.00 sec) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import java.util.ArrayList; | |
import java.util.HashMap; | |
import java.util.List; | |
import java.util.Map; | |
/** | |
* Adapter class to generate command string suitable for | |
* SoapCommandUtil class from User Object class |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* Reads the configuration from the settings XML File | |
* This is for providing the params needed in the | |
* server side | |
* Created Tue Feb 15 18:59:31 IST 2011: Kish | |
* Updated to include Sipx changes Feb 25 2011: Kish | |
* | |
*/ | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml version="1.0" encoding="ISO-8859-1" ?> | |
<!-- This conf file will be read to configure the client side --> | |
<!-- and the set the requried parameters in the server side --> | |
<!-- First draft: Wed Feb 16 11:19:52 IST 2011 : Kish --> | |
<!-- Added zimbra params : Mon Feb 28 21:08:01 IST 2011: Kish --> | |
<!-- Added zimbraMisc : Wed Mar 2 00:24:08 IST 2011 : Kish --> | |
<default_settings> | |
<services> |
OlderNewer