/* * This is the source code of Telegram for iOS v. 1.1 * It is licensed under GNU GPL v. 2 or later. * You should have received a copy of the license in this archive (see LICENSE). * * Copyright Peter Iakovlev, 2013. */ #import #import "NSOutputStream+TL.h" #import "NSInputStream+TL.h" #ifdef __cplusplus #include "TLMetaObject.h" #include #endif #import "TLSerializationEnvironment.h" //#define TL_LOG_SERIALIZATION @protocol TLObject @required - (int32_t)TLconstructorSignature; - (int32_t)TLconstructorName; #ifdef __cplusplus - (id)TLbuildFromMetaObject:(std::tr1::shared_ptr)metaObject; - (void)TLfillFieldsWithValues:(std::map *)values; #endif @optional - (id)TLdeserialize:(NSInputStream *)is signature:(int32_t)signature environment:(id)environment context:(TLSerializationContext *)context error:(__autoreleasing NSError **)error; - (void)TLserialize:(NSOutputStream *)os; @end @protocol TLVector @required - (id)TLvectorConstruct; @end @interface NSArray (TL) - (void)TLtagConstructorName:(int32_t)constructorName; - (int32_t)TLconstructorName; @end