Difference between revisions of "User:Muhammadnasir"
m |
|||
Line 310: | Line 310: | ||
[[Image:AndroidArchitectureDetailed.gif]] | [[Image:AndroidArchitectureDetailed.gif]] | ||
− | |||
− | |||
− | |||
− | |||
− | |||
− |
Revision as of 15:42, 18 June 2011
|
Contents
- 1 ADempiere Package org.compiere.model Classes/Interfaces
- 2 Data Model Purchasing
- 3 Data Model Assets
- 4 How to Create / Update Data-Base
- 5 Go Depth in ADempiere Code
- 6 Debugging in ADempiere
- 7 How to Create New Project in Eclipse
- 8 Relationship in ADempiere
- 9 Click and Find GUI window initial call of methods
- 10 How to Identify Button class Process
- 11 Assets Data Model and Relationship
- 12 ADempiere Reporting Help
- 13 Persistent Objects PO Class
- 14 Immutable Objects in Java
- 15 Enjoy Database Related Tutorial
- 16 ADempiere Database Export / Import
- 17 Create and Apply ADempiere scheduled Database backup script
- 18 Marker Interface in Java
- 19 Extends / Uses
- 20 Talking Image
- 21 ADempiere Developer Forum Volume-1
- 22 ADempiere Developer Forum Volume-2
- 23 ADempiere Developer Forum Volume-3
- 24 ADempiere Developer Forum Volume-4
- 25 Concept of Singleton Using Java
- 26 Android Architecture Heading
- 27 Android Architecture Detailed
ADempiere Package org.compiere.model Classes/Interfaces
File:NasirADempierePackageModel.pdf
Helping Services
Introduction to Java Language
How to install JDK > Java Development Kit
How to install postgres Database
How to install JRE > Java Runtime Environment
How to ready windows to run Java based applications
How to configure server for ADempiere
How to configure clients for ADempiere
ADempiere code structure
Manage ADempiere tree
How to create new window
How to create new Tab
Create and attach a callout with fields
Create and attach a callout with a button
How to create Dynamic and Static validation lists
How to Create New Product and setting its Price
How to Manage Purchase
How to Manage Sales
Data Model Purchasing
Data Model Assets
How to Create / Update Data-Base
>> Please don't trust below instruction without any confirmation from Community Old Developers >> I always Practice on my Dummy Databases.....
Go to the "C:\Adempiere\utils" folder there will be a batch file "myEnvironment.bat" open it in notepad or textpad or wordpad or any other text file editor in the file, find out where ever the word "xe" is written (it would be on 2 places) change it from "xe" to "xe_NEW" save the file and close
then click on "RUN_DBRestore.bat" batch file it would do some processing and in the end it would have created a new database in your db application named as "xe_NEW" now when ever you will run your ADempiere application, in the 1st screen (of database connectivity) if you provide "xe" as the Database name, it would connect to the older database that you already have and if you provide "xe_NEW" as the Database name, it would connect to the new version of the database. ( But I guess, after updating the source code, it would only let you connect with the new version of the database, not with the older version any more)
Go Depth in ADempiere Code
ADempiere Deep Look In Code Depth In Code
Debugging in ADempiere
Download pdf here Debugging.pdf.
How to Create New Project in Eclipse
How to Create New Project in Eclipse
Relationship in ADempiere
I am not sure that this is correct document ,you can send me your comments to update it .
Click and Find GUI window initial call of methods
Click and find >> ClickAndFindBy_Nasir.pdf.
You can send me your comments via mail to update it .
How to Identify Button class Process
You can send me your comments via mail to update it .
Assets Data Model and Relationship
: Data Model and Relationship.
ADempiere Reporting Help
You can send me your comments via mail to update it .
Persistent Objects PO Class
PO is a persistent class in ADempiere.It is an abstract class.This persistence object class manages the database and the mapping between the database and the objects. PO class use for three of main functionality ::
- It use for Transfer of Database
- It use for calls the Triggers
- It use for calls the Model Validator
PO Class Implements three interfaces
- • Serializable (Java Built-in Interface).It is a marker Interface(Interface which have no any method).This interface only use for streaming of object.
The initial concept of object serialization is the ability to read and write objects to byte streams. Serialization involves saving the current state of an object to a stream, and restoring an equivalent object from that stream. Below images describe the Streaming of objects.
- • Comparator > (Java Built-in Interface) It consist two methods compare() and equals().These methods are implemented by PO. Because PO class implements this interface so it need to override these methods.
Methods > boolean equals(Object obj) and int compare(Object obj1, obj2)
- • Evaluatee > This is ADempiere Built-in interface. It consist only one method.
Method >public String get_ValueAsString (String variableName).
More About PO >>> PO use for POJO persistence layer that is mostly use for manages persistent objects. Persistent objects integrated with EJB. It is an abstract class that implements (Implements use for inherit with interface in java) three interfaces (Java built-in interface) by names as • Serializable • Comparator • Evaluatee
PO use for main three purposes
1. DB Transfer 2. Calls Trigger / Calls to Procedures 3. Model Validators
Don't Trust Also Explore with your gun shooooot.. -:)
Immutable Objects in Java
In Java the String class is immutable, so that once it is created a String object cannot be changed. The String class has a number of methods, that appear to modify strings. Since strings are immutable, what these methods really do is create and return a new string that contains the result of the operation.
- •How to Make a Java Class Immutable
- • A Strategy for Defining Immutable Objects
- •Immutable objects First Page
- •Immutable objects
- • Understanding Instance and Class Members
Enjoy Database Related Tutorial
- • How to install Postgres From Youtube
- • How to set the Postgres Database Priviledges.
- •JDK Installation
ADempiere Database Export / Import
I am not much familiar with Postgres -:) . But as much as I can > I am providing you some useful information from youtube,www,irc and from this page. You can export the ADempiere Database Manually. All your information that is used to export the database lies in myEnvironment.bat file. To export the database RUN_DBExport.bat file use. First Line of RUN_DBExport.bat i.e. @if (%ADEMPIERE_HOME%) == () (CALL myEnvironment.bat Server) else (CALL %ADEMPIERE_HOME%\utils\myEnvironment.bat Server) Use to include the myEnvironment.bat file into RUN_DBExport.bat .You can change export file path from default data folder to other folder / dick by modify myDBcopy.bat bat file. RUN_DBExport.bat also include myDBcopy.bat to create the copy of Database and its jar files. myDBcopy.bat generates the three files during creation of backup. File with name of ExpDat.dmp use for export purpose also. %ADEMPIERE_HOME%\data\ExpDat.dmp %ADEMPIERE_HOME%\data\ExpDat.log %ADEMPIERE_HOME%\data\ExpDat.jar
To Import the Datbase just run the RUN_DBRestore.bat by double click on it.This file take database dump from %ADEMPIERE_HOME%\data\ExpDat.dmp Directory .Again for Restore the Database it use the myEnvironment.bat file to get the database user name ,password and other information . You can see many call statements that is use to include a bat file into another bat file.
Create and Apply ADempiere scheduled Database backup script
How to create a bat file ….. Go on run and write edit and path and then file name with that you want to create the bat file ….. Save this file ….. And insert the below lines for creation of backup …. c & cd C:\Program Files\PostgreSQL\8.4\bin & pg_dumpall.exe -h localhost -p 5432 -U postgres -v -f "C:\postgres_backup.sql" C:\postgres_backup.sql show is the path where you backup file with mentioned name will save … C:\Program Files\PostgreSQL\8.4\bin text shows the bin directory of your installed Postgres Database.
After all of this you will attach this bat file with your Window scheduler …..
From control panel click for schedule tasks and click for wizard and attach that bat file with schedule setup other tasks related to scheduling <When you want to take backup>…..
Marker Interface in Java
In Java the interfaces without any methods are known as marker interfaces. Examples Of marker interfaces > Clonable,Serializable, SingleThreadModel, Event listener. E.g. Suppose you want to persist (save) the state of an object then you have to implement the Serializable interface otherwise the compiler will throw an error. Marker Interfaces are implemented by the classes or their super classes in order to add some functionality.
- •For more Detail Visit Below Links
- • Marker Interface Pattern
- • Forum Discussion on Marker Interface
Extends / Uses
How to use UML extends and uses
Talking Image
ADempiere Dictionary Tab Detail [2].
ADempiere Developer Forum Volume-1
Click Here to see the pdf file.
ADempiere Developer Forum Volume-2
Click Here to see Volume-2 file.
ADempiere Developer Forum Volume-3
Click Here to see Volume-3 file.
ADempiere Developer Forum Volume-4
Click Here to see Volume-4 file.
Concept of Singleton Using Java
package com.apps.sms.DAO; /**
* * @author nasir aftab * * * DBConnection.java * * * Created on June 02, 2011, 10:10:13 AM */
import java.sql.*; public class DBConnection {
private Connection con; static private DBConnection _instance = null; Connection getDBConnection(){ try{ Class.forName("sun.jdbc.odbc.JdbcOdbcDriver"); con = java.sql.DriverManager.getConnection("jdbc:odbc:FSMS"); }catch(Exception ex){ System.out.println(ex.getMessage()); ex.printStackTrace(); } return con; }
static public DBConnection getInstance() { if(null == _instance) { _instance = new DBConnection(); } return _instance; }
}
Android Architecture Heading