admin
2023-04-21 0b3a4aaf99ea251bc8e27b96115288f0988fcffe
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
//
//  adModel.m
//  advertisement
//
//  Created by weikou on 16/4/20.
//  Copyright © 2016年 yuxingmin.com. All rights reserved.
//
 
#import "adModel.h"
 
@implementation adModel
 
- (instancetype)init {
    if (self = [super init]) {
        [self inital];
    }
    return self;
}
 
- (void)inital {
    _adImage = [[UIImage alloc]init];
    _adLinkUrl = [[NSString alloc]init];
    _switchtime = 15.0;
}
-(void)setNilValueForKey:(NSString *)key
{
    if ([key isEqualToString: @"adLinkUrl"]) {
        _adLinkUrl = @"www.baidu.com";
    } else {
        [super setNilValueForKey: key];    //防止使用了我们不能理解的建
    }
}
 
 
@end