use of uk.me.parabola.imgfmt.app.Section in project mkgmap by openstreetmap.
the class MDRHeader method setItemSize.
public void setItemSize(int sectionNumber, int itemSize) {
Section section = sections[sectionNumber];
section.setItemSize((char) itemSize);
}
use of uk.me.parabola.imgfmt.app.Section in project mkgmap by openstreetmap.
the class TREFileReader method getCopyrights.
public String[] getCopyrights(LBLFileReader lblReader) {
Section sect = header.getCopyrightSection();
ImgFileReader reader = getReader();
List<String> msgs = new ArrayList<>();
long pos = sect.getPosition();
while (pos < sect.getEndPos()) {
reader.position(pos);
int offset = reader.get3();
Label label = lblReader.fetchLabel(offset);
if (label != null) {
msgs.add(label.getText());
}
pos += sect.getItemSize();
}
return msgs.toArray(new String[msgs.size()]);
}
use of uk.me.parabola.imgfmt.app.Section in project mkgmap by openstreetmap.
the class TYPFile method zapZero.
private void zapZero(Section... sect) {
for (Section s : sect) {
if (s.getSize() == 0) {
s.setPosition(0);
s.setItemSize((char) 0);
}
}
}
use of uk.me.parabola.imgfmt.app.Section in project mkgmap by openstreetmap.
the class MDRHeader method setEnd.
public void setEnd(int sectionNumber, int position) {
Section s = sections[sectionNumber];
s.setSize(position - s.getPosition());
}
use of uk.me.parabola.imgfmt.app.Section in project mkgmap by openstreetmap.
the class MDRHeader method setExtraValue.
public void setExtraValue(int sectionNumber, int extraValue) {
Section section = sections[sectionNumber];
section.setExtraValue(extraValue);
}
Aggregations