Mercurial Hosting > luan
annotate src/luan/LuanElement.java @ 136:7e160d2f6d9c
update HttpLib, untested
git-svn-id: https://luan-java.googlecode.com/svn/trunk@137 21e917c8-12df-6dd8-5cb6-c86387c605b9
author | fschmidt@gmail.com <fschmidt@gmail.com@21e917c8-12df-6dd8-5cb6-c86387c605b9> |
---|---|
date | Wed, 11 Jun 2014 09:33:02 +0000 |
parents | 1f8b6edc2b08 |
children |
rev | line source |
---|---|
40
e3624b7cd603
implement stack trace
fschmidt@gmail.com <fschmidt@gmail.com@21e917c8-12df-6dd8-5cb6-c86387c605b9>
parents:
diff
changeset
|
1 package luan; |
e3624b7cd603
implement stack trace
fschmidt@gmail.com <fschmidt@gmail.com@21e917c8-12df-6dd8-5cb6-c86387c605b9>
parents:
diff
changeset
|
2 |
e3624b7cd603
implement stack trace
fschmidt@gmail.com <fschmidt@gmail.com@21e917c8-12df-6dd8-5cb6-c86387c605b9>
parents:
diff
changeset
|
3 |
48
64ecb7a3aad7
rename Lua to Luan
fschmidt@gmail.com <fschmidt@gmail.com@21e917c8-12df-6dd8-5cb6-c86387c605b9>
parents:
41
diff
changeset
|
4 public abstract class LuanElement { |
40
e3624b7cd603
implement stack trace
fschmidt@gmail.com <fschmidt@gmail.com@21e917c8-12df-6dd8-5cb6-c86387c605b9>
parents:
diff
changeset
|
5 |
41
c53dc854e6cc
minor
fschmidt@gmail.com <fschmidt@gmail.com@21e917c8-12df-6dd8-5cb6-c86387c605b9>
parents:
40
diff
changeset
|
6 final String toString(String fnName) { |
136
7e160d2f6d9c
update HttpLib, untested
fschmidt@gmail.com <fschmidt@gmail.com@21e917c8-12df-6dd8-5cb6-c86387c605b9>
parents:
91
diff
changeset
|
7 String s = location(); |
7e160d2f6d9c
update HttpLib, untested
fschmidt@gmail.com <fschmidt@gmail.com@21e917c8-12df-6dd8-5cb6-c86387c605b9>
parents:
91
diff
changeset
|
8 if( fnName != null ) |
7e160d2f6d9c
update HttpLib, untested
fschmidt@gmail.com <fschmidt@gmail.com@21e917c8-12df-6dd8-5cb6-c86387c605b9>
parents:
91
diff
changeset
|
9 s += ": in function '" + fnName + "'"; |
7e160d2f6d9c
update HttpLib, untested
fschmidt@gmail.com <fschmidt@gmail.com@21e917c8-12df-6dd8-5cb6-c86387c605b9>
parents:
91
diff
changeset
|
10 return s; |
40
e3624b7cd603
implement stack trace
fschmidt@gmail.com <fschmidt@gmail.com@21e917c8-12df-6dd8-5cb6-c86387c605b9>
parents:
diff
changeset
|
11 } |
e3624b7cd603
implement stack trace
fschmidt@gmail.com <fschmidt@gmail.com@21e917c8-12df-6dd8-5cb6-c86387c605b9>
parents:
diff
changeset
|
12 |
41
c53dc854e6cc
minor
fschmidt@gmail.com <fschmidt@gmail.com@21e917c8-12df-6dd8-5cb6-c86387c605b9>
parents:
40
diff
changeset
|
13 abstract String location(); |
c53dc854e6cc
minor
fschmidt@gmail.com <fschmidt@gmail.com@21e917c8-12df-6dd8-5cb6-c86387c605b9>
parents:
40
diff
changeset
|
14 |
48
64ecb7a3aad7
rename Lua to Luan
fschmidt@gmail.com <fschmidt@gmail.com@21e917c8-12df-6dd8-5cb6-c86387c605b9>
parents:
41
diff
changeset
|
15 public static final LuanElement JAVA = new LuanElement(){ |
41
c53dc854e6cc
minor
fschmidt@gmail.com <fschmidt@gmail.com@21e917c8-12df-6dd8-5cb6-c86387c605b9>
parents:
40
diff
changeset
|
16 @Override String location() { |
c53dc854e6cc
minor
fschmidt@gmail.com <fschmidt@gmail.com@21e917c8-12df-6dd8-5cb6-c86387c605b9>
parents:
40
diff
changeset
|
17 return "Java"; |
40
e3624b7cd603
implement stack trace
fschmidt@gmail.com <fschmidt@gmail.com@21e917c8-12df-6dd8-5cb6-c86387c605b9>
parents:
diff
changeset
|
18 } |
e3624b7cd603
implement stack trace
fschmidt@gmail.com <fschmidt@gmail.com@21e917c8-12df-6dd8-5cb6-c86387c605b9>
parents:
diff
changeset
|
19 }; |
e3624b7cd603
implement stack trace
fschmidt@gmail.com <fschmidt@gmail.com@21e917c8-12df-6dd8-5cb6-c86387c605b9>
parents:
diff
changeset
|
20 } |