Lines Matching refs:ios
19 static void set(Property const &prop,std::ios_base &ios) in set() argument
22 if(ios.pword(id)==0) { in set()
23 ios.pword(id) = new Property(prop); in set()
24 ios.register_callback(callback,id); in set()
26 else if(ios.pword(id)==invalid) { in set()
27 ios.pword(id) = new Property(prop); in set()
30 *static_cast<Property *>(ios.pword(id))=prop; in set()
34 static Property &get(std::ios_base &ios) in get() argument
37 if(!has(ios)) in get()
38 set(Property(),ios); in get()
39 return *static_cast<Property *>(ios.pword(id)); in get()
42 static bool has(std::ios_base &ios) in has() argument
45 if(ios.pword(id)==0 || ios.pword(id)==invalid) in has()
50 static void unset(std::ios_base &ios) in unset() argument
52 if(has(ios)) { in unset()
54 Property *p=static_cast<Property *>(ios.pword(id)); in unset()
56 ios.pword(id)=invalid; in unset()
66 static void callback(std::ios_base::event ev,std::ios_base &ios,int id) in callback() argument
70 if(!has(ios)) in callback()
72 delete reinterpret_cast<Property *>(ios.pword(id)); in callback()
75 if(ios.pword(id)==invalid || ios.pword(id)==0) in callback()
77 ios.pword(id)=new Property(*reinterpret_cast<Property *>(ios.pword(id))); in callback()
80 if(ios.pword(id)==invalid || ios.pword(id)==0) in callback()
82 reinterpret_cast<Property *>(ios.pword(id))->on_imbue(); in callback()