FileDocCategorySizeDatePackage
DDBaseKeyImpl.javaAPI DocAzureus 3.0.3.42066Thu Feb 09 19:42:46 GMT 2006org.gudy.azureus2.pluginsimpl.local.ddb

DDBaseKeyImpl

public class DDBaseKeyImpl extends Object implements org.gudy.azureus2.plugins.ddb.DistributedDatabaseKey
author
parg

Fields Summary
private Object
key
private byte[]
key_bytes
private String
description
Constructors Summary
protected DDBaseKeyImpl(Object _key)

		this( _key, null );
	
protected DDBaseKeyImpl(Object _key, String _description)

		key			= _key;
		description	= _description;
				
		key_bytes	= DDBaseHelpers.encode( key );

		if ( description == null ){
			
			if ( key instanceof String ){
				
				description = (String)key;
				
			}else{
				
				description = "[" + ByteFormatter.nicePrint(key_bytes) + "]";
			}
		}
	
Methods Summary
protected byte[]getBytes()

		return( key_bytes );
	
public java.lang.StringgetDescription()

		return( description );
	
public java.lang.ObjectgetKey()

		return( key );