git-svn-id: svn://db.shs.com.ru/pip@623 12ceb7fc-bf1f-11e4-8940-5bc7170c53b5
This commit is contained in:
@@ -32,5 +32,24 @@ PICout(AddSpaces | AddNewLine | AddQuotes) << Tab << "tab and" << "quotes";
|
||||
// "tab and" "quotes"
|
||||
//! [0]
|
||||
|
||||
}
|
||||
|
||||
|
||||
//! [notifier]
|
||||
class A: public PIObject {
|
||||
PIOBJECT(A)
|
||||
public:
|
||||
A() {}
|
||||
EVENT_HANDLER2(void, pcf, int, id, PIString*, buff) {
|
||||
piCout << "PICout(" << id << ") finished:" << (*buff);
|
||||
}
|
||||
};
|
||||
int main() {
|
||||
A a;
|
||||
CONNECTU(PICout::Notifier::object(), finished, &a, pcf);
|
||||
PIString buffer = "my buff:";
|
||||
PICout(&buffer, 1) << "int 10 ->" << 10 << ", time ->" << PITime::current();
|
||||
return 0;
|
||||
}
|
||||
// PICout( 1 ) finished: my buff:int 10 -> 10 , time -> PITime(14:07:09:000)
|
||||
//! [notifier]
|
||||
|
||||
Reference in New Issue
Block a user