| 132 | } |
| 133 | |
| 134 | const AMFField* AMFObject::Find(const char* name) const { |
| 135 | std::map<std::string, AMFField>::const_iterator it = |
| 136 | butil::find_cstr(_fields, name); |
| 137 | if (it != _fields.end()) { |
| 138 | return &it->second; |
| 139 | } |
| 140 | return NULL; |
| 141 | } |
| 142 | |
| 143 | void AMFField::SetString(const butil::StringPiece& str) { |
| 144 | // TODO: Try to reuse the space. |