com.sleepycat.persist
Interface DatabaseNamer


public interface DatabaseNamer


Field Summary
static DatabaseNamer DEFAULT
          The default database namer.
 
Method Summary
 String getFileName(String storeName, String entityClassName, String keyName)
          Returns the name of the file to be used to store the dataabase for the given store, entity class and key.
 

Field Detail

DEFAULT

static final DatabaseNamer DEFAULT
The default database namer.

The getFileName method of this namer returns the storeName, entityClassName and keyName parameters as follows:

 if (keyName != null) {
     return storeName + '-' + entityClassName + '-' + keyName;
 } else {
     return storeName + '-' + entityClassName;
 }

Method Detail

getFileName

String getFileName(String storeName,
                   String entityClassName,
                   String keyName)
Returns the name of the file to be used to store the dataabase for the given store, entity class and key. This method may not return null.

Parameters:
storeName - the name of the EntityStore.
entityClassName - the complete name of the entity class for a primary or secondary index.
keyName - the key name identifying a secondary index, or null for a primary index.


Copyright (c) 2004-2012 Oracle. All rights reserved.