8 Star 0 Fork 3

src-openEuler / apache-commons-chain

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
该仓库未声明开源许可证文件(LICENSE),使用请关注具体项目描述及其代码上游依赖。
克隆/下载
apache-commons-chain.spec 2.92 KB
一键复制 编辑 原始数据 按行查看 历史
lyn 提交于 2020-08-19 13:48 . package init
%global base_name chain
%global short_name commons-%{base_name}
Name: apache-commons-chain
Version: 1.2
Release: 1
Summary: An implementation of the GoF Chain of Responsibility pattern
License: ASL 2.0
URL: http://commons.apache.org/chain/
Source0: https://archive.apache.org/dist/commons/chain/source/commons-chain-%{version}-src.tar.gz
Patch0: %{name}-%{version}-tests-servlet31.patch
Patch1: %{name}-%{version}-portlet20.patch
BuildRequires: maven-local mvn(commons-beanutils:commons-beanutils)
BuildRequires: mvn(commons-digester:commons-digester) mvn(commons-logging:commons-logging)
BuildRequires: mvn(javax.portlet:portlet-api) mvn(javax.servlet:javax.servlet-api)
BuildRequires: mvn(junit:junit) mvn(org.apache.commons:commons-parent:pom:)
BuildRequires: mvn(org.jboss.spec.javax.faces:jboss-jsf-api_2.1_spec)
BuildArch: noarch
%description
A popular technique for organizing the execution of complex
processing flows is the "Chain of Responsibility" pattern, as
described (among many other places) in the classic "Gang of Four"
design patterns book. Although the fundamental API contracts
required to implement this design pattern are extremely simple,
it is useful to have a base API that facilitates using the pattern,
and (more importantly) encouraging composition of command
implementations from multiple diverse sources.
Towards that end, the Chain API models a computation as a series
of "commands" that can be combined into a "chain". The API for a
command consists of a single method (execute()), which is passed
a "context" parameter containing the dynamic state of the
computation, and whose return value is a boolean that determines
whether or not processing for the current chain has been completed
(true), or whether processing should be delegated to the next
command in the chain (false).
%package javadoc
Summary: Javadoc for %{name}
%description javadoc
This package contains javadoc for %{name}.
%prep
%setup -q -n %{short_name}-%{version}-src
find . -name '*.class' -delete
find . -name '*.jar' -delete
sed -i 's/\r$//g;' *.txt
%patch0 -p1
%patch1 -p0
rm -r src/test/org/apache/commons/chain/config/ConfigParserTestCase.java
%pom_remove_dep :myfaces-api
%pom_add_dep org.jboss.spec.javax.faces:jboss-jsf-api_2.1_spec
%pom_xpath_set "pom:dependency[pom:groupId = 'javax.servlet' ]/pom:artifactId" javax.servlet-api
%pom_xpath_set "pom:dependency[pom:groupId = 'javax.servlet' ]/pom:version" 3.1.0
%mvn_file :%{short_name} %{name}
%mvn_file :%{short_name} %{short_name}
%build
%mvn_build -- -Dmaven.compile.source=1.6 -Dmaven.compile.target=1.6
%install
%mvn_install
%files -f .mfiles
%doc RELEASE-NOTES.txt
%license LICENSE.txt NOTICE.txt
%files javadoc -f .mfiles-javadoc
%license LICENSE.txt NOTICE.txt
%changelog
* Tue Aug 4 2020 yanan li <liyanan032@huawei.com> - 1.2-1
- Package init
1
https://gitee.com/src-openeuler/apache-commons-chain.git
git@gitee.com:src-openeuler/apache-commons-chain.git
src-openeuler
apache-commons-chain
apache-commons-chain
openEuler-22.03-LTS

搜索帮助