1
0
mirror of https://github.com/twiglet/cs2j.git synced 2025-01-18 13:15:17 +01:00

86 lines
2.0 KiB
Plaintext
Raw Normal View History

group JavaPrettyPrintTemplates;
itsmine(now, includeDate) ::= <<
//
//
// This file was translated from C# to Java by CS2J (http://www.cs2j.com).
//
// This code is to be used for evaluation of the CS2J tool ONLY.
//
// For more information about CS2J please contact cs2jcontact@scorm.com
<if(includeDate)>
//
// Translated: <now><\n>
<endif>
//
>>
2010-11-16 13:51:43 +01:00
package(now, includeDate, packageName, comments, modifiers, type, endComments) ::= <<
<itsmine(now=now,includeDate=includeDate)>
package <packageName>;
<comments; separator="\n">
<type>
<endComments; separator="\n">
>>
2010-11-16 13:51:43 +01:00
// ******* CLASSES ***********
2010-11-19 16:49:43 +01:00
class(modifiers, comments, attributes, name, typeparams, inherits, body) ::= <<
<comments; separator="\n">
2010-11-19 16:49:43 +01:00
<modifiers(modifiers)>class <name> <typeparams> <inherits>
{
<body>
}
>>
iface(modifiers, comments, attributes, name, imps, body) ::= <<
<comments; separator="\n">
<modifiers(modifiers)>interface <name> <imps>
{
<body>
}
>>
class_body(entries) ::= <<
<entries; separator="\n">
>>
class_member(comments, member) ::= <<
<comments; separator="\n">
<member>
>>
field(modifiers, type, field, comments) ::= "<comments><modifiers> <type> <field>;"
2010-11-19 16:49:43 +01:00
type_param_constraint(param, constraints) ::= "<param> extends <constraints; separator=\" & \">"
// ******* ENUMS ***********
2010-11-16 13:51:43 +01:00
enum(modifiers,comments, attributes, name, body) ::= <<
2010-11-16 13:51:43 +01:00
<comments; separator="\n">
<modifiers(modifiers)>enum <name>
2010-11-16 13:51:43 +01:00
{
<body>
}
>>
enum_body(values) ::= "<values; separator=\",\n\">"
enum_member(comments, value) ::= <<
<comments; separator="\n">
<value>
>>
type(name, rs, stars, opt) ::= "<name><rs><stars><opt>"
namespace_or_type(type1, type2, types) ::= "<type1><if(type2)>::<type2><endif><if(types)>.<types; separator=\".\"><endif>"
modifiers(mods) ::= "<mods; separator=\" \"><if(mods)> <endif>"
extends(types) ::= "<if(types)>extends <types; separator=\",\"><endif>"
imps(types) ::= "<if(types)>implements <types; separator=\",\"><endif>"
2010-11-16 13:51:43 +01:00
// ******* UTILITY ***********
string(payload) ::= "<payload>"