@Override public String toString() { StringBuilder buf = new StringBuilder( simpleName() + '[' ); buf.append( getId() ).append( ',' ).append( inUse() ? "in" : "no" ).append( " use" ); buf.append( ",nameId=" ).append( nameId ); additionalToString( buf ); if ( !isLight() ) { for ( DynamicRecord dyn : nameRecords ) { buf.append( ',' ).append( dyn ); } } return buf.append( ']' ).toString(); }
public List<NamedToken> getTokens() { LinkedList<NamedToken> records = new LinkedList<>(); long maxIdInUse = getHighestPossibleIdInUse(); int found = 0; RECORD record = newRecord(); for ( int i = 0; i <= maxIdInUse; i++ ) { if ( !getRecord( i, record, RecordLoad.CHECK ).inUse() ) { continue; } found++; if ( record != null && record.inUse() && record.getNameId() != Record.RESERVED.intValue() ) { records.add( new NamedToken( getStringFor( record ), i ) ); } } return records; }
@SuppressWarnings( "unchecked" ) @Override public void check( RECORD record, CheckerEngine<RECORD, REPORT> engine, RecordAccess records ) { if ( record.inUse() ) { DynamicOwner.NameOwner owner = owner( record ); DynamicOwner prev = owners.put( (long)record.getNameId(), owner ); if ( prev != null ) { engine.comparativeCheck( prev.record( records ), owner ); } } checker.check( record, engine, records ); }
@Override public void check( RECORD record, CheckerEngine<RECORD, REPORT> engine, RecordAccess records ) { if ( !record.inUse() ) { return; } if ( !Record.NO_NEXT_BLOCK.is( record.getNameId() ) ) { engine.comparativeCheck( name( records, record.getNameId() ), this ); } }
@Override public void write( RECORD record, PageCursor cursor, int recordSize ) { if ( record.inUse() ) { cursor.putByte( Record.IN_USE.byteValue() ); writeRecordData( record, cursor ); } else { cursor.putByte( Record.NOT_IN_USE.byteValue() ); } }
@Override public String toString() { StringBuilder buf = new StringBuilder( simpleName() + '[' ); buf.append( getId() ).append( ',' ).append( inUse() ? "in" : "no" ).append( " use" ); buf.append( ",nameId=" ).append( nameId ); additionalToString( buf ); if ( !isLight() ) { for ( DynamicRecord dyn : nameRecords ) { buf.append( ',' ).append( dyn ); } } return buf.append( ']' ).toString(); }
public List<NamedToken> getTokens() { LinkedList<NamedToken> records = new LinkedList<>(); long maxIdInUse = getHighestPossibleIdInUse(); int found = 0; RECORD record = newRecord(); for ( int i = 0; i <= maxIdInUse; i++ ) { if ( !getRecord( i, record, RecordLoad.CHECK ).inUse() ) { continue; } found++; if ( record != null && record.inUse() && record.getNameId() != Record.RESERVED.intValue() ) { records.add( new NamedToken( getStringFor( record ), i ) ); } } return records; }
@Override public void write( RECORD record, PageCursor cursor, int recordSize ) { if ( record.inUse() ) { cursor.putByte( Record.IN_USE.byteValue() ); writeRecordData( record, cursor ); } else { cursor.putByte( Record.NOT_IN_USE.byteValue() ); } }