Minor extension point documentation changes. Added org.compiere.model.Callout extension point to ease migration of pre-OSGi ADempiere customization.
This commit is contained in:
parent
43c15413c2
commit
23086adf25
|
@ -13,6 +13,7 @@
|
|||
<extension-point id="org.adempiere.base.IDocFactory" name="Financial Document Factory" schema="schema/org.adempiere.base.IDocFactory.exsd"/>
|
||||
<extension-point id="org.adempiere.base.IGridTabExporter" name="Grid data export extension" schema="schema/org.adempiere.base.IGridTabExporter.exsd"/>
|
||||
<extension-point id="org.compiere.model.PaymentProcessor" name="Payment Processor" schema="schema/org.compiere.model.PaymentProcessor.exsd"/>
|
||||
<extension-point id="org.compiere.model.Callout" name="Callout" schema="schema/org.compiere.model.Callout.exsd"/>
|
||||
<extension
|
||||
id="org.adempiere.base.DefaultModelFactory"
|
||||
name="Default model factory"
|
||||
|
|
|
@ -76,6 +76,13 @@ Instead, you specify Table and Column in the extension declaration.
|
|||
</documentation>
|
||||
</annotation>
|
||||
</attribute>
|
||||
<attribute name="priority" type="string">
|
||||
<annotation>
|
||||
<documentation>
|
||||
numeric priority value, higher value is of higher priority.
|
||||
</documentation>
|
||||
</annotation>
|
||||
</attribute>
|
||||
</complexType>
|
||||
</element>
|
||||
|
||||
|
@ -117,7 +124,7 @@ Instead, you specify Table and Column in the extension declaration.
|
|||
<meta.section type="copyright"/>
|
||||
</appinfo>
|
||||
<documentation>
|
||||
This file is part of Adempiere ERP Bazaar http://www.adempiere.org.
|
||||
This file is part of Adempiere ERP Bazaar http://www.adempiere.org.
|
||||
|
||||
Copyright (C) Jorg Viola.
|
||||
Copyright (C) Contributors.
|
||||
|
@ -134,7 +141,6 @@ Instead, you specify Table and Column in the extension declaration.
|
|||
|
||||
Contributors:
|
||||
Heng Sin Low
|
||||
|
||||
</documentation>
|
||||
</annotation>
|
||||
|
||||
|
|
|
@ -6,7 +6,7 @@
|
|||
<meta.schema plugin="org.adempiere.base" id="org.adempiere.base.ModelValidator" name="Model Validator"/>
|
||||
</appinfo>
|
||||
<documentation>
|
||||
Extension point to provide model validator instance. Use the {extension id} syntax in AD_ModelValidator.ModelValidationClass to reference the extension that will provide the concrete ModelValidator instance ( replace {extension id} with your actual extension id ). Alternatively, you can use the EventManager service to listen to model and document event which doesn't need any AD table entry ( see event.test project for example ).
|
||||
Extension point for bundle to contribute model validator implementation. Use the {extension id} syntax in AD_ModelValidator.ModelValidationClass to reference the extension that will provide the concrete ModelValidator instance ( replace {extension id} with your actual extension id ). This extension point is provided to ease migration of pre-OSGi ADempiere code, new code is recommended to use the IEventManager service to listen to model and document event( see event.test project for example ).
|
||||
</documentation>
|
||||
</annotation>
|
||||
|
||||
|
@ -59,6 +59,13 @@
|
|||
</appinfo>
|
||||
</annotation>
|
||||
</attribute>
|
||||
<attribute name="priority" type="string">
|
||||
<annotation>
|
||||
<documentation>
|
||||
numeric priority value, higher value is of higher priority
|
||||
</documentation>
|
||||
</annotation>
|
||||
</attribute>
|
||||
</complexType>
|
||||
</element>
|
||||
|
||||
|
@ -107,7 +114,7 @@ AD_ModelValidator.ModelValidationClass="org.adempiere.extend.myModelValidat
|
|||
<meta.section type="copyright"/>
|
||||
</appinfo>
|
||||
<documentation>
|
||||
This file is part of Adempiere ERP Bazaar http://www.adempiere.org.
|
||||
This file is part of Adempiere ERP Bazaar http://www.adempiere.org.
|
||||
|
||||
Copyright (C) Jorg Viola.
|
||||
Copyright (C) Contributors.
|
||||
|
|
|
@ -6,7 +6,7 @@
|
|||
<meta.schema plugin="org.adempiere.base" id="org.adempiere.base.Process" name="Process"/>
|
||||
</appinfo>
|
||||
<documentation>
|
||||
Extension to provide process implementation. Use the {extension id} syntax in AD_Process.ClassName to reference the extension that will provide the ProcessCall/SvrProcess instance (replace {extension id} with your actual extension id )
|
||||
Extension point for bundle to contribute process implementation. Use the {extension id} syntax in AD_Process.ClassName to reference the extension that will provide the ProcessCall/SvrProcess instance (replace {extension id} with your actual extension id )
|
||||
</documentation>
|
||||
</annotation>
|
||||
|
||||
|
@ -59,6 +59,13 @@
|
|||
</appinfo>
|
||||
</annotation>
|
||||
</attribute>
|
||||
<attribute name="priority" type="string">
|
||||
<annotation>
|
||||
<documentation>
|
||||
numeric priority value, higher value is of higher priority
|
||||
</documentation>
|
||||
</annotation>
|
||||
</attribute>
|
||||
</complexType>
|
||||
</element>
|
||||
|
||||
|
@ -106,7 +113,7 @@ AD_Process.ClassName="org.adempiere.extend.myProcess"
|
|||
<meta.section type="copyright"/>
|
||||
</appinfo>
|
||||
<documentation>
|
||||
This file is part of Adempiere ERP Bazaar http://www.adempiere.org.
|
||||
This file is part of Adempiere ERP Bazaar http://www.adempiere.org.
|
||||
|
||||
Copyright (C) Jorg Viola.
|
||||
Copyright (C) Contributors.
|
||||
|
|
|
@ -0,0 +1,113 @@
|
|||
<?xml version='1.0' encoding='UTF-8'?>
|
||||
<!-- Schema file written by PDE -->
|
||||
<schema targetNamespace="org.adempiere.base" xmlns="http://www.w3.org/2001/XMLSchema">
|
||||
<annotation>
|
||||
<appinfo>
|
||||
<meta.schema plugin="org.adempiere.base" id="org.compiere.model.Callout" name="Callout"/>
|
||||
</appinfo>
|
||||
<documentation>
|
||||
Extension point for bundle to contribute Callout implementation. Use the {extension id}.{methodName} syntax in AD_Column.Callout to reference the extension that will provide the CalloutEngine instance (replace {extension id} with your actual extension id ). This extension point is provided to ease migration from pre-OSGi ADempiere code, new code is recommended to use the org.adempiere.base.IColumnCallout extension point.
|
||||
</documentation>
|
||||
</annotation>
|
||||
|
||||
<element name="extension">
|
||||
<annotation>
|
||||
<appinfo>
|
||||
<meta.element />
|
||||
</appinfo>
|
||||
</annotation>
|
||||
<complexType>
|
||||
<choice>
|
||||
<element ref="callout"/>
|
||||
</choice>
|
||||
<attribute name="point" type="string" use="required">
|
||||
<annotation>
|
||||
<documentation>
|
||||
|
||||
</documentation>
|
||||
</annotation>
|
||||
</attribute>
|
||||
<attribute name="id" type="string" use="required">
|
||||
<annotation>
|
||||
<documentation>
|
||||
|
||||
</documentation>
|
||||
</annotation>
|
||||
</attribute>
|
||||
<attribute name="name" type="string">
|
||||
<annotation>
|
||||
<documentation>
|
||||
|
||||
</documentation>
|
||||
<appinfo>
|
||||
<meta.attribute translatable="true"/>
|
||||
</appinfo>
|
||||
</annotation>
|
||||
</attribute>
|
||||
</complexType>
|
||||
</element>
|
||||
|
||||
<element name="callout">
|
||||
<complexType>
|
||||
<attribute name="class" type="string" use="required">
|
||||
<annotation>
|
||||
<documentation>
|
||||
Implementation class name that extend org.compiere.model.CalloutEngine
|
||||
</documentation>
|
||||
<appinfo>
|
||||
<meta.attribute kind="java" basedOn="org.compiere.model.CalloutEngine:"/>
|
||||
</appinfo>
|
||||
</annotation>
|
||||
</attribute>
|
||||
<attribute name="prioriy" type="string">
|
||||
<annotation>
|
||||
<documentation>
|
||||
numeric priority value, higher value is of higher priority.
|
||||
</documentation>
|
||||
</annotation>
|
||||
</attribute>
|
||||
</complexType>
|
||||
</element>
|
||||
|
||||
<annotation>
|
||||
<appinfo>
|
||||
<meta.section type="since"/>
|
||||
</appinfo>
|
||||
<documentation>
|
||||
1.0.0
|
||||
</documentation>
|
||||
</annotation>
|
||||
|
||||
<annotation>
|
||||
<appinfo>
|
||||
<meta.section type="examples"/>
|
||||
</appinfo>
|
||||
<documentation>
|
||||
<pre>
|
||||
<extension
|
||||
point="org.compiere.model.Callout"
|
||||
id="org.compiere.model.CalloutOrder"
|
||||
name="Order Callout">
|
||||
<callout
|
||||
class="org.compiere.model.CalloutOrder">
|
||||
</callout>
|
||||
</extension>
|
||||
|
||||
AD_Column.Callout="org.compiere.model.CalloutOrder.bPartner
|
||||
</pre>
|
||||
|
||||
</documentation>
|
||||
</annotation>
|
||||
|
||||
<annotation>
|
||||
<appinfo>
|
||||
<meta.section type="apiinfo"/>
|
||||
</appinfo>
|
||||
<documentation>
|
||||
Class attribute must represent a subclass of org.compiere.model.CalloutEngine
|
||||
</documentation>
|
||||
</annotation>
|
||||
|
||||
|
||||
|
||||
</schema>
|
|
@ -2854,8 +2854,14 @@ public class GridTab implements DataStatusListener, Evaluatee, Serializable
|
|||
{
|
||||
if (methodStart != -1) // no class
|
||||
{
|
||||
Class<?> cClass = Class.forName(cmd.substring(0,methodStart));
|
||||
call = (Callout)cClass.newInstance();
|
||||
String className = cmd.substring(0,methodStart);
|
||||
//first, check matching extension id in extension registry
|
||||
call = Service.locate(Callout.class, className);
|
||||
if (call == null) {
|
||||
//no match from extension registry, check java classpath
|
||||
Class<?> cClass = Class.forName(className);
|
||||
call = (Callout)cClass.newInstance();
|
||||
}
|
||||
method = cmd.substring(methodStart+1);
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue