0 Replies Latest reply on Aug 5, 2010 7:28 AM by joefirebaugh

    Array of Custom Actionscript Classes as a Component Property?

    joefirebaugh

      I have a problem where I can invision the MXML that I want to achieve, but I don't know how to structure the ActionScript classes to accomplish it.

       

      I want to make a Class that will handle thresholding of states for my custom gauge -- and I would like the MXML to look like the following.

       

      <mySpace:StatusThresholdManager>
        <mySpace:thresholds> <!-- Notice Lowercase 't' -->
          <mySpace:StatusThreshold comparison="GREATER_THAN" statusValue="75" status="critical"/>
          <mySpace:StatusThreshold comparison="GREATER_THAN" statusValue="35" status="warning"/>
          <mySpace:StatusThreshold comparison="LESS_THAN_EQ" statusValue="35" status="normal"/>
        </mySpace:thresholds>
      </mySpace:StatusThresholdManager>

       

      If possible I would like to make the comparison attribute auto prompt from a list of possible values out of an ENUM in the eclipse editor as well.  I figured this may be possible because it's kinda how the DataGrid columns are defined, as well as several other Spark components.

       

      Thanks!

       

      Joseph FIrebaugh