static void testTagid(short tag, short refno) throws IOException { System.out.format(" tag= %#x refno=%#x tagid=%#x \n", tag, refno, tagid(refno, tag)); }
private void addVariableAttributes(TagGroup group, Vinfo vinfo) throws IOException { // look for attributes for (int i = 0; i < group.nelems; i++) { Tag tag = tagMap.get(tagid(group.elem_ref[i], group.elem_tag[i])); if (tag == null) throw new IllegalStateException(); if (tag.code == 1962) { TagVH vh = (TagVH) tag; if (vh.className.startsWith("Att")) { Attribute att = makeAttribute(vh); if (null != att) { vinfo.v.addAttribute(att); if (att.getShortName().equals(CDM.FILL_VALUE)) vinfo.setFillValue(att); } } } } }
private void addGlobalAttributes(TagVGroup group) throws IOException { // look for attributes for (int i = 0; i < group.nelems; i++) { Tag tag = tagMap.get(tagid(group.elem_ref[i], group.elem_tag[i])); if (tag == null) throw new IllegalStateException(); if (tag.code == 1962) { TagVH vh = (TagVH) tag; if (vh.className.startsWith("Att")) { String lowername = vh.name.toLowerCase(); if ((vh.nfields == 1) && (H4type.setDataType(vh.fld_type[0], null) == DataType.CHAR) && ((vh.fld_isize[0] > 4000) || lowername.startsWith("archivemetadata") || lowername.startsWith("coremetadata") || lowername.startsWith("productmetadata") || lowername.startsWith("structmetadata"))) { ncfile.addVariable(null, makeVariable(vh)); // // large EOS metadata - make into variable in root group } else { Attribute att = makeAttribute(vh); if (null != att) ncfile.addAttribute(null, att); // make into attribute in root group } } } } group.used = true; }
private void addVariableAttributes(TagGroup group, Vinfo vinfo) throws IOException { // look for attributes for (int i = 0; i < group.nelems; i++) { Tag tag = tagMap.get(tagid(group.elem_ref[i], group.elem_tag[i])); if (tag == null) throw new IllegalStateException(); if (tag.code == 1962) { TagVH vh = (TagVH) tag; if (vh.className.startsWith("Att")) { Attribute att = makeAttribute(vh); if (null != att) { vinfo.v.addAttribute(att); if (att.getShortName().equals(CDM.FILL_VALUE)) vinfo.setFillValue(att); } } } } }
private void addVariableAttributes(TagGroup group, Vinfo vinfo) throws IOException { // look for attributes for (int i = 0; i < group.nelems; i++) { Tag tag = tagMap.get(tagid(group.elem_ref[i], group.elem_tag[i])); if (tag == null) throw new IllegalStateException(); if (tag.code == 1962) { TagVH vh = (TagVH) tag; if (vh.className.startsWith("Att")) { Attribute att = makeAttribute(vh); if (null != att) { vinfo.v.addAttribute(att); if (att.getShortName().equals(CDM.FILL_VALUE)) vinfo.setFillValue(att); } } } } }
private void addGlobalAttributes(TagVGroup group) throws IOException { // look for attributes for (int i = 0; i < group.nelems; i++) { Tag tag = tagMap.get(tagid(group.elem_ref[i], group.elem_tag[i])); if (tag == null) throw new IllegalStateException(); if (tag.code == 1962) { TagVH vh = (TagVH) tag; if (vh.className.startsWith("Att")) { String lowername = vh.name.toLowerCase(); if ((vh.nfields == 1) && (H4type.setDataType(vh.fld_type[0], null) == DataType.CHAR) && ((vh.fld_isize[0] > 4000) || lowername.startsWith("archivemetadata") || lowername.startsWith("coremetadata") || lowername.startsWith("productmetadata") || lowername.startsWith("structmetadata"))) { ncfile.addVariable(null, makeVariable(vh)); // // large EOS metadata - make into variable in root group } else { Attribute att = makeAttribute(vh); if (null != att) ncfile.addAttribute(null, att); // make into attribute in root group } } } } group.used = true; }
private void addGlobalAttributes(TagVGroup group) throws IOException { // look for attributes for (int i = 0; i < group.nelems; i++) { Tag tag = tagMap.get(tagid(group.elem_ref[i], group.elem_tag[i])); if (tag == null) throw new IllegalStateException(); if (tag.code == 1962) { TagVH vh = (TagVH) tag; if (vh.className.startsWith("Att")) { String lowername = vh.name.toLowerCase(); if ((vh.nfields == 1) && (H4type.setDataType(vh.fld_type[0], null) == DataType.CHAR) && ((vh.fld_isize[0] > 4000) || lowername.startsWith("archivemetadata") || lowername.startsWith("coremetadata") || lowername.startsWith("productmetadata") || lowername.startsWith("structmetadata"))) { ncfile.addVariable(null, makeVariable(vh)); // // large EOS metadata - make into variable in root group } else { Attribute att = makeAttribute(vh); if (null != att) ncfile.addAttribute(null, att); // make into attribute in root group } } } } group.used = true; }
Tag tag = tagMap.get(tagid(group.elem_ref[i], group.elem_tag[i])); if (tag == null) { log.warn("Image Group "+group.tag()+" has missing tag="+group.elem_ref[i]+"/"+group.elem_tag[i]); Tag tag = tagMap.get(tagid(dimTag.nt_ref, TagEnum.NT.getCode())); if (tag == null) { log.warn("Image Group "+group.tag()+" missing NT tag");
Tag tag = tagMap.get(tagid(group.elem_ref[i], group.elem_tag[i])); if (tag == null) { log.warn("Image Group "+group.tag()+" has missing tag="+group.elem_ref[i]+"/"+group.elem_tag[i]); Tag tag = tagMap.get(tagid(dimTag.nt_ref, TagEnum.NT.getCode())); if (tag == null) { log.warn("Image Group "+group.tag()+" missing NT tag");
Tag tag = tagMap.get(tagid(group.elem_ref[i], group.elem_tag[i])); if (tag == null) { log.warn("Image Group "+group.tag()+" has missing tag="+group.elem_ref[i]+"/"+group.elem_tag[i]); Tag tag = tagMap.get(tagid(dimTag.nt_ref, TagEnum.NT.getCode())); if (tag == null) { log.warn("Image Group "+group.tag()+" missing NT tag");
TagData data = null; for (int i = 0; i < group.nelems; i++) { Tag tag = tagMap.get(tagid(group.elem_ref[i], group.elem_tag[i])); if (tag == null) { log.error("Cant find tag " + group.elem_ref[i] + "/" + group.elem_tag[i] + " for group=" + group.refno); throw new IllegalStateException(); TagNumberType nt = (TagNumberType) tagMap.get(tagid(dim.nt_ref, TagEnum.NT.getCode())); if (null == nt) throw new IllegalStateException(); Tag tag = tagMap.get(tagid(group.elem_ref[i], group.elem_tag[i])); if (tag == null) throw new IllegalStateException();
Tag tag = tagMap.get(tagid(tagGroup.elem_ref[i], tagGroup.elem_tag[i])); if (tag == null) { log.error("Reference tag missing= " + tagGroup.elem_ref[i] + "/" + tagGroup.elem_tag[i] +" for group "+tagGroup.refno);
Tag tag = tagMap.get(tagid(tagGroup.elem_ref[i], tagGroup.elem_tag[i])); if (tag == null) { log.error("Reference tag missing= " + tagGroup.elem_ref[i] + "/" + tagGroup.elem_tag[i] +" for group "+tagGroup.refno);
Tag tag = tagMap.get(tagid(tagGroup.elem_ref[i], tagGroup.elem_tag[i])); if (tag == null) { log.error("Reference tag missing= " + tagGroup.elem_ref[i] + "/" + tagGroup.elem_tag[i] +" for group "+tagGroup.refno);
tagMap.put(tagid(tag.refno, tag.code), tag); // track all tags in a map, key is the "tag id". if (debugTag1) System.out.println(debugTagDetail ? tag.detail() : tag);
tagMap.put(tagid(tag.refno, tag.code), tag); // track all tags in a map, key is the "tag id". if (debugTag1) System.out.println(debugTagDetail ? tag.detail() : tag);
tagMap.put(tagid(tag.refno, tag.code), tag); // track all tags in a map, key is the "tag id". if (debugTag1) System.out.println(debugTagDetail ? tag.detail() : tag);