Source:
<code>BlobIdPreamble(DataInputStream stream) throws IOException { version = stream.readShort(); byte blobIdFlag; <START> blobDataType = null; <END> switch (version) { case BLOB_ID_V1: type = BlobIdType.NATIVE; datacenterId = UNKNOWN_DATACENTER_ID; accountId = UNKNOWN_ACCOUNT_ID; containerId = UNKNOWN_CONTAINER_ID; isEncrypted = false; break; case BLOB_ID_V2: stream.readByte(); type = BlobIdType.NATIVE; datacenterId = stream.readByte(); accountId = stream.readShort(); containerId = stream.readShort(); isEncrypted = false; break; case BLOB_ID_V3: blobIdFlag = stream.readByte(); type = BlobIdType.values()[blobIdFlag & BLOB_ID_TYPE_MASK]; datacenterId = stream.readByte(); accountId = stream.readShort(); containerId = stream.readShort(); isEncrypted = false; break; case BLOB_ID_V4: blobIdFlag = stream.readByte(); type = BlobIdType.values()[blobIdFlag & BLOB_ID_TYPE_MASK]; isEncrypted = (blobIdFlag & IS_ENCRYPTED_MASK) != 0; datacenterId = stream.readByte(); accountId = stream.readShort(); containerId = stream.readShort(); break; case BLOB_ID_V5: blobIdFlag = stream.readByte(); type = BlobIdType.values()[blobIdFlag & BLOB_ID_TYPE_MASK]; isEncrypted = (blobIdFlag & IS_ENCRYPTED_MASK) != 0; int dataTypeOrdinal = (blobIdFlag & BLOB_DATA_TYPE_MASK) >> BLOB_DATA_TYPE_SHIFT; blobDataType = dataTypeOrdinal < BlobDataType.values().length ? BlobDataType.values()[dataTypeOrdinal] : null; datacenterId = stream.readByte(); accountId = stream.readShort(); containerId = stream.readShort(); break; default: throw new IllegalArgumentException("blobId version " + version + " is not supported."); } }</code><technical_language>set this null in individual cases</technical_language>

Target:
BlobIdPreamble(DataInputStream stream) throws IOException { version = stream.readShort(); byte blobIdFlag; switch (version) { case BLOB_ID_V1: type = BlobIdType.NATIVE; datacenterId = UNKNOWN_DATACENTER_ID; accountId = UNKNOWN_ACCOUNT_ID; containerId = UNKNOWN_CONTAINER_ID; isEncrypted = false; blobDataType = null; break; case BLOB_ID_V2: stream.readByte(); type = BlobIdType.NATIVE; datacenterId = stream.readByte(); accountId = stream.readShort(); containerId = stream.readShort(); isEncrypted = false; blobDataType = null; break; case BLOB_ID_V3: blobIdFlag = stream.readByte(); type = BlobIdType.values()[blobIdFlag & BLOB_ID_TYPE_MASK]; datacenterId = stream.readByte(); accountId = stream.readShort(); containerId = stream.readShort(); isEncrypted = false; blobDataType = null; break; case BLOB_ID_V4: blobIdFlag = stream.readByte(); type = BlobIdType.values()[blobIdFlag & BLOB_ID_TYPE_MASK]; isEncrypted = (blobIdFlag & IS_ENCRYPTED_MASK) != 0; datacenterId = stream.readByte(); accountId = stream.readShort(); containerId = stream.readShort(); blobDataType = null; break; case BLOB_ID_V5: blobIdFlag = stream.readByte(); type = BlobIdType.values()[blobIdFlag & BLOB_ID_TYPE_MASK]; isEncrypted = (blobIdFlag & IS_ENCRYPTED_MASK) != 0; datacenterId = stream.readByte(); accountId = stream.readShort(); containerId = stream.readShort(); int dataTypeOrdinal = (blobIdFlag & BLOB_DATA_TYPE_MASK) >> BLOB_DATA_TYPE_SHIFT; blobDataType = BlobDataType.values()[dataTypeOrdinal]; break; default: throw new IllegalArgumentException("blobId version " + version + " is not supported."); } }