Distribution Using Message Types 
Purpose
In Release 3.x business functions and processes are distributed using message types. A message type represents a business function. The technical structure of the message type is the IDoc type.
The programming model "Distribution using message types" contains the definitions of message types and IDoc types and the ABAP code for processing inbound and outbound IDocs.
Process Flow
Defining message types and IDoc types:
Defining New IDoc Types

The ALE interface does not allow you to create different segment data for different IDoc types for the same message type.
Writing ABAP code:
You can find information on other ALE functions under: