The syntax of the flow operation of Delphi

Source: Internet
Author: User

Delphi has done quite well in both respects. In earlier versions of Delphi, Turbo Pascal had classes dedicated to object-type data management such as streams, groups (Collection), and Resources (Resource). In Delphi, these functions have been greatly enhanced. Delphi boils down to object-type data management classes as stream objects (stream) and Filer objects (Filer) and applies them to all aspects of the visual Part class library (VCL). They provide not only the ability to manage objects in memory, external memory, and Windows system resources, but also the functionality of objects in database blob fields.

In this chapter, we will introduce the implementation principle, application method and application of stream object and filer object in Hypermedia system. This is very important for using Delphi to develop advanced applications.

The realization principle and application of 20.1 flow-type Object


Stream objects, also known as streaming objects, are collectively referred to as Tstream, Thandlestream, TFileStream, Tmemorystream, Tresourcestream, and Tblobstream. They represent the ability to store data on a variety of mediums, abstracting the management operations of various data types (including objects and parts) in memory, external memory, and database fields into object methods, and leveraging the benefits of object-oriented technology to make it fairly easy for applications to copy data across various stream objects.

The following describes the data and methods of various objects and how to use them.

20.1.1 Tstream Object

Tstream objects are abstract objects that can store binary data in various mediums. Objects inherited from the Tstream object are used to store data in media such as memory, Windows System resource files, disk files, and database fields.

Two properties are defined in Tstream: size and position. They represent the size of the stream and the current pointer position, respectively, in bytes. The methods defined in Tstream are used to read, write, and copy binary data to and from each stream. Because all stream objects are inherited from Tstream, the fields and methods defined in Tstream can be called and accessed by the Stream object. In addition, due to the dynamic linking function of object-oriented technology, TSTREAM provides a unified interface for the application of various streams, which simplifies the use of streams. Different stream objects are abstract operations on data from different storage mediums, so The Tstream method provides the simplest means of copying data between different mediums.

Properties and methods of 20.1.1.1 Tstream

1. Position Properties

Statement: Property position:longint;

The Position property indicates the current offset to read and write in the stream.

2. Size Property

Statement: Property size:longint;

The Size property indicates the volume of the stream in bytes, which is read-only.

3. CopyFrom method

Statement: function CopyFrom (source:tstream; Count:longint): Longint;

CopyFrom copies count bytes from the stream specified by source to the current stream, and moves the pointer from the current position count bytes, the function return value is the actual copy of the number of bytes.

4. The Read method

Statement: function Read (var Buffer; Count:longint): Longint; Virtual Abstract

The Read method copies the contents of count bytes to buffer from the current position in the current stream and moves the current pointer backwards by count bytes, which is the actual number of bytes read. If the return value is less than count, this means that the read operation has reached the end of the stream before reading the required number of bytes.

The Read method is an abstract method. Each subsequent stream object overwrites the method according to its own specific read operation on a particular storage medium. And all other methods of reading data (such as: readbuffer,readcomponent, etc.) are called by the Read method when the actual read operation is completed. The benefits of object-oriented dynamic linking are now here. Because subsequent stream objects simply overwrite the Read method, other read operations (such as Readbuffer, Readcomponent, and so on) do not have to be redefined, and Tstream provides a unified interface.

5. Readbuffer method

Statement: Procedure Readbuffer (Var Buffer; Count:longint);

The Readbuffer method copies count bytes from the stream into buffer and moves the current pointer of the stream backwards by count bytes. If the read operation exceeds the end of the stream, the Readbuffer method causes the Ereaderror exception event.

6. Readcomponent method

Declaration: Function Readcomponent (instance:tcomponent): tcomponent;

The Readcomponent method reads the part specified by instance from the current stream, and the function returns the part that is being read. Readcomponent creates a reader object and calls his Readrootcomponent method while reading instance and all objects it owns.

If instance is a Nil,readcomponent method, the part is created based on the part type information described in the stream, and the newly created part is returned.

7. Readcomponentres method

Declaration: Function Readcomponentres (instance:tcomponent): tcomponent;

The Readcomponentres method reads the instance specified part from the stream, but the current position of the stream must be the position of the part written by the Writecomponentres method.

Readcomponentres first calls the Readresheader method to read the resource header from the stream and then calls the Readcomponent method to read the instance. If the current position of the stream does not contain a resource header. Readresheader will throw a Einvalidimage exception event. The Classes Library unit also contains a function named Readcomponentres that performs the same action, except that he establishes its own stream based on the resources that the application contains.

8. Readresheader method

Statement: procedure Readresheader;

The Readresheader method reads the Window System resource file header from the current position of the stream and moves the current position pointer of the stream to the end of the file header. If the stream does not contain a valid resource file header, Readresheader throws a Einvalidimage exception event.

The Readcomponentres method of the stream automatically calls the Readresheader method before it reads the part from the resource file, so the programmer usually does not have to call him himself.

9. Seek method

Statement: function Seek (offset:longint; Origin:word): Longint; Virtual Abstract

The Seek method moves the current pointer of the stream to offset bytes, and the beginning of the byte movement is specified by origin. If offset is a negative number, the Seek method moves from the described starting point toward the head of the stream. The different values of origin and their meanings are listed in the following table:

Table 20.1 values of the parameters of the function seek

━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━

Value of the starting offset of the constant value seek

─────────────────────────────────

Sofrombeginning 0 The beginning of the stream positive

Sofromcurrent current position of 1 stream positive or negative

Sofromend 2-stream ending negative number

━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━

Ten. Write method

There are two types of objects in Delphi Object-managed objects that have a method called write: The Stream object and the Filer object. The Write method of the Stream object writes the data into the stream. The Filer object passes the data through the associated stream, which is described later in this article.

The Write method of the stream object is declared as follows:
function Write (const Buffer; Count:longint): Longint; Virtual Abstract

The Write method writes count bytes in buffer to the stream and moves the current position pointer toward the end of the stream count bytes, and the function returns the number of bytes written.

The Write method of Tstream is abstract, and each inherited stream object is provided with a specific method to write data to a particular storage medium (memory, disk file, and so on) by overriding the method. All other methods of writing data (such as WriteBuffer, writecomponent) of the stream call write to assume the actual write operation.

One-WriteBuffer method

Statement: Procedure WriteBuffer (const Buffer; Count:longint);

WriteBuffer functions are similar to write. The WriteBuffer method calls write to perform the actual write operation, and if the stream does not write all the bytes, writebuffer triggers a Ewriteerror exception event.

Writecomponent method

Both the stream object and the Filer object have methods that are called writecomponent. The Writecomponent method of the Stream object writes instance the specified part and all the parts he contains to the stream, and the writecomponent of the writer object writes the property values of the specified part to the stream of the writer object.

The Writecomponent method declaration for the Stream object is this:

Procedure Writecomponent (instance:tcomponent);

Writecomponent creates a writer object and calls the writer's Writerootcomponent method to write instance and its own objects to the stream.

Writecomponentres method

Statement: writecomponentres (const resname:string; Instance:tcomponent);

The Writecomponentres method first writes the standard Windows System resource file header to the stream, and then writes the specified part of instance to the stream. To read a part written by Writecomponentres, you must call the Readcomponentres method.

Writecomponentres uses the Resname passed-in string as the resource name for the resource file header, and then calls the Writecomponent method to write the instance and the parts he owns to the stream.

Writedescendant method

Statement: Procedure Writedescendant (Instance ancestor:tcomponent);

The Writedescendant method of the Stream object creates a writer object and then moves the Writedescendant method of the object into the instance part to the stream. Instance can be a form that inherits from an ancestor part, or a part in a form that inherits from an ancestor form that corresponds to a ancestor part in an ancestor form.

Writedescendantres method

Statement: Procedure writedescendantres (const resname:string;

Instance, ancestor:tcomponent);

The Writedescendantres method writes the Windows System resource file header to the stream, uses the Resname action resource name, and then calls the Writedescendant method to write the instance to the stream.


The realization principle of 20.1.1.2 Tstream

The Tstream object is the underlying class of the stream object, which is the basis for the stream object. In order to store data objects on different mediums, the subsequent stream objects are mainly improved on the read and write methods. Therefore, understanding Tstream is at the heart of mastering the management of Stream objects. Although the Borland company provided the interface documentation for the stream object, but did not mention its implementation and application methods, the author has mastered streaming object technology from the source code and some example programs provided by Borland Delphi 2.0 Client/server Suite.

The following is the beginning of the implementation of Tstream's properties and methods.

1. Implementation of the Tstream property

As described earlier, Tstream has position and size two attributes, and as an abstract data type, he abstracts the domains that are frequently accessed to read and write data in various storage mediums. So how did they make it happen?

Read and write controls in the Part property definition are described in the chapter on custom part authoring. Position and size are also read and write controlled. Defined as follows:
 
Property Position:longint read GetPosition write setposition;
Property Size:longint read GetSize;

As can be seen, position is a read-write property, and size is readonly.

The implementation of the Position property is currently getposition and SetPosition. The private methods GetPosition and SetPosition are automatically triggered by all read position values and assignments to position when the program is running. The declarations of the two methods are as follows:

function TStream.GetPosition:Longint;

Begin
Result: = Seek (0, 1);
End

Procedure Tstream.setposition (Pos:longint);
Begin
Seek (Pos, 0);
End

When setting the location, the Delphi compilation mechanism automatically passes the position to Pos.

The use of seek is described earlier, the first parameter is the move offset, the second argument is the starting point of the move, and the return value is the position of the pointer after the move.
The implementation of the Size property is read-only, completely masking the write operation. The Read control method GetSize is implemented as follows:

function TStream.GetSize:Longint;
Var
Pos:longint;
Begin
Pos: = Seek (0, 1);
Result: = Seek (0, 2);
Seek (Pos, 0);
End


2. Implementation of the Tstream method
⑴copyfrom method
CopyFrom is a very useful method in stream objects that is used to copy data in different storage mediums. For example, memory and external files, between memory and database fields, and so on. He simplifies many of the details of memory allocation, file opening and reading, and unifies all copy operations on the stream object.

Previously described: The CopyFrom method takes the source and count two parameters and returns a long integer. This method copies the contents of count bytes from source to the current stream, and copies all data if the count value is 0.

function Tstream.copyfrom (source:tstream; Count:longint): Longint;
Const
Maxbufsize = $F 000;
Var
BufSize, N:integer;
Buffer:pchar;
Begin
If Count = 0 Then
Begin
Source.position: = 0;
Called when coung= "ZH-CN" > a part in a resource file, usually the programmer does not need to call itself. If the read is not a resource file Readresheader, an exception event is triggered.

Procedure Tstream.readresheader;
Var
Readcount:longint;
HEADER:ARRAY[0..79] of Char;
Begin
Fillchar (header, SizeOf (header), 0);
Readcount: = Read (header, SizeOf (header)-1);
if (Byte ((@Header [0]) ^) = $FF) and (Word (@Header [1]) ^) = ten) Then
Seek (StrLen (Header + 3) + 10-readcount, 1)
Else
Raise Einvalidimage.createres (Sinvalidimage);
End

Readcomponentres reads the part in the Windows System resource file, in order to determine whether it is a resource file, he first calls the Readresheader method and then calls the Readcomponent method to read the instance specified part. Here is his implementation:


function Tstream.readcomponentres (instance:tcomponent): tcomponent;

Begin
Readresheader;
Result: = Readcomponent (Instance);
End

and readcomponentres the corresponding write method is Writecomponentres,delphi call both methods read and write form files (DFM file), in the following book will be used in these two methods to read the DFM file example.

⑷writecomponent and Writedescendant methods

The Writedescendant method of the Stream object creates the Twriter object during implementation, and then writes instance to the stream using Twriter's Writedescendant method. The Writecomponent method simply invokes the Writedescendant method to write the instance to the stream. Their implementation is as follows:

Procedure Tstream.writecomponent (instance:tcomponent);
Begin
Writedescendent (Instance, nil);
End

Procedure Tstream.writedescendent (Instance, ancestor:tcomponent);
Var
Writer:twriter;
Begin
Writer: = Twriter.create (self, 4096);
Try
Writer.writedescendent (Instance, Ancestor);
Finally

Writer.free;
End
End

⑸writedescendantres and Writecomponentres methods

The Writedescendantres method is used to write the part to the Windows System resource file, whereas the Writecomponentres method simply calls the Writedescendantres method, and their implementation is as follows:


Procedure Tstream.writecomponentres (const resname:string; Instance:
Tcomponent);
Begin
Writedescendentres (Resname, Instance, nil);
End
 

Procedure Tstream.writedescendentres (const resname:string; Instance,
Ancestor:tcomponent);
Var
Headersize:integer;
Origin, Imagesize:longint;
HEADER:ARRAY[0..79] of Char;
Begin
Byte ((@Header [0]) ^): = $FF;

Word ((@Header [1]) ^): = 10;

Headersize: = StrLen (Strupper (Strplcopy (@Header [3], Resname, 63)) + 10;

Word ((@Header [HeaderSize-6]) ^): = $1030;

Longint ((@Header [HeaderSize-4]) ^): = 0;

WriteBuffer (Header, headersize);

Origin: = Position;

Writedescendent (Instance, Ancestor);

ImageSize: = Position-origin;

Position: = Origin-4;

WriteBuffer (ImageSize, SizeOf (Longint));

Position: = Origin + ImageSize;

End

 

Writecompnentres is the corresponding object writing method with Readcomponentres, these two methods cooperate with each other to read Delphi's DFM file, thus take advantage of the function of Delphi system.

20.1.2 Thandlestream Object

The Thandlestream object behaves particularly like a FileStream object, and the difference is that he stores the data in the stream through the file handle that was created instead of the filename.

The Thandlestream object defines the handle property, which provides read-only access to the file handle, and the handle property can be used as a parameter to the Delphi file management function of the file class function to read and write data. Thandlestream overrides the constructor create, which has a handle parameter that specifies the file handle associated with the Thandlestream object.

20.1.2.1 the properties of the Thandlestream:

1. Handle Properties

Statement: Property handle:integer;

The Handle property provides read-only access to a file handle, which is passed in by the constructor of the Thandlestream create method. Therefore, in addition to the method provided by Thandlestream, the handle can also be manipulated with the file management function. In fact, the thandlestream approach is also implemented using file management functions for actual read and write operations.

2. Create method

Statement: Constructor Create (Ahandle:integer);

The Create method creates a Thandlestream object that is associated with a specific file handle with the passed-in handle parameter, and assigns Ahandle to the handle property of the stream.

3. Read, write, and Seek methods

These three methods are the virtual methods of Tstream, and only three methods are covered in the Thandlestream to realize the data access of the specific media--file. The implementation of these three methods is described in detail later.

The realization principle of 20.1.2.2 Thandlestream

Thandlestream is inherited from Tstream, so it is possible to share attributes and most methods in Tstream. Thandlestream is mainly implemented by adding an attribute handle and covering the four methods of Create, Read, write and Seek.

1. Implementation of attributes

The implementation of the handle property, like the implementation of most properties of Delphi, declares a variable fhandle that holds the data in the ******* part of the object definition, and then declares the property handle in the public part of the definition, where the read-write control portion of the property definition is added with read-only control. Read control simply reads the value of the Fhandle variable, which is implemented as follows:

Thandlestream = Class (TStream)

*******

Fhandle:integer;

Public

...

Property Handle:integer read Fhandle;

End

 

2. Implementation of the method

Thandlestream Create method, with Ahandle as the parameter, in the method is simply to assign Ahandle value to Fhandle, its implementation is as follows:

Constructor Thandlestream.create (Ahandle:integer);

Begin

Fhandle: = Ahandle;

End

To implement data object storage for files, the read, write, and seek methods of Thandlestream overwrite the corresponding methods in Tstream. Their implementation invokes the file management function of the Windows system.

The Read method calls the Fileread function to implement the file read operation, which is implemented as follows:

function Thandlestream.read (var Buffer; Count:longint): Longint;

Begin

Result: = FileRead (Fhandle, Buffer, Count);

If result =-1 then Result: = 0;

End

The Write method calls the FileWrite function to implement the file write operation, which is implemented as follows:

function thandlestream.write (const Buffer; Count:longint): Longint;

Begin

Result: = FileWrite (Fhandle, Buffer, Count);

If result =-1 then Result: = 0;

End

The Seek method calls the FileSeek function to implement the movement of the file pointer, which is implemented as follows:

function Thandlestream.seek (offset:longint; Origin:word): Longint;

Begin

Result: = FileSeek (Fhandle, Offset, Origin);

End

20.1.3 TFileStream Object

The TFileStream object is a stream object that stores data on a disk file. TFileStream is inherited from the Thandlestream, he and Thandlestream are the same is the implementation of file access operations. The difference is that Thandlestream accesses the file with a handle, and TFileStream accesses it with a file name. In fact, TFileStream is a layer of packaging on Thandlestream, whose kernel is Thandlestream properties and methods.

New properties and methods are not added in TFileStream. He just covered the construction method of Create and destructor method Destory. In the Create method, take two parameters, filename, and mode. FileName describes the name of the file to be created or opened, while mode describes the file schema such as Fmcreate, Fmopenread, and Fmopenwrite. The Create method first creates or opens a file named filename with the Filecreate or FileOpen function, and assigns the resulting file handle to Fhandle. TFileStream file read and write operations are inherited from the Thandlestream read

Var

Stream:tstream;

Begin

Stream: = Tfilestream.create (FileName, fmcreate);

Try

Savetostream (Stream);

Finally

Stream.free;

End

End

The Savetostream of many objects in Delphi and the implementations of SaveToFile, Loadfromstream, and LoadFromFile methods have similar nesting structures.

20.1.5 Tmemorystream Object

The Tmemorystream object is a stream object that manages data in dynamic memory, inherited from Tcustommemorystream, except for attributes and methods inherited from Tcustommemorystream. He also added and covered some methods for reading data from disk files and other note-sets. He also provides a dynamic memory management method for writing and eliminating memory content. Here are some of his properties and methods.

Properties and methods of 20.1.5.1 Tmemorystream

1. Capacity Properties

Statement: Property copacity:longint;

The capacity property determines the size of the memory pool allocated to the memory stream. This is somewhat different from the Size property. The Size property is a description of the amount of data in the stream. The ability to set the value of capacity in a program is larger than the maximum memory required for the data, which avoids frequent redistribution.

2. ReAlloc method

Statement: function Realloc (var newcapacity:longint): Pointer; Virtual

The ReAlloc method allocates dynamic memory in 8K, and the size of the memory is specified by newcapacity, and the function returns a pointer to the allocated memory.

3. SetSize method

The SetSize method removes the data that is contained in the memory stream and sets the size of the memory pool in the memory stream to a sized byte. If size is zero, the SetSize method frees the existing memory pool and resets the memory property to nil, otherwise the SetSize method resizes the pool size to size.

4. Clear method

Statement: procedure Clear;

The clear method frees the in-memory pool and resets the memory property to nil. After the clear method is called, both the size and position properties are 0.

5. Loadfromstream method

Statement: Procedure Loadfromstream (Stream:tstream);

The Loadfromstream method copies the entire contents of the stream specified by the stream into MemoryStream, which replaces the existing content and makes MemoryStream a copy of the stream.

6. LoadFromFile method

Statement: Procedure LoadFromFile (count filename:string);

The LoadFromFile method copies all the contents of the filename specified file to MemoryStream and supersedes the existing content. When the LoadFromFile method is called, MemoryStream becomes the full copy of the file contents in memory.

The implementation principle of 20.1.5.2 Tmemorystream object

Tmemorystream inherit directly from the Tcustommemorystream object, so you can enjoy the properties and methods of the Tcustommemorystream. As mentioned earlier, Tcustommemorystream is an abstract object for data manipulation in memory, and he provides a framework for the implementation of the MemoryStream object, and the contents of the framework are populated by specific MemoryStream objects. The Tmemorystream object is to populate the framework with the needs of dynamic memory management. The implementation of the Tmemorystream object is described below.

1. Implementation of the Tmemorystream property

Tmemorystream adds a capacity property in its protected section that determines the size of the dynamic memory that the MemoryStream occupies. Tmemorystream first declares the fcapacity variable as the data field that stores the value of the capacity property in the ******* section, and then declares the property in the protected section. In the Read control section of the property declaration, the fcapacity value is simply read, and the method setcapacity is called at write control. In addition to assigning values to Fcapacity, the method performs the necessary actions such as state changes to modify the capacity property.

Here is the implementation of the property:

Tmemorystream = Class (Tcustommemorystream)

*******

Fcapacity:longint;

Procedure setcapacity (Newcapacity:longint);

Protected

...

Property Capacity:longint read Fcapacity write setcapacity;

Public

...

End

 

The implementation of the Write control method setcapacity is this:

 

Procedure tmemorystream.setcapacity (Newcapacity:longint);

Begin

Setpointer (Realloc (newcapacity), fsize);

Fcapacity: = newcapacity;

End

The Setcapacity method first calls ReAlloc to reallocate memory, and then assigns a value to fcapacity with the value of newcapacity. The ReAlloc method makes some changes to the state of the object.

2. Implementation of the Tmemorystream object method

⑴realloc method

The ReAlloc method is the core of tmemorystream dynamic memory allocation, and his setsize, setcapacity and other methods are finally called REALLOC for memory allocation and initialization. His implementation is as follows:

Const

Memorydelta = $2000;

 

function Tmemorystream.realloc (var newcapacity:longint): Pointer;

Begin

If newcapacity > 0 Then

Newcapacity: = (newcapacity + (MemoryDelta-1)) and not (MemoryDelta-1);

Result: = Memory;

If newcapacity <> fcapacity Then

Begin

If newcapacity = 0 Then

Begin

Globalfreeptr (Memory);

Result: = nil;

End Else

Begin

If capacity = 0 Then

Result: = Globalallocptr (Heapallocflags, newcapacity)

Else

Result: = Globalreallocptr (Memory, newcapacity, heapallocflags);

If Result = Nil then raise Estreamerror.createres (Smemorystreamerror);

End

End

End

The ReAlloc method is to allocate dynamic memory in 8K, and the first sentence in the method is the if statement to perform the operation. If the value of the passed-in newcapacity parameter is 0, the memory in the stream is freed. The ReAlloc method frees memory with the global freeptr function, allocates memory with GLOBALALLOCPTR, and allocates memory with GLOBALREALLOCPTR. If the original capacity property value is 0, call globa| Allocptr otherwise calls Globalreallocptr. Finally, if result is nil, a memory stream error event is triggered, otherwise a pointer to the allocated memory is returned.

⑵write method

The Write method writes binary data from the current position of the internal buffer pool of the memory stream. The implementation is as follows:

function tmemorystream.write (const Buffer; Count:longint): Longint;

Var

Pos:longint;

Begin

if (fposition >= 0) and (Count >= 0) Then

Begin

Pos: = Fposition + Count;

If Pos > 0 Then

Begin

If Pos > Fsize Then

Begin

If Pos > Fcapacity Then

Setcapacity (Pos);

Fsize: = Pos;

End

System.move (Buffer, Pointer (Longint (fmemory) + fposition) ^, Count);

Fposition: = Pos;

Result: = Count;

Exit;

End

End

Result: = 0;

End

The binary data to write to the stream is stored in buffer, and if the bytes of data to be written exceed the size of the flow's memory pool, the Setcapacity method is called to allocate memory, and then the data in buffer is copied to the fmemory using the memory copy function. It then moves the position pointer and returns the number of bytes written to the data. Analysis of this program can be known that the value of fcapacity and fsize values are different.

⑶clear method

The clear method eliminates data in the memory stream, sets the memories property to nil, and sets the value of Fsize and fposition to 0. The implementation is as follows:

Procedure Tmemorystream.clear;

Begin

Setcapacity (0);

Fsize: = 0;

Fposition: = 0;

End

⑷loadfromstream and LoadFromFile methods

The Loadfromstream method first re-allocates dynamic memory based on the value of the passed stream's size property, and then calls the stream's Readbuffer method to copy the data into fmemory, resulting in a full copy of the stream's contents in memory. The implementation is as follows:

Procedure Tmemorystream.loadfromstream (Stream:tstream);

Var
Count:longint;

Begin
Stream.position: = 0;
Count: = stream.size;
SetSize (Count);
If Count <> 0 then Stream.readbuffer (fmemory^, Count);
End

The syntax of the flow operation of Delphi

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.