blob: 17ce4c52f5f82bcc178a1a6959547bc327deb39f [file] [log] [blame]
<link rel="import" href="../../../../packages/polymer/polymer.html">
<link rel="import" href="observatory_element.html">
<polymer-element name="service-ref" extends="observatory-element">
</polymer-element>
<polymer-element name="any-service-ref" extends="observatory-element">
</polymer-element>
<polymer-element name="object-ref" extends="service-ref">
<template><link rel="stylesheet" href="css/shared.css">
<template if="{{ ref.isObjectPool }}">
<a on-click="{{ goto }}" _href="{{ url }}">
<em>{{ ref.vmType }}</em> ({{ ref.length }})
</a>
<curly-block callback="{{ expander() }}" expandKey="{{ expandKey }}">
<template if="{{ expanded }}">
<div class="indented">
<template repeat="{{ entry in ref.entries }}">
<div class="memberItem">
<div class="memberName">[PP+0x{{ entry['offset'].toRadixString(16) }}]</div>
<div class="memberValue">
<template if="{{ entry['kind'] == 'Object' }}">
<any-service-ref ref="{{ entry['value'] }}">
</any-service-ref>
</template>
<template if="{{ entry['kind'] == 'Immediate' }}">
Immediate 0x{{ entry['value'].toRadixString(16) }}
</template>
<template if="{{ entry['kind'] == 'NativeEntry' }}">
NativeEntry 0x{{ entry['value'].toRadixString(16) }}
</template>
</div>
</div>
</template>
</div>
</template>
</curly-block>
</template>
<template if="{{ ref.isICData || ref.isMegamorphicCache }}">
<a on-click="{{ goto }}" _href="{{ url }}">
<em>{{ ref.vmType }}</em> ({{ ref.selector }})
</a>
</template>
<template if="{{ ref.isInstructions }}">
<a on-click="{{ goto }}" _href="{{ url }}">
<em>{{ ref.vmType }}</em> ({{ ref.code.name }})
</a>
</template>
<template if="{{ !(ref.isObjectPool || ref.isICData || ref.isMegamorphicCache || ref.isInstructions) }}">
<template if="{{ nameIsEmpty }}">
<a on-click="{{ goto }}" _href="{{ url }}"><em>{{ ref.vmType }}</em></a>
</template>
<template if="{{ !nameIsEmpty }}">
<a on-click="{{ goto }}" _href="{{ url }}"><em>{{ name }}</em></a>
</template>
</template>
</template>
</polymer-element>
<script type="application/dart" src="service_ref.dart"></script>