001 // Copyright (c) 2011, the Dart project authors. Please see the AUTHORS file
002 // for details. All rights reserved. Use of this source code is governed by a
003 // BSD-style license that can be found in the LICENSE file.
004
005 package com.google.dart.compiler.backend.js.ast;
006
007 import com.google.dart.compiler.common.Symbol;
008
009 /**
010 * A JavaScript parameter.
011 */
012 public final class JsParameter extends SourceInfoAwareJsNode implements HasName {
013 private final JsName name;
014
015 public JsParameter(JsName name) {
016 this.name = name;
017 }
018
019 @Override
020 public JsName getName() {
021 return name;
022 }
023
024 @Override
025 public Symbol getSymbol() {
026 return name;
027 }
028
029 @Override
030 public void accept(JsVisitor v) {
031 v.visitParameter(this);
032 }
033 }