@Override
        public IntegratedSegment open(IndexMemCache indexMemCache,
                                      ExtIndexMemCache extIndexMemCache,
                                      PackMemCache packMemCache) throws IOException {
            // Open file here. The user will close it by Segment#close().
            ByteBufferReader reader = dataSource.openOnRead(0);
            // Create a wrapped reader, all open peration will directly return the opening file.
            ByteBufferReader.Opener wrappedDataSource = ByteBufferReader.Opener.create(reader);

            StorageSegment.StorageColumnCreator<IntegratedColumn> columnCreator = (ci, sc, rc) -> {
                ColumnMeta info = sectionInfo.columnInfos[ci];
                return new IntegratedColumn(
                        sectionInfo.version,
                        SegmentMode.fromId(sectionInfo.mode),
                        segmentId,
                        ci,
                        sc.name,
                        sc.sqlType,
                        sc.isIndexed,
                        rc,
                        wrappedDataSource,
                        info.dpnOffset(),
                        info.indexOffset(),
                        info.extIndexOffset(),
                        info.outerIndexOffset(),
                        info.outerIndexSize(),
                        info.packOffset(),
                        dpnCache,
                        indexMemCache,
                        extIndexMemCache,
                        packMemCache);
            };
            return new IntegratedSegment(
                    sectionInfo.version,
                    SegmentMode.fromId(sectionInfo.mode),
                    infoSegment.name(),
                    infoSegment.schema(),
                    infoSegment.rowCount(),
                    infoSegment.columnNodes(),
                    columnCreator,
                    reader);
        }
An integrated segment combines all its data into a single file, including schema, index and data.
indexr-segment/src/main/java/io/indexr/segment/storage/itg/IntegratedSegment.java