草庐IT

Unavailable

全部标签

ios - Swift - 'sharedApplication is unavailable.' 在适当的地方使用基于 View Controller 的解决方案

我正在使用以下行在我的Swift应用程序中打开一个外部URL:UIApplication.sharedApplication().openURL(url)在我通过CocoaPods将Realm添加到我的项目之前,它工作正常。那时,它开始给我以下两个编译错误:'sharedApplication()'isunavailable:Useviewcontrollerbasedsolutionswhereappropriateinstead.'openURL'isunavailable这些错误表明API对应用程序扩展不可用,但我的代码在普通应用程序中,而不是扩展中。为什么添加Realm会导致编

swift - 距离(从 :to:)' is unavailable: Any String view index conversion can fail in Swift 4; please unwrap the optional indices

我试图将我的应用程序迁移到Swift4、Xcode9。我收到此错误。它来自第3方框架。distance(from:to:)'isunavailable:AnyStringviewindexconversioncanfailinSwift4;pleaseunwraptheoptionalindicesfuncnsRange(fromrange:Range)->NSRange{letutf16view=self.utf16letfrom=range.lowerBound.samePosition(in:utf16view)letto=range.upperBound.samePositio

Swift3 & Xcode8 : ’subscript' is unavailable: cannot subscript String with a CountableClosedRange<Int>,

错误1:当我尝试从元数据中获取stringValue时,在Swift3中显示上述错误:letmyMetadata:AVMetadataMachineReadableCodeObject=metadataObjects[0]as!AVMetadataMachineReadableCodeObject//takeoutthesystemandcheck-digitsletmyBarcode=myMetadata.stringValue[1...11]//error错误2:在String的扩展中,我编写了这些以获取right(x)和left(x)函数以获取子字符串:extensionStri

ios - 'openParentApplication(_ :reply:)' has been explicitly marked unavailable here - Xcode 7 Beta

更新到Xcode7beta后,在运行代码行“WKInterfaceController.openParentApplication”时,我收到以下错误消息:“‘openParentApplication(_:reply:)’已在此处明确标记为不可用”这是我的实际代码:funcgetData(messageText:String){letinfoDictionary=["message":messageText]WKInterfaceController.openParentApplication(infoDictionary){(replyDictionary,error)->Void

swift 2.0 : 'enumerate' is unavailable: call the 'enumerate()' method on the sequence

刚刚下载了Xcode7Beta,这个错误出现在enumerate关键字上。for(index,string)inenumerate(mySwiftStringArray){}谁能帮我克服这个问题?此外,似乎count()不再用于计算String的长度。letstringLength=count(myString)在上面一行,编译器说:'count'isunavailable:accessthe'count'propertyonthecollection.Apple是否发布了Swift2.0的任何编程指南? 最佳答案 许多全局函数已被

c# - VS 2017 : The security debugging option is set but it requires the Visual Studio hosting process which is unavailable

我的解决方案(包含十几个项目)在VisualStudio2013中完美运行。在VisualStudio2017中,我可以打开解决方案并进行编译。但如果我开始调试,我会系统地收到此错误消息:ThesecuritydebuggingoptionissetbutitrequirestheVisualStudiohostingprocesswhichisunavailableinthisdebuggingconfiguration.Thesecuritydebuggingoptionwillbedisabled.Thisoptionmaybere-enabledintheSecuritypro

go - grpc-通过 https : failed rpc error: code = Unavailable desc = transport is closing:

注意:这是在Kubernetes的容器中运行。我已经成功完成了这个非常简短的描述:https://knative.dev/docs/serving/samples/grpc-ping-go/成功:2019/05/0813:43:56Pinggothello-pong2019/05/0813:43:56Gotpong2019-05-0813:43:57.646935391+0000UTCm=+1.661567121但是,如果我在https的knative设置上从网关运行443,它就不起作用:dockerrun-ti--entrypoint=/clientdocker.io/{userna

hash - Go 中的 OpenPGP 错误 : "crypto: requested hash function is unavailable"

我正在玩弄openpgp通过制作一个简单的程序来加密短消息和ASCII装甲,为Go打包。我目前的代码是:packagemainimport("code.google.com/p/go.crypto/openpgp""code.google.com/p/go.crypto/openpgp/armor""fmt""log""os")funcmain(){to,err:=openpgp.NewEntity("JohnSmith","comment","john@example.com",nil)iferr!=nil{log.Fatal(err)}from,err:=openpgp.NewEn

关于spring cloud gateway中出现503 Service Unavailable的问题

1.引用springcloudgateway+nacos配置中心2.微服务+分布式(本节与分布式问题无关)项目3.路由规则:网关端口:8085;第三方端口:8081,8086第三方单独访问路径localhost:8081/test/getUserTest?id=2希望路由到:localhost:consumer-service/test/getUserTest?id=2(这里我写了两个消费者服务,服务名一致)然后再通过openfeign去访问服务提供者localhost:provider-service/user/getUser?id=2((这里我写了3个服务提供者服务,服务名一致)(8085

git push 致命的 : unable to create thread: Resource temporarily unavailable

我是git的新手。我想将大量提交推送到远程服务器,但问题是当我使用gitpushoriginmaster返回错误Countingobjects:5009,done.Deltacompressionusingupto16threads.fatal:unabletocreatethread:Resourcetemporarilyunavailableerror:pack-objectsdiedwithstrangeerror那么我是否可以设置Delta压缩的最大线程使用量。谢谢你的帮助,陈元 最佳答案 错误:“fatal:unablet