我的后台服务执行我的应用程序的核心功能,并且在打开UI时首先启动。
因此,当在Play商店上更新应用程序时,该服务将被终止,但UI可能不会再次打开(因此我猜该服务也不会再次启动)。这对我来说是不利的,因为该服务执行了以下功能:应用程式。我该如何克服呢?
任何帮助深表感谢
我对 C++ 中的 STL 很陌生,即使在几个小时后也无法获得正确的输出。
int main()
{
std::string str = "Hello8$World";
replace(str.begin(), str.end(), ::isdigit, " ");
replace(str.begin(), str.end(), ::ispunct, " ");
return 0;
}
Run Code Online (Sandbox Code Playgroud)
如果上述方法有效,我会非常高兴,但事实并非如此。