編輯:關於Android編程
[cpp]
/*
* Copyright (c) 2013, 煙台大學計算機學院
* All rights reserved.
* 文件名稱:test.cpp
* 作者:樊露露
* 完成日期:2013 年 5 月 27 日
* 版本號:v1.0
*
* 輸入描述:無
* 問題描述:
* 程序輸出:
* 問題分析:
* 算法設計:略
*/
#include<iostream>
#include<string>
using namespace std;
class Teacher
{
public:
Teacher(string n,int a,char s,string ad,string t,string ti);
void display();
private:
string name;
int age;
char sex;
string add;
string tel;
string title;
};
Teacher::Teacher(string n,int a,char s,string ad,string t,string ti):name(n),age(a),sex(s),add(ad),tel(t),title(ti){ }
void Teacher::display()
{
cout<<"name:"<<name<<endl;
cout<<"age:"<<age<<endl;
cout<<"sex:"<<sex<<endl;
cout<<"title:"<<title<<endl;
cout<<"address:"<<add<<endl;
cout<<"tel:"<<tel<<endl;
}
class Cadre
{
public:
Cadre(string n,int a,char s,string ad,string t,string p);
void display();
private:
string name;
int age;
char sex;
string add;
string tel;
string post;
};
Cadre::Cadre(string n,int a,char s,string ad,string t,string p)
{
name=n;
age=a;
sex=s;
add=ad;
tel=t;
post=p;
}
void Cadre::display()
{
cout<<"name:"<<name<<endl;
cout<<"age"<<age<<endl;
cout<<"sex:"<<sex<<endl;
cout<<"post:"<<post<<endl;
cout<<"address:"<<add<<endl;
cout<<"tel:"<<tel<<endl;
}
class Teacher_Cadre:public Teacher,public Cadre
{
public:
Teacher_Cadre(string n,int a,char s,string ad,string t,string ti,string p,int w);
void show();
private:
string name;
int age;
char sex;
string add;
string tel;
int wages;
};
Teacher_Cadre::Teacher_Cadre(string n,int a,char s,string ad,string t,string ti,string p,int w):Teacher(n,a,s,ad,t,ti),Cadre(n,a,s,ad,t,p),wages(w){ }
void Teacher_Cadre::show()
{
Teacher::display();
//cout<<"post:"<<Cadre::post<<endl;
cout<<"wages:"<<wages<<endl;
}
int main()
{
Teacher_Cadre te_ca("Wang-li",50,'f',"135 Beijing Road,Shanghai","(021)61234567","president","prof.",1534);
te_ca.show( );
return 0;
}
/*
* Copyright (c) 2013, 煙台大學計算機學院
* All rights reserved.
* 文件名稱:test.cpp
* 作者:樊露露
* 完成日期:2013 年 5 月 27 日
* 版本號:v1.0
*
* 輸入描述:無
* 問題描述:
* 程序輸出:
* 問題分析:
* 算法設計:略
*/
#include<iostream>
#include<string>
using namespace std;
class Teacher
{
public:
Teacher(string n,int a,char s,string ad,string t,string ti);
void display();
private:
string name;
int age;
char sex;
string add;
string tel;
string title;
};
Teacher::Teacher(string n,int a,char s,string ad,string t,string ti):name(n),age(a),sex(s),add(ad),tel(t),title(ti){ }
void Teacher::display()
{
cout<<"name:"<<name<<endl;
cout<<"age:"<<age<<endl;
cout<<"sex:"<<sex<<endl;
cout<<"title:"<<title<<endl;
cout<<"address:"<<add<<endl;
cout<<"tel:"<<tel<<endl;
}
class Cadre
{
public:
Cadre(string n,int a,char s,string ad,string t,string p);
void display();
private:
string name;
int age;
char sex;
string add;
string tel;
string post;
};
Cadre::Cadre(string n,int a,char s,string ad,string t,string p)
{
name=n;
age=a;
sex=s;
add=ad;
tel=t;
post=p;
}
void Cadre::display()
{
cout<<"name:"<<name<<endl;
cout<<"age"<<age<<endl;
cout<<"sex:"<<sex<<endl;
cout<<"post:"<<post<<endl;
cout<<"address:"<<add<<endl;
cout<<"tel:"<<tel<<endl;
}
class Teacher_Cadre:public Teacher,public Cadre
{
public:
Teacher_Cadre(string n,int a,char s,string ad,string t,string ti,string p,int w);
void show();
private:
string name;
int age;
char sex;
string add;
string tel;
int wages;
};
Teacher_Cadre::Teacher_Cadre(string n,int a,char s,string ad,string t,string ti,string p,int w):Teacher(n,a,s,ad,t,ti),Cadre(n,a,s,ad,t,p),wages(w){ }
void Teacher_Cadre::show()
{
Teacher::display();
//cout<<"post:"<<Cadre::post<<endl;
cout<<"wages:"<<wages<<endl;
}
int main()
{
Teacher_Cadre te_ca("Wang-li",50,'f',"135 Beijing Road,Shanghai","(021)61234567","president","prof.",1534);
te_ca.show( );
return 0;
}
實現功能:實現網絡音樂歌詞下載功能(下載音樂的同時,下載對應歌詞)下載好的歌詞目前不在播放器內,可以通過文件浏覽器查看。後續將博文,將實現本地音樂歌詞下載和已下載音樂掃描
大家好,由於最近會有對智能硬件相關的開發需求,所以最近這些天分享的博文也就大致掛鉤智能硬件了,像上一篇的藍牙分享,相信很多讀者已經看過了,那麼今天我為大家帶來Androi
前言:從本篇開始,將進入Multimedia框架,包含MediaPlayer, Camera, Surface, MediaRecord, 接下來幾篇都是MediaPla
之前有很多朋友都問過我,在Android系統中怎樣才能實現靜默安裝呢?所謂的靜默安裝,就是不用彈出系統的安裝界面,在不影響用戶任何操作的情況下不知不覺地將程序裝好。雖說這