Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(515)

Unified Diff: lib/options.dart

Issue 8437075: - Add the implementation of the Options interface to the runtime. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/runtime/
Patch Set: '' Created 9 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « lib/lib_impl_sources.gypi ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: lib/options.dart
===================================================================
--- lib/options.dart (revision 0)
+++ lib/options.dart (revision 0)
@@ -0,0 +1,18 @@
+// Copyright (c) 2011, 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.
+
+class RuntimeOptions implements Options {
+ List<String> get arguments() {
+ if (_arguments === null) {
+ // On first access make a copy of the native arguments.
+ _arguments = _nativeArguments.getRange(0, _nativeArguments.length);
+ }
+ return _arguments;
+ }
+
+ List<String> _arguments = null;
+
+ // This arguments singleton is overriden by the embedder if applicable.
+ static List<String> _nativeArguments = const [];
+}
« no previous file with comments | « lib/lib_impl_sources.gypi ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698