From 1f11299d047e8668147e19203d94f9ee3b70be4a Mon Sep 17 00:00:00 2001 From: richie Date: Fri, 19 Oct 2018 17:20:46 +0800 Subject: [PATCH] =?UTF-8?q?=E5=A2=9E=E5=8A=A0=E8=B5=84=E6=BA=90=E6=96=87?= =?UTF-8?q?=E4=BB=B6=E7=9A=84=E5=AD=98=E6=94=BE=E7=A4=BA=E4=BE=8B?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- plugin-function/plugin.xml | 1 + plugin-function/src/main/java/com/fr/plugin/MyAbs.java | 2 +- .../src/main/java/com/fr/plugin/MyLocaleFinder.java | 10 ++++++++++ .../src/main/resources/com/fr/plugin/demo.properties | 1 + .../main/resources/com/fr/plugin/demo_zh_CN.properties | 1 + 5 files changed, 14 insertions(+), 1 deletion(-) create mode 100644 plugin-function/src/main/java/com/fr/plugin/MyLocaleFinder.java create mode 100644 plugin-function/src/main/resources/com/fr/plugin/demo.properties create mode 100644 plugin-function/src/main/resources/com/fr/plugin/demo_zh_CN.properties diff --git a/plugin-function/plugin.xml b/plugin-function/plugin.xml index 4816b1a..9c96a7f 100644 --- a/plugin-function/plugin.xml +++ b/plugin-function/plugin.xml @@ -13,5 +13,6 @@ ]]> + \ No newline at end of file diff --git a/plugin-function/src/main/java/com/fr/plugin/MyAbs.java b/plugin-function/src/main/java/com/fr/plugin/MyAbs.java index 78dab4c..0e09770 100644 --- a/plugin-function/src/main/java/com/fr/plugin/MyAbs.java +++ b/plugin-function/src/main/java/com/fr/plugin/MyAbs.java @@ -12,7 +12,7 @@ import com.fr.stable.Primitive; @EnableMetrics public class MyAbs extends AbstractFunction { - @Focus(id = "com.fr.plugin.function.test", text = "Function description", source = Original.PLUGIN) + @Focus(id = "com.fr.plugin.function.test", text = "Plugin-Test_Function_Abs", source = Original.PLUGIN) public Object run(Object[] args) { int len = ArrayUtils.getLength(args); if (len == 0) { diff --git a/plugin-function/src/main/java/com/fr/plugin/MyLocaleFinder.java b/plugin-function/src/main/java/com/fr/plugin/MyLocaleFinder.java new file mode 100644 index 0000000..a062cd1 --- /dev/null +++ b/plugin-function/src/main/java/com/fr/plugin/MyLocaleFinder.java @@ -0,0 +1,10 @@ +package com.fr.plugin; + +import com.fr.stable.fun.impl.AbstractLocaleFinder; + +public class MyLocaleFinder extends AbstractLocaleFinder { + @Override + public String find() { + return "com/fr/plugin/demo"; + } +} diff --git a/plugin-function/src/main/resources/com/fr/plugin/demo.properties b/plugin-function/src/main/resources/com/fr/plugin/demo.properties new file mode 100644 index 0000000..9bc5f29 --- /dev/null +++ b/plugin-function/src/main/resources/com/fr/plugin/demo.properties @@ -0,0 +1 @@ +Plugin-Test_Function_Abs=Test ABS \ No newline at end of file diff --git a/plugin-function/src/main/resources/com/fr/plugin/demo_zh_CN.properties b/plugin-function/src/main/resources/com/fr/plugin/demo_zh_CN.properties new file mode 100644 index 0000000..aa910e8 --- /dev/null +++ b/plugin-function/src/main/resources/com/fr/plugin/demo_zh_CN.properties @@ -0,0 +1 @@ +Plugin-Test_Function_Abs=测试ABS函数 \ No newline at end of file