参考java String equals 方法: if (anObject instanceof String) { ... } 参考: https://blog.csdn.net/qq_38663729/article/details/78022990 转载于:https://my.oschina.net/hongdaorong/blog/3031243