SunSPOT API V5.0


com.sun.squawk.peripheral
Interface INorFlashSectorAllocator

All Superinterfaces:
IPeripheral
All Known Implementing Classes:
NorFlashSectorAllocator, SimulatedNorFlashSectorAllocator

public interface INorFlashSectorAllocator
extends IPeripheral

INorFlashSectorAllocator is part of the implementation of the Record Management Store (see RecordStore). It should not be used for other purposes.


Method Summary
 INorFlashSector getExtraSector(int purpose)
           
 INorFlashSector[] getInitialSectors(int purpose)
           
 void releaseSector(INorFlashSector sector, int purpose)
          Notify the allocator that a previously allocated sector is no longer required
 

Method Detail

getExtraSector

INorFlashSector getExtraSector(int purpose)
                               throws InsufficientFlashMemoryException
Parameters:
purpose - code (defined in INorFlashSector) indicating purpose of sector
Returns:
a free sector
Throws:
InsufficientFlashMemoryException

getInitialSectors

INorFlashSector[] getInitialSectors(int purpose)
                                    throws IOException
Parameters:
purpose - code (defined in INorFlashSector) indicating purpose of sectors
Returns:
the sectors that were in use for this purpose at the time of the last VM exit
Throws:
InsufficientFlashMemoryException
IOException

releaseSector

void releaseSector(INorFlashSector sector,
                   int purpose)
Notify the allocator that a previously allocated sector is no longer required

Parameters:
sector - the sector to free
purpose - code (defined in INorFlashSector) indicating purpose of sector

SunSPOT API V5.0


Copyright � 2006-2008 Sun Microsystems, Inc. All Rights Reserved.