当前位置: 首页 > news >正文

我要用新浪云做网站常用的网站建设技术有

我要用新浪云做网站,常用的网站建设技术有,国外wordpress cms主题,南昌建设局转载自 Maven的pom.xml文件详解------The Basics Maven坐标 GroupId、artifactId和version构成了Maven的坐标#xff08;groupId和version可以从parent继承#xff09;#xff0c;指定了组件在Maven仓库中的位置。Maven中的每个组件都有一个坐标#xff0c;通过这个坐标…转载自  Maven的pom.xml文件详解------The Basics Maven坐标 GroupId、artifactId和version构成了Maven的坐标groupId和version可以从parent继承指定了组件在Maven仓库中的位置。Maven中的每个组件都有一个坐标通过这个坐标我们在自己的项目中可以设置对该组件的依赖。  ------groupId项目属于哪个组往往和项目所在的组织或公司存在关联  ------artifactId当前Maven项目在组中唯一的ID  ------version定义当前项目的版本如1.0-SNAPSHOTSNAPSHOT表示快照说明该项目还处于开发阶段是不稳定版本  ------packaging当我们有了groupId:artifactId:version作为地址后还需要packaging为我们提供组件的类型例如packagingwar/packaging标识组件为一个war。如果packaging不指定默认值为jar当前可选值为pom, jar, maven-plugin, ejb, war, ear, rar, par  ------classifier可选坐标也可以展示为groupId:artifactId:packaging:classifier:version。 POM关联 Maven的一个有力的地方就在于对项目关联的处理包括依赖、继承和聚合多模块项目。 Dependencies dependenciesdependencygroupIdjunit/groupIdartifactIdjunit/artifactIdversion4.0/versiontypejar/typescopetest/scopeoptionaltrue/optional/dependency... /dependencies ------groupId、artifactId、version依赖组件的坐标如果当Maven通过这些坐标无法从中心仓库获取该组件时可以通过下面的方法处理   1、用安装插件安装本地依赖在命令行中输入   mvn install:install-file -Dfilenon-maven-proj.jar -DgroupIdsome.group -DartifactIdnon-maven-proj -Dversion1 -Dpackagingjar   2、创建你自己的仓库并部署它   3、设置依赖scope到system并定义一个systemPath但这个不推荐。 ------type对应所以来的组件的packaging ------scop用于控制依赖的范围有以下几种范围供选择   1、compile编译依赖范围默认对于所有的classpath都是有效的   2、provided仅对编译和测试classpath有效   3、runtime编译时不需要尽在运行时需要   4、test仅用于测试   5、system和provided类似只是你需要提供JAR组件不再在仓库中查找。 ------systemPath当scop配置为system时就需要它了 dependencygroupIdjunit/groupIdartifactIdjunit/artifactIdversion4.0/versiontypejar/typescopesystem/scopesystemPath$(object.path)/lib/junit.jar/systemPathoptionaltrue/optional/dependency ------optional设置为true标识该依赖只对该项目有效如果其他项目依赖该项目该依赖将不会传递。 Exclusions 该配置告诉Maven你不想包含的该依赖的依赖即依赖传递的依赖。 dependenciesdependencygroupIdorg.apache.maven/groupIdartifactIdmaven-embedder/artifactIdversion2.0/versionexclusionsexclusiongroupIdorg.apache.maven/groupIdartifactIdmaven-core/artifactId/exclusion/exclusions/dependency... /dependencies 也可以使用通配符表示排除所有传递的依赖。 dependenciesdependencygroupIdorg.apache.maven/groupIdartifactIdmaven-embedder/artifactIdversion2.0/versionexclusionsexclusiongroupId*/groupIdartifactId*/artifactId/exclusion/exclusions/dependency... /dependencies Inheritance 继承是一个有力的工具在maven中使用继承时需要为parent和aggregation多模块项目设置packaging为pompackagingpom/packaging然后就子项目就可以继承该POM了。 parentgroupIdorg.codehaus.mojo/groupIdartifactIdmy-parent/artifactIdversion2.0/versionrelativePath../my-parent/relativePath /parent relativePath是可选的指定parent的搜索路径如果配置了Maven将首先搜索relativePath然后本地仓库最后远程仓库查找parentPOM。 POM就像Java对象最终都继承自java.lang.Object一样所有的POM都继承自一个Super POM你通过查ungjianyige最小化的pom.xml并在命令行中执行 mvn help:effective-pom来查看Super POM对你的POM的影响下面是Maven 3.0.4的Super POM该Super POM的位置在apache-maven-version\lib\maven-model-builder-version.jar\org\apache\maven\model\下面文件名pom-4.0.0.xml。 projectmodelVersion4.0.0/modelVersionrepositoriesrepositoryidcentral/idnameCentral Repository/nameurlhttp://repo.maven.apache.org/maven2/urllayoutdefault/layoutsnapshotsenabledfalse/enabled/snapshots/repository/repositoriespluginRepositoriespluginRepositoryidcentral/idnameCentral Repository/nameurlhttp://repo.maven.apache.org/maven2/urllayoutdefault/layoutsnapshotsenabledfalse/enabled/snapshotsreleasesupdatePolicynever/updatePolicy/releases/pluginRepository/pluginRepositoriesbuilddirectory${project.basedir}/target/directoryoutputDirectory${project.build.directory}/classes/outputDirectoryfinalName${project.artifactId}-${project.version}/finalNametestOutputDirectory${project.build.directory}/test-classes/testOutputDirectorysourceDirectory${project.basedir}/src/main/java/sourceDirectoryscriptSourceDirectorysrc/main/scripts/scriptSourceDirectorytestSourceDirectory${project.basedir}/src/test/java/testSourceDirectoryresourcesresourcedirectory${project.basedir}/src/main/resources/directory/resource/resourcestestResourcestestResourcedirectory${project.basedir}/src/test/resources/directory/testResource/testResourcespluginManagement!-- NOTE: These plugins will be removed from future versions of the super POM --!-- They are kept for the moment as they are very unlikely to conflict with lifecycle mappings (MNG-4453) --pluginspluginartifactIdmaven-antrun-plugin/artifactIdversion1.3/version/pluginpluginartifactIdmaven-assembly-plugin/artifactIdversion2.2-beta-5/version/pluginpluginartifactIdmaven-dependency-plugin/artifactIdversion2.1/version/pluginpluginartifactIdmaven-release-plugin/artifactIdversion2.0/version/plugin/plugins/pluginManagement/buildreportingoutputDirectory${project.build.directory}/site/outputDirectory/reportingprofiles!-- NOTE: The release profile will be removed from future versions of the super POM --profileidrelease-profile/idactivationpropertynameperformRelease/namevaluetrue/value/property/activationbuildpluginsplugininheritedtrue/inheritedartifactIdmaven-source-plugin/artifactIdexecutionsexecutionidattach-sources/idgoalsgoaljar/goal/goals/execution/executions/pluginplugininheritedtrue/inheritedartifactIdmaven-javadoc-plugin/artifactIdexecutionsexecutionidattach-javadocs/idgoalsgoaljar/goal/goals/execution/executions/pluginplugininheritedtrue/inheritedartifactIdmaven-deploy-plugin/artifactIdconfigurationupdateReleaseInfotrue/updateReleaseInfo/configuration/plugin/plugins/build/profile/profiles/project Dependency Management dependencyManagement用于在parent项目定义一个依赖如 dependencyManagementdependencies dependencygroupIdjunit/groupIdartifactIdjunit/artifactIdversion4.0/versiontypejar/typescopecompile/scopeoptionaltrue/optional/dependency/dependencies /dependencyManagement 然后从这个parent继承的POMs就能设置他们的依赖为 dependencies dependency groupIdjunit/groupIdartifactIdjunit/artifactId/dependency /dependencies 继承的POM的dependency的其它信息可以从parent的dependencyManagement中获得这样的好处在于可以将依赖的细节放在一个控制中心子项目就不用在关心依赖的细节只需要设置依赖。 Aggregation或者Multi-Module 在多模块的项目中可以将一个模块的集合配置到modules中。modulesmodulemy-project/modulemoduleanother-project/module /modules 在这里列出的模块不需要考虑顺序Maven将自己根据依赖关系排序。 Properties Maven中的Properties就像Ant中的可以在POM的任何地方通过${X}来返回属性的值X就表Poperty。 存在以下5种不同的类型 1、env.X将返回环境变量的值如${env.PATH}返回PATH环境变量的值 2、project.XPOM中的对应元素的值.表示在POM中的路径如projectversion1.0/version/project可以通过${project.version}获取值 3、settings.Xsettings.xml中包含的对应元素的值.表示路径如 settingsofflinefalse/offline/settings可以通过${settings.offline}获取 4、Java System Properties所有可以通过java.lang.System.getProperties()获取到的属性在POM属性中都是可用的如${java.home} 5、X在POM的properties /中设置的元素如 propertiessomeVarvalue/someVar/properies通过${someVar}获取。
http://www.sadfv.cn/news/207679/

相关文章:

  • 网站里宣传视频怎么做wordpress章节添加章节
  • pc网站如何做移动网站成都软件外包公司
  • 淘宝客的wordpress模板下载地址seo发布网站
  • 信息发布网站设计免费做苗木网站
  • 外贸网站模板免费下载网站访问速度优化
  • 做兼职哪个网站好住建局哪个科室最吃香
  • 织梦网站被做跳转临漳专业做网站
  • 建网站怎么分类网站建设销售前景
  • wordpress qiniu-uploader 使用南宁seo多少钱报价
  • 哪家网站做推广好优化方案系列丛书
  • 中国建设银行网站的机构wordpress文章循环不带置顶文章
  • 家庭网络如何做网站服务器百度seo流量
  • 北京京水建设集团有限公司网站上海工程建设交易信息网站
  • 淮安做网站酷站网站
  • 网站带app建设南阳建设工程信息网站
  • 温州自适应网站建设深圳做英文网站的公司
  • 网站备案时间多久网站建设客户需求调查表
  • 网站分析流程郑州餐饮网站建设哪家好
  • 河北省建设安全监督站的网站濮阳家电网站建设
  • 微擎 网站开发工具网网站制作开发
  • 营销型网站建设信融网站制作西安
  • 网站改版换域名wordpress ajax 登陆
  • php网站开发实例教程百度网站备案查询
  • 重庆渝兴建设有限公司网站自己的网站怎么和百度做友链
  • 免费 网站 模板产品宣传方式有哪些
  • 番禺学校网站建设建议电子商务网站建设的重要行
  • 贞丰县建设局网站那个网站是做房产中介的
  • 专业网站建设加盟合作搜索引擎seo
  • 网站ome系统怎么做重庆搜索引擎优化seo
  • 美心西饼在哪个网站做问卷调查河北搜索引擎推广方法