我使用iOS5故事板,而我的初始视图控制器是TabBarController
,view1和view2&view3&view4有四种关系,那么,我如何获得view3的视图控制器?
我试过了:
[[[[self.window.rootViewController navigationController] tabBarController] viewControllers] objectAtIndex:2];
Run Code Online (Sandbox Code Playgroud)
但它不起作用......
以下是JBossAS 7.1开发人员指南:
更改ResourceBundle位置在以前的AS版本中,JBOSS_HOME/server // conf /在类路径中可用.因此,该位置的属性文件在应用程序的类路径中可用.
在AS7中,要在类路径中获取这些属性,请将它们打包到应用程序中.例如,如果要部署.war,则将这些属性打包在WAR WEB-INF/classes /文件夹中.如果您希望.ear中的所有组件都可以访问这些属性,那么将它们打包在某些.jar的根目录下,并将该jar放在EAR lib /文件夹中.
但是如果资源文件太多,这种方法就不太好了,我们无法将所有资源文件打包到jar或ear.
对于新的类加载方法 - 模块.我尝试以下方法:
创建module.xml文件..您将为instnace custom.myconfig选择模块名称....
Run Code Online (Sandbox Code Playgroud)<resources> <resource-root path="."/> <!-- Insert resources here --> </resources> <dependencies> </dependencies> </module> In your jboss-deployment-structure.xml include this module to your app <jboss-deployment-structure> <ear-subdeployments-isolated>false</ear-subdeployments-isolated> <deployment> <dependencies> <module name="custom.myconfig/> </dependencies> <resources> </resources> </deployment> <sub-deployment name="My_WAR.war"> <dependencies> <module name="custom.myconfig" /> </dependencies> </sub-deployment>
https://community.jboss.org/message/723631
但是我发现你不能设置路径的绝对路径,例如:[resource-root path =""C:\ resourcefolder"].
这意味着您还需要在JBossAS 7上包含所有资源文件.
在JBossAS 5.x-6.x上非常简单,只需要将类似"C:\ resourcefolder"的文件夹路径添加到classpath即可.但它就像JBossAS7上的一个不可能完成的任务.
我将 rails 应用程序推送到 appfog,但收到以下错误消息:
/var/vcap.local/dea/apps/superb-0-dc92a2e492e46c40c06d2abc3ad59841/app/rubygems ruby/1.9.1/gems/bundler-1.1.3/lib/bundler/resolver.rb:129'block in resolve Bundler 找不到 gem "nokogiri" 的兼容版本:(Bundler::Versi nConflict) 在快照 (Gemfile.lock): nokogiri (1.5.6) 在 Gemfile: capybara (= 1.1.2) ruby 依赖于 nokogiri (>= 1.3.3) 红宝石
运行
bundle update
将从头开始重建您的快照,仅使用 Gemfile 中的 gem,这可能会解决冲突。
和我的 Gemfile:
source 'https://rubygems.org'
gem 'rails', '3.2.12'
gem 'mysql2'
gem 'pg'
gem 'thin'
gem 'sqlite3'
group :development, :test do
gem 'rspec-rails', '2.11.0'
end
# Gems used only for assets and not required
# in production environments by default.
group :assets do
gem 'sass-rails', '3.2.5' …
Run Code Online (Sandbox Code Playgroud)