1 // Copyright 2016 The Chromium Authors. All rights reserved. 2 // Use of this source code is governed by a BSD-style license that can be 3 // found in the LICENSE file. 4 5 #include "mojo/edk/system/ports/port_ref.h" 6 7 #include "mojo/edk/system/ports/port.h" 8 9 namespace mojo { 10 namespace edk { 11 namespace ports { 12 ~PortRef()13PortRef::~PortRef() { 14 } 15 PortRef()16PortRef::PortRef() { 17 } 18 PortRef(const PortName & name,const scoped_refptr<Port> & port)19PortRef::PortRef(const PortName& name, const scoped_refptr<Port>& port) 20 : name_(name), port_(port) { 21 } 22 PortRef(const PortRef & other)23PortRef::PortRef(const PortRef& other) 24 : name_(other.name_), port_(other.port_) { 25 } 26 operator =(const PortRef & other)27PortRef& PortRef::operator=(const PortRef& other) { 28 if (&other != this) { 29 name_ = other.name_; 30 port_ = other.port_; 31 } 32 return *this; 33 } 34 35 } // namespace ports 36 } // namespace edk 37 } // namespace mojo 38