//
//  PrivateMessageRequest.m
//  SFS2X
//
//  Original development by Infosfer Game Technologies Ltd. | http://www.infosfer.com.
//
//  Maintained and developed by A51 Integrated.
//  Copyright 2012 A51 Integrated | http://a51integrated.com. All rights reserved.
//

#import "PrivateMessageRequest.h"
#import "GenericMessageType.h"

@implementation PrivateMessageRequest


-(id)initWithMessage:(NSString *)message recipientId:(NSInteger)recipientId params:(id <ISFSObject>)params {
	if ((self = [super init])) {
		_type = GenericMessageType_PRIVATE_MSG;
		self.message = message;
		self.recipient = [NSNumber numberWithInt:(int)recipientId];
		self.params = params;
	}
	return self;
}

+(id)requestWithMessage:(NSString *)message recipientId:(NSInteger)recipientId params:(id <ISFSObject>)params {
	PrivateMessageRequest *req = [[PrivateMessageRequest alloc] initWithMessage:message recipientId:recipientId params:params];
	return req;
}

+(id)requestWithMessage:(NSString *)message recipientId:(NSInteger)recipientId {
	PrivateMessageRequest *req = [[PrivateMessageRequest alloc] initWithMessage:message recipientId:recipientId params:nil];
	return req;
}

@end
