refreshInterval and other elements in IconStyle->Icon

39 views
Skip to first unread message

Simon Chase

unread,
Oct 9, 2014, 7:19:15 PM10/9/14
to javaap...@googlegroups.com
Hi,

I'm experiencing a similar problem to the one this guy - http://stackoverflow.com/questions/20081299/remove-tags-from-iconstyle - experienced. When I create an Icon Style in a Style, by doing this:
  Style s = new Style();
  s
.withIconStyle(new IconStyle()
   
.withIcon()
     
.withHref("SomeStyleUrl"));


 The marshalled KML looks like this:
  <ns3:Style>
    <ns3:IconStyle>
      <ns3:scale>0.0</ns3:scale>
      <ns3:heading>0.0</ns3:heading>
      <ns3:Icon>
        <ns3:href>a-f-G-U-C-I-L</ns3:href>
        <ns3:refreshInterval>0.0</ns3:refreshInterval>
        <ns3:viewRefreshTime>0.0</ns3:viewRefreshTime>
        <ns3:viewBoundScale>0.0</ns3:viewBoundScale>
      </ns3:Icon>
    </ns3:IconStyle>
  </ns3:Style>


The OGC and Google xsd's both claim that the refreshInterval is illegal, and the Google reference for KML states that "In <IconStyle>, the only child element of <Icon> is <href>" (https://developers.google.com/kml/documentation/kmlreference?hl=de#icon). Inspection of the OGC's KML xsd (http://www.opengeospatial.org/standards/kml/) shows that, indeed, the element type of Icon is a BasicLinkType, which contains href, and no refreshInterval element. It looks like they linked to "LinkType" instead of "BasicLinkType" here, which is a mistake.

Has anyone solved this problem before? I am planning on hacking apart the code tomorrow in search of this problem.

Simon
Reply all
Reply to author
Forward
0 new messages