Search in sources :

Example 1 with RecordFormat

use of org.neo4j.kernel.impl.store.format.RecordFormat in project neo4j by neo4j.

the class IdGeneratorTest method makeSureIdCapacityCannotBeExceeded.

@Test
public void makeSureIdCapacityCannotBeExceeded() throws Exception {
    RecordFormats formats = Standard.LATEST_RECORD_FORMATS;
    List<RecordFormat<? extends AbstractBaseRecord>> recordFormats = Arrays.asList(formats.node(), formats.dynamic(), formats.labelToken(), formats.property(), formats.propertyKeyToken(), formats.relationship(), formats.relationshipGroup(), formats.relationshipTypeToken());
    for (RecordFormat format : recordFormats) {
        makeSureIdCapacityCannotBeExceeded(format);
    }
}
Also used : AbstractBaseRecord(org.neo4j.kernel.impl.store.record.AbstractBaseRecord) RecordFormats(org.neo4j.kernel.impl.store.format.RecordFormats) RecordFormat(org.neo4j.kernel.impl.store.format.RecordFormat) PropertyKeyTokenRecordFormat(org.neo4j.kernel.impl.store.format.standard.PropertyKeyTokenRecordFormat) RelationshipRecordFormat(org.neo4j.kernel.impl.store.format.standard.RelationshipRecordFormat) NodeRecordFormat(org.neo4j.kernel.impl.store.format.standard.NodeRecordFormat) PropertyRecordFormat(org.neo4j.kernel.impl.store.format.standard.PropertyRecordFormat) Test(org.junit.Test)

Example 2 with RecordFormat

use of org.neo4j.kernel.impl.store.format.RecordFormat in project neo4j by neo4j.

the class InputEntityCacherTokenCreationTest method mockRecordFormats.

private RecordFormats mockRecordFormats(long maxPropertyKeyId, long maxLabelId, long maxRelationshipTypeId, long maxRelationshipGroupId) {
    RecordFormats recordFormats = mock(RecordFormats.class);
    RecordFormat propertyKeyTokenFormat = getRecordFormatMock(maxPropertyKeyId);
    RecordFormat labelTokenFormat = getRecordFormatMock(maxLabelId);
    RecordFormat relationshipTypeTokenFormat = getRecordFormatMock(maxRelationshipTypeId);
    RecordFormat relationshipGroupTokenFormat = getRecordFormatMock(maxRelationshipGroupId);
    when(recordFormats.propertyKeyToken()).thenReturn(propertyKeyTokenFormat);
    when(recordFormats.labelToken()).thenReturn(labelTokenFormat);
    when(recordFormats.relationshipTypeToken()).thenReturn(relationshipTypeTokenFormat);
    when(recordFormats.relationshipGroup()).thenReturn(relationshipGroupTokenFormat);
    return recordFormats;
}
Also used : RecordFormats(org.neo4j.kernel.impl.store.format.RecordFormats) RecordFormat(org.neo4j.kernel.impl.store.format.RecordFormat)

Example 3 with RecordFormat

use of org.neo4j.kernel.impl.store.format.RecordFormat in project neo4j by neo4j.

the class InputEntityCacherTokenCreationTest method getRecordFormatMock.

private RecordFormat getRecordFormatMock(long maxId) {
    RecordFormat recordFormat = mock(RecordFormat.class);
    when(recordFormat.getMaxId()).thenReturn(maxId);
    return recordFormat;
}
Also used : RecordFormat(org.neo4j.kernel.impl.store.format.RecordFormat)

Aggregations

RecordFormat (org.neo4j.kernel.impl.store.format.RecordFormat)3 RecordFormats (org.neo4j.kernel.impl.store.format.RecordFormats)2 Test (org.junit.Test)1 NodeRecordFormat (org.neo4j.kernel.impl.store.format.standard.NodeRecordFormat)1 PropertyKeyTokenRecordFormat (org.neo4j.kernel.impl.store.format.standard.PropertyKeyTokenRecordFormat)1 PropertyRecordFormat (org.neo4j.kernel.impl.store.format.standard.PropertyRecordFormat)1 RelationshipRecordFormat (org.neo4j.kernel.impl.store.format.standard.RelationshipRecordFormat)1 AbstractBaseRecord (org.neo4j.kernel.impl.store.record.AbstractBaseRecord)1