Index: include/core/SkAnnotation.h |
diff --git a/include/core/SkAnnotation.h b/include/core/SkAnnotation.h |
index 872bb941a5dc9a490d88c80e1c40e1d64dc220e7..d7b9b84529d3524222331337e6862024b39a266d 100644 |
--- a/include/core/SkAnnotation.h |
+++ b/include/core/SkAnnotation.h |
@@ -24,18 +24,27 @@ struct SkPoint; |
*/ |
class SkAnnotation : public SkRefCnt { |
public: |
- SkAnnotation(const char key[], SkData* value); |
virtual ~SkAnnotation(); |
+ static SkAnnotation* Create(const char key[], SkData* value) { |
+ return SkNEW_ARGS(SkAnnotation, (key, value)); |
+ } |
+ |
+ static SkAnnotation* Create(SkReadBuffer& buffer) { |
+ return SkNEW_ARGS(SkAnnotation, (buffer)); |
+ } |
+ |
/** |
* Return the data for the specified key, or NULL. |
*/ |
SkData* find(const char key[]) const; |
- SkAnnotation(SkReadBuffer&); |
void writeToBuffer(SkWriteBuffer&) const; |
private: |
+ SkAnnotation(const char key[], SkData* value); |
+ SkAnnotation(SkReadBuffer&); |
+ |
SkString fKey; |
SkData* fData; |