how to obtain the object's attributes which kml file loaded

I load a kml file use bellow code:

    viewer.dataSources.add(Cesium.KmlDataSource
    .load(kmlfilename)
  );

including some figures like polyline, polygon(transparent or not) and placemark, but how to obtain the object's attributes of name, type, positions and so on, when pick the figure?

thanks for your help!

Hello,

Check out this demo: http://cesiumjs.org/Cesium/Apps/Sandcastle/index.html?src=Picking.html&label=Showcases

The ‘Pick Entity’ function should show you want you need to do.

Best,

Hannah