package uk.co.mmscomputing.device.twain; import java.util.*; class TwainEnumeration extends TwainContainer{ // TWON_ENUMERATION. Container for a collection of values. /* typedef struct { TW_UINT16 ItemType; TW_UINT32 NumItems; // How many items in ItemList TW_UINT32 CurrentIndex; // Current value is in ItemList[CurrentIndex] TW_UINT32 DefaultIndex; // Powerup value is in ItemList[DefaultIndex] TW_UINT8 ItemList[1]; // Array of ItemType values starts here } TW_ENUMERATION, FAR * pTW_ENUMERATION; */ int count; int currentIndex; int defaultIndex; // don't care = -1 Vector items=new Vector(); TwainEnumeration(int cap,byte[] container){ // TW_ENUMERATION super(cap,container); count = jtwain.getINT32(container,2); currentIndex = jtwain.getINT32(container,6); defaultIndex = jtwain.getINT32(container,10); for(int i=0,off=14;i