05_developer_tutorials:dev-guide:base-objects:user-pattern
Differences
This shows you the differences between two versions of the page.
| Both sides previous revisionPrevious revision | |||
| 05_developer_tutorials:dev-guide:base-objects:user-pattern [2025/02/19 15:51] – removed - external edit (Unknown date) 127.0.0.1 | 05_developer_tutorials:dev-guide:base-objects:user-pattern [2025/02/19 15:51] (current) – ↷ Page moved from 04_developer_documentation:dev-guide:base-objects:user-pattern to 05_developer_tutorials:dev-guide:base-objects:user-pattern gaetan | ||
|---|---|---|---|
| Line 1: | Line 1: | ||
| + | Create your own pattern 8-) | ||
| + | Simplify the query syntax ;-) | ||
| + | |||
| + | <code java> | ||
| + | module A(float len, int i) extends Sphere(0.1) | ||
| + | { | ||
| + | {setShader(GREEN); | ||
| + | public static class Patternx extends de.grogra.xl.impl.base.FieldListPattern | ||
| + | { | ||
| + | public Patternx () | ||
| + | { | ||
| + | super (A.$TYPE, | ||
| + | } | ||
| + | public static void signature (@In @Out A n, float a); | ||
| + | } | ||
| + | } | ||
| + | |||
| + | protected void init () | ||
| + | [ | ||
| + | Axiom ==> A(2, 1) A(3, 1); | ||
| + | ] | ||
| + | |||
| + | public void toto(){ | ||
| + | println((*A(3)*)); | ||
| + | |||
| + | } | ||
| + | </ | ||
