//在编写子类的时候要重载父类的方法,如果子类不重写方法,则跑出异常让程序崩溃 - (void)superClassMethod { [NSException raise:NSInternalInconsistencyException format:@"It‘s an exception", NSStringFromSelector(_cmd)]; }
时间: 2024-10-25 20:36:20
//在编写子类的时候要重载父类的方法,如果子类不重写方法,则跑出异常让程序崩溃 - (void)superClassMethod { [NSException raise:NSInternalInconsistencyException format:@"It‘s an exception", NSStringFromSelector(_cmd)]; }