blob: f2b71e830a698bf14b06d32715fb7006dd9a0e2c [file] [log] [blame]
// Copyright (c) 2018, the Dart project authors. Please see the AUTHORS file
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
library vm.metadata.obfuscation_prohibitions;
import 'package:kernel/ast.dart';
class ObfuscationProhibitionsMetadata {
final Set<String> protectedNames = Set<String>();
String toString() => protectedNames.toString();
/// Repository for [ObfuscationProhibitionsMetadata].
class ObfuscationProhibitionsMetadataRepository
extends MetadataRepository<ObfuscationProhibitionsMetadata> {
static final repositoryTag = 'vm.obfuscation-prohibitions.metadata';
final String tag = repositoryTag;
final Map<TreeNode, ObfuscationProhibitionsMetadata> mapping =
<TreeNode, ObfuscationProhibitionsMetadata>{};
void writeToBinary(
ObfuscationProhibitionsMetadata metadata, Node node, BinarySink sink) {
for (String name in metadata.protectedNames) {
ObfuscationProhibitionsMetadata readFromBinary(
Node node, BinarySource source) {
final metadata = ObfuscationProhibitionsMetadata();
int length = source.readUint32();
for (int i = 0; i < length; ++i) {
return metadata;