sdr 0.6

net.cscott.sdr.calls.lists
Class BasicList

java.lang.Object
  extended by net.cscott.sdr.calls.lists.BasicList

public abstract class BasicList
extends Object

The BasicList class contains complex call and concept definitions which are on the 'basic' program. Note that "simple" calls and concepts are defined in the resource file at net/cscott/sdr/calls/lists/basic.calls; this class contains only those definitions for which an executable component is required.

Version:
$Id: BasicList.java,v 1.20 2009-02-05 06:13:31 cananian Exp $
Author:
C. Scott Ananian

Nested Class Summary
static class BasicList.LRMEvaluator
          Evaluator for left, reverse, and mirror.
static class BasicList.LRMType
          Enumeration: left, reverse, or mirror.
 
Field Summary
static Call _FRACTIONAL
          The "fractional" concept.
static Call _HALF
           
static Call _WITH_DESIGNATED
          The "with designated" concept saves the designated dancers (in the DanceState) so that they can be referred to later in the call.
static Call AND
          Simple combining concept.
static Call IN
          Time readjustment.
static Call LEFT
           
static Call QUASI_CONCENTRIC
          Like the "concentric" concept, but no adjustment for ends.
static Call REVERSE
           
 
Method Summary
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

AND

public static final Call AND
Simple combining concept.


IN

public static final Call IN
Time readjustment.


LEFT

public static final Call LEFT

REVERSE

public static final Call REVERSE

_WITH_DESIGNATED

public static final Call _WITH_DESIGNATED
The "with designated" concept saves the designated dancers (in the DanceState) so that they can be referred to later in the call. This is used for '<anyone> hop' and even for the humble '<anyone> run'. Takes at least two arguments; all except the last are tag names; dancers who match any of these tags are saved as the 'designated' ones. (Note that you can add 'DESIGNATED' as one of the tags in order to grow the designated tag set after performing another match; not sure if that would ever be necessary.)

Tests:
Show how this concept is used for 'designees run':
js> importPackage(net.cscott.sdr.calls.ast)
js> a1 = Expr.literal("_designees run")
'_designees run
js> a = new Apply(new Expr("_with designated", Expr.literal("boy"), a1))
(Apply (Expr _with designated 'boy '_designees run))

QUASI_CONCENTRIC

public static final Call QUASI_CONCENTRIC
Like the "concentric" concept, but no adjustment for ends. What's usually meant by "centers X while the ends do Y".


_FRACTIONAL

public static final Call _FRACTIONAL
The "fractional" concept.

Tests:
Evaluate TWICE DOSADO and the DOSADO 1 1/2. Note that we prohibit further subdivision of the DOSADO 1 1/2.
js> importPackage(net.cscott.sdr.calls)
js> importPackage(net.cscott.sdr.calls.ast)
js> ds = new DanceState(new DanceProgram(Program.C4), Formation.SQUARED_SET); undefined;
js> a1 = Expr.literal("dosado")
'dosado
js> a = new Expr("_fractional", Expr.literal("2"), a1)
(Expr _fractional '2 'dosado)
js> BasicList._FRACTIONAL.getEvaluator(ds, a.args).simpleExpansion()
(Seq (Apply 'dosado) (Apply 'dosado))
js> a = new Expr("_fractional", Expr.literal("1 1/2"), a1)
(Expr _fractional '1 1/2 'dosado)
js> BasicList._FRACTIONAL.getEvaluator(ds, a.args).simpleExpansion()
(Seq (Part 'INDETERMINATE '1 (Seq (Apply 'dosado) (Part 'DIVISIBLE '1 (In (Expr _multiply num '1/2 '6) (Opt (From 'ANY (Seq (Part 'INDIVISIBLE '1 (Seq (Apply '_mixed touch))) (Part 'DIVISIBLE '3 (In (Expr _multiply num '1/3 '6) (Opt (From 'RH MINIWAVE (Seq (Prim 1, 1, none, 1, SASHAY_FINISH))))))))))))))

_HALF

public static final Call _HALF

sdr 0.6

Copyright © 2006-2009 C. Scott Ananian