IT SOLUTIONS
Your full service technology partner! 
-Collapse +Expand
Prism
Search Prism Group:

Advanced
-Collapse +Expand Prism To/From
To/FromCODEGuides
-Collapse +Expand Prism Study Test
PRESTWOODCERTIFIED
-Collapse +Expand Prism Store
PRESTWOODSTORE

Prestwood eMagazine

December Edition
Subscribe now! It's Free!
Enter your email:

   ► KB ►► ProgrammingDelphi Prism   Print This    All Groups  

Delphi Prism New and Updated KB Posts

Page Contents


Recently Created

(Delphi Prism Group)

  KB Article    

Mike Prestwood
1. Delphi Prism Member Events (event)

Like all .Net languages, Prism events are a separate type of class member. You define a member event by using the event keyword. Events depend on Delegates to define the signature (the type) of the event they represent and they maintain a list of multiple subscribers - unlike in Delphi for Win32, where each event can only have one handler

Posted to KB Topic: Delphi Prism
15 years ago

Code
Nothing New Since Your Last Visit
10107
Hits

Mike Prestwood
2. Delphi Prism Event Handler

The Delphi Prism

Most notable for Delphi developers is the fact that Prism does not offer initialization nor finalization sections.

Posted to KB Topic: Delphi Prism
15 years ago

Code
Nothing New Since Your Last Visit
13237
Hits

Mike Prestwood
3. Delphi Prism Empty String Check (length)

In Prism, a string can be nil (unassigned), assigned an empty string (""), or assigned a value.  Therefore, to check if a string is empty, you have to check against both nil and (""). Alternatively, you can check the length of the string or use String.IsNullOrEmpty.

Posted to KB Topic: Delphi Prism
15 years ago

Code

KB Post
Nothing New Since Your Last Visit
18580
Hits

Mike Prestwood
4. Delphi Prism Polymorphism

Prism supports the following types of polymorphism:

Posted to KB Topic: OOP
15 years ago, and updated 15 years ago
(1 Comments , last by mtiede )

Code
Nothing New Since Your Last Visit
11444
Hits

Mike Prestwood
5. Delphi Prism Pointers

Although pointer data types in Prism coding are less important than in other languages such as C++, Prism does support developer defined pointers. Use the ^ operator to declare a pointer data type. Use the @ operator to return the current address of a variable.

In .Net managed coding the use of pointers is not safe because the garbage collector may move memory around. To safely use pointers, use the unsafe keyword. However, avoid unsafe code if possible.

Posted to KB Topic: Language Details
15 years ago
(2 Comments , last by Robert.V2 )

Code
Nothing New Since Your Last Visit
13512
Hits

Mike Prestwood
6. Delphi Prism Overriding (virtual, override)

Same as Delphi. In Prism, you specify a virtual method with the virtual keyword in a parent class and replace it in a descendant class using the override keyword. Call Inherited in the descendant method to execute the code in the parent method.

Posted to KB Topic: OOP
15 years ago

Code

Article
Nothing New Since Your Last Visit
17367
Hits

Mike Prestwood
7. Delphi Prism Self Keyword (Self)

Within the implementation of a method, the identifier Self references the object in which the method is called. The Self variable is an implicit parameter for each object method.
A method can use this variable to refer to its owning class.

Posted to KB Topic: Language Details
15 years ago
(1 Comments , last by Margie.J )

Definition
Nothing New Since Your Last Visit
9718
Hits

Mike Prestwood
8. Oxidizer

Oxidizer is a free tool that (in combination with ShineOn) is provided to help to port Delphi (Win32 and .NET) projects to the Delphi Prism language. Oxidizer is a command line tool that will adjust your .pas source files for common differences between the two languages.

Posted to KB Topic: Tool Basics
15 years ago

Download
Nothing New Since Your Last Visit
14056
Hits

Mike Prestwood
9. ShineOn

A Delphi Prism implementation of the Delphi for Win32 RTL.

Posted to KB Topic: Tool Basics
15 years ago

Download
Nothing New Since Your Last Visit
12186
Hits

Mike Prestwood
10. Share Code with Delphi and Prism

Can I share code between a Delphi and a Dephi Prism project? I want to have a single source Win32 and .Net application.

Posted to KB Topic: Tool Basics
15 years ago
(2 Comments , last by mprestwood )

FAQ

KB Post
Nothing New Since Your Last Visit
15714
Hits




Recently Updated

(Delphi Prism Group)

  KB Article    

Mike Prestwood
1. Delphi Prism Member Property (property..read..write)

Like Delphi, Delphi Prism uses a special property keyword to both get and set the values of properties. The read and write keywords are used to get and set the value of the property directly or through an accessor method. For a read-only property, leave out the write portion of the declaration.

You can give properties any visibility you wish (private, protected, etc). It is common in Delphi and Delphi Prism to start member fields with "F" ("FName" in our example) and drop the "F" with properties that manage member fields ("Name" in our example).

Posted to KB Topic: OOP
16 years ago, and updated 14 years ago
(2 Comments , last by mprestwood )

Code
Nothing New Since Your Last Visit
13013
Hits

Mike Prestwood
2. Delphi Prism Member Events (event)

Like all .Net languages, Prism events are a separate type of class member. You define a member event by using the event keyword. Events depend on Delegates to define the signature (the type) of the event they represent and they maintain a list of multiple subscribers - unlike in Delphi for Win32, where each event can only have one handler

Posted to KB Topic: Delphi Prism
15 years ago

Code
Nothing New Since Your Last Visit
10107
Hits

Mike Prestwood
3. Delphi Prism Event Handler

The Delphi Prism

Most notable for Delphi developers is the fact that Prism does not offer initialization nor finalization sections.

Posted to KB Topic: Delphi Prism
15 years ago

Code
Nothing New Since Your Last Visit
13237
Hits

Mike Prestwood
4. Delphi Prism Empty String Check (length)

In Prism, a string can be nil (unassigned), assigned an empty string (""), or assigned a value.  Therefore, to check if a string is empty, you have to check against both nil and (""). Alternatively, you can check the length of the string or use String.IsNullOrEmpty.

Posted to KB Topic: Delphi Prism
15 years ago

Code

KB Post
Nothing New Since Your Last Visit
18580
Hits

Mike Prestwood
5. Delphi Prism String Concatenation (+)

Unlike Delphi, Prism performs implicit casting. To concatenate two strings, a string to an integer, or a string to a floating point number, use the + operator. For example, to convert a floating point number to a string just concatenate an empty string to the number as in "" + 3.2.

Posted to KB Topic: Language Basics
15 years ago, and updated 15 years ago
(3 Comments , last by mtiede )

Code

KB Post
Nothing New Since Your Last Visit
17625
Hits

Mike Prestwood
6. Delphi Prism Finalizer (finalize())

Unlike Delphi, Delphi Prism uses the .Net garbage collector to free managed object instances. Prism does not have nor need a true destructor.

In .Net, a finalizer is used to free non-managed objects such as a file or network resource. Because you don't know when the garbage collector will call your finalizer, Microsoft recommends you implement the IDisposable interface for non-managed resources and call it's Dispose() method at the appropriate time.

Posted to KB Topic: OOP
15 years ago, and updated 15 years ago

Code

Article
Nothing New Since Your Last Visit  
23198
Hits

Mike Prestwood
7. Delphi Prism Member Field

In Prism you can set the visibility of a member field to any visibility: private, protected, public, assembly and protected or assembly or protected. Prism supports the readonly modifier for member fields which is handy for constant like data. In this case, I chose not to preface my read-only member field with "F" so it's usage is just like a read-only property. Prism also support the class modifier (static data) for member fields. Delphi developers should notice the use of := to initialize a member field (in Delphi you use an =).

Posted to KB Topic: OOP
16 years ago, and updated 15 years ago
(1 Comments , last by mtiede )

Code

Article
Nothing New Since Your Last Visit
15881
Hits

Mike Prestwood
8. Delphi Prism Code Blocks (begin..end)

Same as in Delphi for Win32 but Prism also supports inline variable declaration.

Posted to KB Topic: Language Basics
16 years ago, and updated 15 years ago
(2 Comments , last by mprestwood )

Code

KB Post
Nothing New Since Your Last Visit
15936
Hits

Mike Prestwood
9. Delphi Prism Class Member Visibility Levels

In Prism, you specify each class and each class member's visibility with a Class Member Visibility Level preceding the return type. Like Delphi, you group member declarations as part of defining the interface for a class in the Interface section of a unit.

Unlike Delphi, Prism supports a traditional OO approach to member visibility with additional .Net type assembly visibility. For example, private members are truly private to the class they are declared in. In Delphi for Win32, you use strict private for true traditional private visibility.

Prism also supports assembly and protected and assembly or protected which modify the visibility of protected members to include only descendants in the same assembly (and) or publicly accessible from assembly and descendant only outside (or). OO purist might object to assembly and protected and assembly or protected and I suggest you choose the traditional private, protected, and public as your first chose at least until you both fully understand them and have a specific need for them.

Posted to KB Topic: OOP
16 years ago, and updated 15 years ago
(4 Comments , last by mprestwood )

Code
Nothing New Since Your Last Visit  
19861
Hits

Mike Prestwood
10. Delphi Prism Polymorphism

Prism supports the following types of polymorphism:

Posted to KB Topic: OOP
15 years ago, and updated 15 years ago
(1 Comments , last by mtiede )

Code
Nothing New Since Your Last Visit
11444
Hits
Icon Legend:
Since your last logged visit:
- New to you or updated since your last visit (sign in now to activate).
- NOT new to you since your last visit (sign in now to activate).
Go ahead!   Use Us! Call: 916-726-5675  Or visit our new sales site: 
www.prestwood.com


©1995-2024 Prestwood IT Solutions.   [Security & Privacy]