|
|
@ -169,27 +169,27 @@ data class BookSource( |
|
|
|
return AppConst.SCRIPT_ENGINE.eval(jsStr, bindings) |
|
|
|
return AppConst.SCRIPT_ENGINE.eval(jsStr, bindings) |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
fun equal(source: BookSource?): Boolean { |
|
|
|
fun equal(source: BookSource): Boolean { |
|
|
|
if (source == null) { |
|
|
|
return equal(bookSourceName, source.bookSourceName) |
|
|
|
return false |
|
|
|
&& equal(bookSourceUrl, source.bookSourceUrl) |
|
|
|
} |
|
|
|
&& equal(bookSourceGroup, source.bookSourceGroup) |
|
|
|
return bookSourceName == source.bookSourceName |
|
|
|
|
|
|
|
&& bookSourceUrl == source.bookSourceUrl |
|
|
|
|
|
|
|
&& bookSourceGroup == source.bookSourceGroup |
|
|
|
|
|
|
|
&& bookSourceType == source.bookSourceType |
|
|
|
&& bookSourceType == source.bookSourceType |
|
|
|
&& bookUrlPattern == source.bookUrlPattern |
|
|
|
&& equal(bookUrlPattern, source.bookUrlPattern) |
|
|
|
&& enabled == source.enabled |
|
|
|
&& enabled == source.enabled |
|
|
|
&& enabledExplore == source.enabledExplore |
|
|
|
&& enabledExplore == source.enabledExplore |
|
|
|
&& header == source.header |
|
|
|
&& equal(header, source.header) |
|
|
|
&& loginUrl == source.loginUrl |
|
|
|
&& equal(loginUrl, source.loginUrl) |
|
|
|
&& lastUpdateTime == source.lastUpdateTime |
|
|
|
&& equal(exploreUrl, source.exploreUrl) |
|
|
|
&& exploreUrl == source.exploreUrl |
|
|
|
&& equal(searchUrl, source.searchUrl) |
|
|
|
&& searchUrl == source.searchUrl |
|
|
|
&& getSearchRule() == source.getSearchRule() |
|
|
|
&& ruleSearch == source.ruleSearch |
|
|
|
&& getExploreRule() == source.getExploreRule() |
|
|
|
&& ruleExplore == source.ruleExplore |
|
|
|
&& getBookInfoRule() == source.getBookInfoRule() |
|
|
|
&& ruleBookInfo == source.ruleBookInfo |
|
|
|
&& getTocRule() == source.getTocRule() |
|
|
|
&& ruleToc == source.ruleToc |
|
|
|
&& getContentRule() == source.getContentRule() |
|
|
|
&& ruleContent == source.ruleContent |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
private fun equal(a: String?, b: String?): Boolean { |
|
|
|
|
|
|
|
return a == b || (a.isNullOrEmpty() && b.isNullOrEmpty()) |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
data class ExploreKind( |
|
|
|
data class ExploreKind( |
|
|
|