code: protected boolean index(TableIndex tableIndex, long geomId,
  			GeoPackageGeometryData geomData) {
  
  		boolean indexed = false;
  
  		if (geomData != null) {
  
  			// Get or build the envelope
  			GeometryEnvelope envelope = geomData.getOrBuildEnvelope();
  
  			// Create the new index row
  			if (envelope != null) {
  				GeometryIndex geometryIndex = geometryIndexDao.populate(
  						tableIndex, geomId, envelope);
  				try {
  					geometryIndexDao.createOrUpdate(geometryIndex);
  					indexed = true;
  				} catch (SQLException e) {
  					throw new GeoPackageException(
  							"Failed to create or update Geometry Index. GeoPackage: "
  									+ geoPackage.getName() + ", Table Name: "
  									+ tableName + ", Geom Id: " + geomId, e);
  				}
  			}
  		}
  
  		return indexed;
  	}
docs: Index the geometry id and geometry data
  
  @param tableIndex
  table index
  @param geomId
  geometry id
  @param geomData
  geometry data
  
  @return true if indexed