Skip to content

Instantly share code, notes, and snippets.

@MasazI
Created May 20, 2015 10:55
Show Gist options
  • Select an option

  • Save MasazI/3351a11f870a0cfa8324 to your computer and use it in GitHub Desktop.

Select an option

Save MasazI/3351a11f870a0cfa8324 to your computer and use it in GitHub Desktop.
Stream.cpp (親)
//
// Stream.cpp
// CplusplusPractice
//
// Created by masai on 2015/05/20.
// Copyright (c) 2015年 masai. All rights reserved.
//
#include <iostream>
#include "Stream.hpp"
using namespace std;
double Stream::Get() const{
return m_n;
}
bool Stream::Set(){
cout << "Stream::Set" << endl;
SetBase();
return m_n >= 0;
}
// 必ず子供で実装するので実装が不要→純粋仮想関数
//void Stream::SetBase(){
// cout << "Stream::SetBase" << endl;
// m_n = -1;
//}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment