Trying to start a new web stack
[edit]follow link http://aphatak.blogspot.com/2010/08/star-stack.html to read and download the stack [edit]
S = SQLite (embed db and jdbc driver)
T = Tomcat (as dedicated Railo Container with SQLite JDBC driver)
A = Apache (for serving static stuff. Will try to sever this from WAMP stack, maybe)
R = Railo (cfml engine)
Off these, I have been able to take Tomcat and integrate it with Railo (this is also documented on Jamie Krugg's blog)
Remember...you saw it here first !!
Tuesday, March 30, 2010
New Web Stack (STAR)
Labels:
application server,
cfml,
coldfusion,
LAMP,
railo,
stack,
WAMP,
web application stack
Thursday, March 11, 2010
Simple things that we forget
Create a few simple classes (one extends the other)
Now test the methods from inheritance chain...
1: class A {
2: public String prop_a1 = "property a1";
3: 4: public String method_a2() {
5: return "return from method_a2";
6: } 7: }1: class B extends A {
2: public String prop_b1 = "property b1";
3: public String method_b2() {
4: return "return from method_b2";
5: } 6: }Now test the methods from inheritance chain...
1: class C {
2: public static void main(String [] args) {
3: A a = new B(); // this is upcasting
4: 5: System.out.println(a.prop_a1);
6: System.out.println(a.method_a2());
7: 8: 9: /**
10: ** The following code is compile-time error
11: ** System.out.println(a.prop_b1);
12: ** System.out.println(a.method_b2());
13: 14: C:\Java\test4>javac A.java
15: A.java:24: cannot find symbol
16: symbol : variable prop_b1
17: location: class A
18: System.out.println(a.prop_b1);
19: ^
20: A.java:25: cannot find symbol
21: symbol : method method_b2()
22: location: class A
23: System.out.println(a.method_b2());
24: ^
25: 2 errors
26: **/
27: 28: 29: 30: 31: B b = new A();
32: /**
33: ** B b = new A();
34: ** The above code is "downcasting" [I stand corrected]
35: * C:\Java\test4>javac A.java
36: A.java:45: incompatible types
37: found : A
38: required: B
39: B b = new A();
40: ^
41: 1 error
42: **/
43: 44: B b = (B)new A();
45: /**
46: * Casting will compile
47: * But causes a runtime error
48: **/
49: 50: } 51: }
[Edit]
Looking at the comments below, I feel compelled to write the reason for these snippets of code. In ActionScript 3.0, the following works in standard mode (deferred type checking)
1: class ClassBase
2: { 3: }You can subsequently create a subclass of ClassBase named ClassExtender, which has one property named someString, as follows:
1: class ClassExtender extends ClassBase
2: { 3: var someString:String; 4: }and finally:
1: var myClass:ClassBase = new ClassExtender();
2: myClass.someString = 3: "hello";
4: // no error in ActionScript 3.0 standard mode
[Edit]
Few more: public static void main(String[] args) { int i = 10; Integer I = new Integer(10); System.out.println("I == i : "+ (I == i)); // true System.out.println("I.equals(i) : "+ I.equals(i)); // true long l = 10L; System.out.println("I == l : " + (I == l)); // true Long L = new Long((long)10); System.out.println("I == L : Compiler Error...Incompatible datatypes"); System.out.println("I.equals(L) : " + I.equals(L)); // false }Saturday, December 12, 2009
X Over SSH - Simple, Straightforwad way to access remote Ubuntu desktop from local Ubuntu machine
I keep hunting for this command so I decided to document my process.
Start x display
with a simple command in Ubuntu
xinit -- :1 vt8
Use {vt8,vt9,...,vt12}
then log in to far away machine
ssh user@ip_address -X -C
-X for X Forwarding
-C for compression (don't remember the case)
once logged in use command
gnome-session
this is my window manager of choice albeit heavy. You can use others from so many available!
Ctrl+Alt+F2
Use {F2,F3,F4...F6}
Start x display
with a simple command in Ubuntu
xinit -- :1 vt8
Use {vt8,vt9,...,vt12}
then log in to far away machine
ssh user@ip_address -X -C
-X for X Forwarding
-C for compression (don't remember the case)
once logged in use command
gnome-session
this is my window manager of choice albeit heavy. You can use others from so many available!
Thursday, December 25, 2008
An overly simple Model-Glue app
So there is good documentation on Model-glue framework. I followed along with their “Pig Latin Translator” but decided I need something more realistic. Who uses a translator that translates to “Pig Latin”? So here is a more realistic Login –> Validate Login –> show view on correct login || show error and login screen on bad login info type application in Model Glue.
If you understand this and follow, you’d have known the most of model glue in its basic form.
If you understand this and follow, you’d have known the most of model glue in its basic form.
Thursday, December 04, 2008
An Overly simplistic ColdSpring Application
This just to get you started on building a basic coldspring application. This topic is beaten to death everywhere else, and I’ve just posted this to do my part in cluttering the web (and to give me a starting point in learning CS). For more documentation go here.
An example of a simple Coldspring application that has a USER bean and a USERSERVICE class.
Subscribe to:
Posts (Atom)
