!
ԣిˢ͘ܝΊ
Delphi 8 for .NET
!
COPYRIGHT © 1984, 2004 Borland Software Corporation. үᝋᛳ Borland ̳ΦٙѣĎᖙᄦυտĄ ٙѣ Inprise Borland ۞யݡЩჍ࠰ߏ Borland Software Corporation.̝થᇾٕොΊથᇾĄ ώ३͔ٙ̚ϡι̳ΦயݡЩჍĎથᇾᛳ̳ྍٺΦٙѣ。 ώ͘Ίܼдέ៉Оᄦ !
ϫᐂ! ϫ ᐂ ܧෛᛇ̼̮І̮Іሹ ..........................4-4 ̍ሹĞTool Paletteğ................................4-5 ҋᄦ۞̮І ..............................................4-5 ̮Іᇹ ۍ..................................................4-5 ۏІᑭෛጡĞObject Inspectorğ ................4-5 ۏІᚗऱĞObject Repositoryğ .................4-6 ۏІᚗऱ̰ొ ..........................................4-6 ۏІᚗऱᇹ ۍ..........................................4-7 ९გநࣶĞProject Managerğ ................4-7 ΐˢણ (Reference) ............................4-7 ણኑᄦזώгྮश ..........................4-7 ΐˢ Web ણ ........................................4-8 Data Explorer ................................................4-8 ёቅበᏭጡĞCode Editorğ ...................4-8
ௐ1ౢ
ԣిˢܝ
1-1
ௐ2ౢ
̦ᆃߏ Delphi for .NETĉ
2-1
ؠཌྷᅮՐ.........................................................2-1 ሀᑕϡё.................................................2-2 నࢍֹϡ۰̬ࢬ.............................................2-2 யϠᄃበᏭёቅ.........................................2-2 በᛌĂੵĂᄃొཌᑕϡё.....................2-2 ଠטх̈́פᖸёቅ۞តՀ.....................2-3 .NET Framework ..........................................2-3
ௐ3ౢ Delphi 8 for .NET ۞າপّ
ௐ5ౢ ฟؕາ۞९
3-1
IDE ..................................................................3-1 ሀ.................................................................3-2 ASP .NET Web ฟ൴ .....................................3-3 ྤफ़ऱฟ൴.....................................................3-4 Visual Component Library (VCL) for .NET 3-4 Delphi ᄬ֏੫၆.NET ۞ΐૻ......................3-5 ёቅଠ۞טፋЪ.........................................3-5 ࢦາనࢍ۞۞ᅃӄᄲځր.........................3-6
ௐ4ౢ IDE ̝ॠ
5-1
९۞ݭၗ.....................................................5-2 ෛᑕϡё ..........................................5-2 ASP .NET Web ᑕϡё ......................5-2 ASP .NET Web Services ᑕϡё.......5-2 VCL .NET ᑕϡё...............................5-3 ྤफ़ऱᑕϡё ......................................5-3 ͽሀݭᜭજ۞ᑕϡё ..........................5-4 Assemblies ..............................................5-5 ᗝγ۞९.....................................................5-5 Ϗৼˢგந۞ёቅᄃ COM/Interop.......5-5
4-1
ᝌࢬࢱܓĞWelcome Pageğ.......................4-2 ܑॾĞFormsğ..............................................4-2 ෛܑॾ ..................................................4-3 ASP .NET Web ܑॾ ..............................4-3 VCL ܑॾ .................................................4-3 HTML Designer .....................................4-4 Designer Surface...........................................4-4 ෛᛇ̼̮І ..............................................4-4
ௐ6ౢ
ёቅበᏭጡ
6-1
எˢёቅĞCode Insightğ ......................6-2 ᙷҾԆјĞClass Completionğ..................6-2 ёቅᕱᜓ.....................................................6-2 ёቅͯ߱ĞCode Snippetsğ ...................6-3 ёቅԶᝑĞCode Foldingğ.....................6-3 ޞநಏĞTo-Do Listsğ ........................6-4
i
ᔣᑝ۞λะĞKeystroke Macrosğ .............6-4
ણ҂ᗟ ..................................................7-2 Context Sensitive ۞ F1 ᅃӄᄲ ځ........7-3 Microsoft .NET Framework SDK ᅃӄᄲځ.7-3 Borland ฟ൴۰͚೯ڇચ̈́შ৭..................7-3 Delphi 8 for .NET ԣిˢ͔ܝ.................7-4 ᅃӄᄲ۞ځଵۍၚּ.....................................7-4
ௐ7ౢ
ᅃӄᄲੈྤ۞ځ
7-1
ࢦາనࢍ۞ Delphi 8 for .NET ᅃӄᄲځ....7-1 ໄ۞هტ៍ ..............................................7-2 Ԕ۞͔ ..............................................7-2
ii
ԣిˢܝ Delphi 8 for .NET ፋЪّ൴णᒖဩ (IDE) ೩ֻధк̍পّĂםӄଋԣ ిгޙϲૻѣ˧۞.NET ᑕϡёĄ֭ܧٙѣ۞পّౌ̍Βӣд Delphi 8 for .NET ۞ٙѣۍώ̚Ąࠎᒢྋଋֹϡ۞ۍώΒӣֱࣹপّ̍Ăኛણ ҂ http://www.borland.com/delphi_net ۞পّܑĄ ώˢ̰۞ܝटΒ߁Ĉ y
̦ᆃߏ Delphi for .NETĉ ೩ֻயݡໄ៍Ă֭ೡ Delphi 8 for .NET ϡֽგநёฟ൴Ϡฉഇ۞ ̍Ą
y
ѣ̦ᆃາ۞পّĉ ̬ώயֱ˘ݡາ۞পّΑਕĄ
y
IDE ̝ॠ ೡ IDE ۞ЧีࢋІĄ
y
ฟؕາ۞९
ԣిˢܝ
1-1
ೡ९۞Чొ̶Ă֭Еᓝ Delphi 8 for .NET ͚ٙ೯۞९ᙷݭĄ y
ᅃӄᄲ࠹۞ځᙯྤੈ ྋᛖቢ˯ᅃӄᄲ̰ੈྤ۞̚ځटĂ֭Еᓝ۞ણ҂ྤ೩ֻගёฟ ൴۰Ą
1-2
Delphi ԣిˢ͘ܝΊ
̦ᆃߏ Delphi for .NETĉ Delphi 8 for .NET ߏ ˘ ࣎ ፋ Ъ ّ ൴ ण ᒖ ဩ (IDE) Ă ϡ ֽ ޙϲ ે Җ ٺ Microsoft .NET ᒖဩ۞ Delphi ᑕϡёĄDelphi 8 for .NET IDE ೩ֻ˘ ̙ٙΒ۞̍Ăϡͽᖎ̼֭ΐిฟ൴ᑕϡё۞ϠฉഇĄIDE ̚Ξϡ۞ ̍ෛଋֹϡ۞ Delphi 8 for .NET ۍώ҃ؠĄତ˭ֽЧ༼ᖎൺֱ̬ ̍Ĉ
ؠཌྷᅮՐ Delphi 8 for .NET೩ֻ˘࣎CaliberRM۞̬ࢬĂߏ˘࣎Web-based۞ᅮՐ ؠཌྷ̈́გநրĂϡֽםӄଋଠטய۞ݡ൴ण࿅ĄдIDE྆ĂଋΞͽхפ CaliberRMͽТॡந९ᅮՐĂ֭ቁܲଋ۞ᑕϡёЪֹϡ۰(end-user) ۞ᅮࢋĄ
̦ᆃߏ Delphi for .NETĉ
2-1
ሀᑕϡё ሀ (modeling) ߏдฟؕᇤᆷёቅ̝݈АޙϲྎႽ۞ෛᛇ̼నࢍĂͽם ӄଋᆧซᑕϡё۞ड़ਕăड़தăͽ̈́Ξჯ᜕ّĄDelphi for .NET ೩ֻͽ UML ࠎૄᖂ۞ᙷҾᄦဦ(class diagramming)̍Ăͽ̈́˘࣎ Enterprise Core Objects (ECO) ۞॰ߛĂםӄଋޙϲणனሀݭજ˧۞.NET ᑕϡёĄ
నࢍֹϡ۰̬ࢬ Delphi 8 for .NET ෛᛇ̼۞ designer surfaceĂឰଋ̍ሹ (Tool Palette) ˯۞̮ІٳѢ˯ॾܑזĂͽޙϲဦԛ̼۞ֹϡ۰̬ࢬĄֹϡֱ designersĂ ଋΞͽޙϲෛܑॾ (Windows Form)ăWeb ܑॾăVCL ܑॾă HTML შࢱĄ
யϠᄃበᏭёቅ Delphi 8 for .NETдଋฟؕฟ൴९ॡĂಶࠎଋҋજயϠధкёቅĄࠎ˞ םӄଋԣిгԆј۞ᑕϡёទᏭĂͽ͛фࠎૄᖂ۞ёቅበᏭጡ (Code Editor) ೩ֻ۞পّѣёቅ۞ԆјăΞࢦኑֹϡ۞ёቅͯ߱ăᐂ ᄦ۞ᔣᑝλะ (keystroke macros)ăͽ̈́ҋࢎ۞ᔣሹ၆ᑕĄᄬڱΎព (syntax highlighting) ̈́ёቅԶᝑ (code folding) ឰଋ۞ёቅՀٺٽዦፆ үĄ
በᛌĂੵĂᄃొཌᑕϡё д IDE ྆ĂଋΞͽనؠበᛌጡᏴีăበᛌ֭ેҖଋ۞ᑕϡёăͽ̈́ᑭෛበ ᛌጡ۞ੈिĄ̏ፋЪซֽ۞ੵጡĂឰଋԱ࣒֭זϒેҖഇมទᏭ˯۞ ᄱăଠטё۞ેҖăͽ̈́ుՎซˢёቅมᑭෛតᇴ࣒֭Լྤफ़ࣃĄ.NET Framework Β ӣ ధ к ̳ ϡ ё םӄ ଋ ౯ ᑕ ϡ ё ۞ ొ ཌ Ą Delphi 8 for .NET ۞ InstallShield Express ϡֽޙϲ Windows Installer ۞నؠĄ
2-2
Delphi ԣిˢ͘ܝΊ
ଠטх̈́פᖸёቅ۞តՀ ёቅଠטր(source control system)ĂᖣϤଠטх̈́פᖸёቅ ᑫ९۞តՀĂֽܳјဥฤฟ൴ĄDelphi 8 for .NET Ӏϡ Microsoft Common Source Code Control API (SCC API) ೩ֻ˘࣎В఼۞̬ࢬග StarTeamă CVSăClearCase Visual SourceSafeĄд Delphi 8 for .NET ۞ IDE ྆Ăଋ Ξͽઇ˘ਠ۞ࣧؕቅଠ̍טүĂּтᑫ९൳ˢă൳ă̈́ТՎ̼Ą
.NET Framework Microsoft .NET Framework ೩ֻ˞ޙၹેҖ.NET ᑕϡё۞ૄᖂĄѩ॰ ߛΒ߁ common language runtime ᙷҾऱ (class library)ĄCommon language runtime გநёቅ۞ેҖ֭೩ֻڇચĂּтጸវგநྭё ᄬ֏۞ፋЪĂͽᖎ̼ฟ൴۞࿅ĄᙷҾऱΒ߁Ξࢦኑֹϡ۞ۏІጱШ̮ІĂ ϡֽ൴णӀϡ common language runtime ڇચр۞.NET ᑕϡёĄ Delphi 8 for .NET ۞ IDE ֹϡፋ࣎॰ߛ۞ᙷҾऱĂͽםӄଋ൴ण.NET ᑕϡ ёĄDelphi 8 for .NET дͽ˭ೀ࣎͞ࢬΐૻ˞॰ߛĈ y
Delphi 8 for .NET ۞ Borland Data Providers for .NET ೩ֻ InterBaseă OracleăDB2 Universalăͽ̈́ Microsoft SQL Server ඈྤफ़ऱ۞хפĄ
y
ధкྤफ़ऱ̳ϡё೩ֻд೩̿ड़ਕ˯۞םӄĂтాඕྤफ़ऱăᕱᜓ በᏭྤफ़ऱăͽ̈́ેҖ SQL ߤྙĄ
y
.NET Menu Designers ᖎ̼˞ෛܑॾ˯Ᏼಏ̰टᏴಏ۞ޙϲĄ
̦ᆃߏ Delphi for .NETĉ
2-3
2-4
Delphi ԣిˢ͘ܝΊ
Delphi 8 for .NET ۞າপّ Delphi 8 for .NET ೩ֻ̂ณ۞າপّϡֽ൴ण.NET ᑕϡёĄତ˭ֽೀ༼ পҾᄲځᄃ Delphi ̝݈ۍώ̙Т۞পّĄ
IDE y
IDE ѣ˘࣎າ۞γ៍ĂΒӣ˘࣎న۞ઃዸෛ(ࢬۍdocked window layout)࣎˘న۞ੵ(ࢬۍdebug layout)ĄΩγĂଋΞͽֹϡ็۞ Ϗઃዸ(ࢬۍundocked layout)Ăٕᐼхଋҋࢎ۞ࢬۍనؠĄ
y
д IDE ϒ̚δ۞ᝌ( ࢬࢱܓWelcome page)Ăѣ˘ЊܑಏЕଋܕх ۞פ९Ă֭೩ֻధкฟ൴۰შ৭۞ాඕĄ
y
९გநࣶ (Project Manager)ăາ۞ Model Viewăͽ̈́ΐૻ࿅۞ Data ExplorerĂౌညॾਠಷдځព۞г͞ͽֻԣిхפĄ
Delphi 8 for .NET ۞າপّ
3-1
y
̮Іሹ (Component Palette) ̏གྷజ IDE Π˭֎˘࣎Ξຩವ҃ͷΞҋࢎ ۞̍ሹ (Tool Palette) ٙפĄ̍ሹౘЕ۞̮Іߏॲፂ IDE ྆ϫ݈ ฟୁ۞ᑕϡёᙷݭĂᙷҾܑ҃ЕĄΠᑝ̍ሹពϯధкΞҋࢎ ۞ᏴีĄ
y
˘ֱ̮ІΒӣ component designersĂ೩ֻᗝγ۞నࢍॡഇΑਕĄ̂ొ̶ ۞ component designers ΞͽଂۏІᑭෛጡ (Object Inspector) ۞ొغ designer verb ડાхפĄ
y
ۏІᑭෛጡົពϯٙᏴפ.NET ॰ߛ̮Іᛳّ۞ᖎൺᄲځĄ
y
၆ Web ܑॾෛܑॾ҃֏Ăܧෛᛇ̼۞̮Іт̫ពϯд designer غ ొ۞̮І (component tray)Ă̙҃ߏܑॾ˯Ą
y
ёቅበᏭጡ۞ёቅͯ߱ (Code Snippets) ឰଋᐼхࢦኑֹϡ૱ϡ ۞ёቅ߱རĄ
y
ёቅበᏭጡ۞ёቅԶᝑ (Code Folding) ឰଋԶᝑणฟёቅડ ĂͽᆧซΞّፆүĄ
y
ҖᇴனдΞͽពϯдёቅበᏭጡ۞νቡĄ
y
Бા۞ IDE న̏ؠགྷඕЪֹٺٽ࣎˘זϡ۞ treeview ၆ྖĂϡ Tools -> Options Ᏼಏ΄ΞͽԯιΨֽĄ
y
ଂ Tools -> Reflection х ۞ פBorland Reflection ̍ Ă Ξ ឰ ଋ ၅ ࠻.NET assembly metadataĄ
ሀ y
Delphi 8 for .NET ̰ӣ̍Ăϡֽฟ൴णனሀજ˧۞.NET ෛܑॾᑕ ϡёĄ
y
Enterprise Core Object (ECO) ॰ߛ၁ү˞ UML 1.4 ۞ۍMetamodelĂ ֹ֭.NET ॰ߛдనࢍഇมેҖഇมౌΞͽֹϡሀ( ݭmodel)Ą
3-2
Delphi ԣిˢ͘ܝΊ
y
ፋЪ۞ UML ᄦဦ̍םӄଋޙϲ UML इІ(package)ăᙷҾăᙷҾม ۞ాඕ(link)ᙯܼ(association)ăဦܑᄲ(ځnote)Ăͽ̈́ՀкĄ
y
Model View ෛឰଋॲፂᙷҾёቅ̮྆৵̝ม۞ទᏭᙯܼፆ ଠଋ۞९Ą
y
UML ሀݭΞͽϡ XML Metadata Interchange (XMI) ۞ॾё๗ˢ̈́๗ Ą
ASP .NET Web ฟ൴ y
Delphi 8 for .NET ͚೯ ASP .NET ёሀݭĄ
y
ధкྤफ़ຏᑕ۞(data-aware)ྤफ़ऱ web ଠ̮טІĂᖎ̼˞ͽྤफ़ᜭજ ۞ ASP .NET web ᑕϡё۞ฟ൴Ą
y
Web ܑॾ۞ designer ೩ֻԆፋ۞ WYSIWYG HTML በᏭĂ ̚HTML ჯ ᜕ д ˘ ࣎ ϲ ۞ .aspx ᑫ ྆ Ă ҃ ଋ ۞ Delphi ё ቅ ߏ ჯ ᜕ д ˘ ࣎.pas ᑫ྆Ą
y
༊ޙϲ˘࣎ ASP .NET ᑕϡёॡĂNew ASP .NET Application ၆ྖ ឰଋ ؠweb Ҩڇጡన۞хטࢨפĂޢҋજޙϲᑢϫᐂ(virtual directory)Ă֭ࠎଋ۞ᑕϡёనؠхפᝋࢨĄ
y
ેҖ ASP .NET ᑕϡёॡĂົҋજពϯд˘࣎ web ᕱᜓጡ྆Ăឰଋд IDE ྆ಶΞͽүീྏĄ
y
Web ܑॾ designer ۞ొغHTML Tag Editor ឰଋд࠻ HTML ۞ဦԛܑ ன۞ТॡĂ˵ਕበᏭιĄ
y
HTML Tidy Ξϡֽд IDE ྆ԯ HTML ЕО۞႓႓۞ܪܪĄ
y
೩ֻޙϲ SOAP Server ᑕϡё۞͞( ڱmethod)Ăᖎ̼˞ Web Services ۞ฟ൴Ą
Delphi 8 for .NET ۞າপّ
3-3
y
ଋΞͽд IDE ྆ീྏ Web ServiceĂ̙҃υᇤᆷ˘࣎͗މბᑕϡёү ീྏĄ
y
UDDI Brower ΞͽԱ࣎˘זೡ Web Service ۞ WSDLĂ֭๗ˢזଋ۞ ͗މბᑕϡё྆Ą
ྤफ़ऱฟ൴ y
Delphi 8 for .NET ͚೯ ADO .NET ёሀݭĄ
y
Borland Data Providers (BDP) for ADO.NET ೩ֹֻϡ Web ܑॾăWeb Services ෛܑॾᑕϡёх פInterBaseăOracleăDB2 Universală Microsoft SQL Serverăͽ̈́ Microsoft Access database ඈྤफ़ऱĄ
y
BDP.NET ̮І designers ͞ܮฟ൴۰ᕱᜓበᏭྤफ़ऱ۞পۏؠІĂт ాቢ(connection)ăܑॾ(table)ătriggers ৶͔Ą
y
၆ VCL.NET ᑕϡё҃֏Ăధк Delphi ߊѣ۞ྤफ़ऱԫఙౌ̏གྷᑕϡ ٺ.NETĂ Β߁ dbExpress .NETăDataSnap .NET ClientăInterBase for .NETăͽ̈́ BDE .NETĄ
Visual Component Library (VCL) for .NET y
VCL .NET ॰ߛ೩ֻ˘ࠎ.NET ॰ߛՀາ۞૱֍ VCL ̮ІĄ
y
VCL ܑॾ designer ឰଋֹϡ VCL .NET ॰ߛ྆۞̮ІĂͽޙϲ.NET ෛ ᑕϡёĄ
y
ֹϡ WinForm Control Import WizardĂଋΞͽԯ.NET ෛܑॾ̮Іΐ זଋ۞ VCL ᑕϡёĄѩჟីឰଋ.NET ෛܑॾ̮І๗ˢ࣎˘ז Delphi इІĂޢιࣇщ྅̍זሹĄ
3-4
Delphi ԣిˢ͘ܝΊ
Delphi ᄬ֏੫၆.NET ۞ΐૻ ͽ˭Е Delphi ᄬ֏ࠎ͚೯.NET πέ Common Language Specification (CLS) ٙΐˢ۞າপّĈ y
ёቅ̷̶̙זТЩ۩ม(namespace)
y
ኬ̟ᙷҾјࣶາ۞Ξ֍ّϯෟ(visibility specifier)
y
ᙷҾ۞ᐖၗ͞ڱăᛳّҜ
y
ᙷҾ۞ޙၹ̄(constructor)
y
ᙷҾ྆૰(۞ېnested)ݭၗކӘ
y
ދҝ۞(sealed)ᙷҾ
y
۞(final)ᑢ͞ڱ
y
ᙷҾ྆ྻზ̄۞ᖬྶ(overload)
y
.NET ᛳّ(attribute)
y
ᙷҾ۞ᅃӄᙷҾᄬڱ
ቢ˯۞ Delphi ёᄬ֏ᖎ̬̏జՀາĂͽͅᑕ၆ٺ.NET ۞ΐૻ̝Ą
ёቅଠ۞טፋЪ y
Delphi 8 for .NET ೩ֻధкёቅଠטր۞ፋЪĂឰଋд IDE ྆ઇ ఼ϡ۞ёቅଠ̍טүĄ
y
ϫ݈͚೯۞ёቅଠטրѣ Borland StarTeamăConcurrent Versions System (CVS)ăRational ClearCaseăͽ̈́ Microsoft Visual SourceSafeĄ
Delphi 8 for .NET ۞າপّ
3-5
ࢦາనࢍ۞۞ᅃӄᄲځր y
ቢ˯ᅃӄᄲ̏ځགྷࢦາనࢍֹ֭ϡ Microsoft Document Explorer ҃ܧ WinHelpĄNavigation panesĞӣ ContentsăSearchă Indexğឰଋԣ ిͷटٽгԱ֭ז࿅ᕭྤੈĄ
y
ᅃӄᄲ̰۞ځट̏གྷડ̶јໄ۞هტ៍ăԔ۞͔ăͽ̈́ણ҂ྤੈĂ ٙѣֱౌΞͽଂ Contents хזפĄ
y
Microsoft .NET Framework SDK Help ˧םᇄથ۞ᅃӄᄲ̏ځፋЪז Delphi 8 for .NET Help ྆Ą
3-6
Delphi ԣిˢ͘ܝΊ
IDE ̝ॠ ༊ଋฟୁ Delphi 8 for .NET ॡĂፋЪّฟ൴ᒖဩ (IDE) ಶົୁજ֭ពϯధ к̍ᏴಏĄIDE םӄଋͽෛᛇ̼۞͞ёనࢍֹϡ۰̬ࢬăనۏؠІᛳّă ᇤᆷёቅăͽ̈́ϡЧᇹ۞͞ёᑭෛგநଋ۞ᑕϡёĄ న۞ IDE ॸࢬଵЕΒ߁˘ֱ૱ϡ۞̍ĄଋΞͽϡ View Ᏼಏԯߙֱ̍ ពϯٕᔳᖟֽĄଋ˵Ξͽҋࢎ֭ᐼхዋЪଋ̍ү۞ॸࢬଵЕĄ IDE ྆Ξϡ۞̍ෛଋֹϡ۞ Delphi 8 for .NET ۍώ҃ؠĂΒ߁Ĉ y
ᝌࢬࢱܓ
y
ܑॾ
y
Designer Surface
y
̍ሹ
y
ۏІᑭෛጡ
y
ۏІᚗऱ
y
९გநࣶ
IDE ̝ॠ
4-1
y
Data Explorer
y
ёቅበᏭጡ
ତ˭ֽࠎଋ࣎Ҿֱ̬̍Ą
ᝌࢬࢱܓĞWelcome Pageğ ༊ଋฟୁ Delphi 8 for .NET ॡĂᝌࢬࢱܓಶົனĂ֭ЕధкᏴีాඕ ֻଋᏴፄĄ༊ଋдฟ൴˘ٕ࣎к࣎९ॡĂົѣ˘ܑ࣎ॾЕଋ̍ܕү۞ ९Ăͽ̈́Տ࣎९జ࣒Լ۞ॡมĄֹଋΞͽޝԣгхפଋ̍ܕү۞ ९Ą тڍଋᙯౕᝌࢬࢱܓĂଋΞͽᏴፄ View -> Welcome Page ιࢦາฟୁĄ ᝌࢬࢱܓΒӣхפฟୁ९۞ตĄଋ˵Ξͽ Help ตхפາ۞ቢ ˯ᄲੈྤځĄProject ตฟୁ˘࣎̏хд۞९ٕ९ཏĄNew ต ฟୁۏІᚗऱ֭ឰଋଂЧ९ᇹۍᏴፄ˘Ăͽޙϲଋຐࢋ۞.NET ᑕϡ ёĄଋ˵ΞͽᏴ File -> New -> Other ֭߄ᏴዋЪଋֹϡ۰̬ࢬనࢍ۞ ᇹۍĄ
ܑॾĞFormsğ ܑॾߏֹϡ۰̬ࢬ˯۞ෛٕ HTML შࢱĄдనࢍഇมĂܑॾົனд designer surfaceĄଋΞͽଂ̍ሹԯ̮ІٳѢޙͽ˯ॾܑזϲଋ۞ֹϡ۰̬ ࢬĄ Delphi 8 for .NET ೩ֻˬᙷॾܑ۞ݭĂൾ߱۞ޢརົΐͽೡĄ̙ኢଋ ۞ᑕϡёߏᖣϤ Web ೩ֻЋຽទᏭΑਕ۞ Web ᑕϡёĂϺٕߏ೩ֻ̍ үநड़ਕ۞̰टពϯΑਕĂౌΞͽᏴፄዋЪଋ۞నࢍĄ୬д designer ёቅበᏭጡү̷ೱĂኛᕇᏴ IDE ˭͞࠹၆ᑕ۞ᇾចࢱĄ ୬хॾܑפĂኛᏴፄ File -> New -> OtherĄ
4-2
Delphi ԣిˢ͘ܝΊ
ෛܑॾ ෛܑॾϡֽޙϲેҖٺజგநᒖဩ(managed environment)۞ෛᑕϡ ёĄֹϡ.NET ᙷҾޙϲෛ۞͗މბѣ࣎ࢋ۞р ę ឰᑕϡё۞ ͗މბֹϡᕱᜓጡ͗މბֹڱϡ۞পّĂͽ̈́.NET ॰ߛྻϡдፋ࣎ߛ ၹ˯Ąෛܑॾ۞ࠧ͵࣎ᐹᕇඕЪֽĂणன۞ёሀ۞ݭрΒ ӣ.NET ॰ߛ̝˘ّĞּтщБ፟טજၗᑕϡёՀາğ̈́ GUI ෛމ ͗ბ̝ᖳಱّĄଋΞͽֹϡෛଠ̮טІтตăЕϯ͞ă͛ф͞ඈĂ ޙϲଋ۞ෛᑕϡёĄ ୬ х פෛ ܑ ॾ Ă ኛ Ᏼ File -> New -> Other ֭ д ९ ϫ ᐂ ྆ Ᏼ ፄ Application ဦϯĄ
ASP .NET Web ܑॾ ֹϡ ASP .NET Web ܑॾޙϲ۞ᑕϡёĂΞϤЇңπέ۞Ї˘ᕱᜓጡх פĄֹϡ.NET ᙷҾޙϲ۞ ASP .NET Web ܑॾᑕϡёĂॾܑΒӣ HTML ෛᛇܑ̼னă၁ᅫ۞ HTMLăͽ̈́ࡦ۞ޢёቅᑫ९Ą ୬х פASP .NET Web ܑॾĂኛᏴ File -> New -> Other ֭д ASP ९ϫᐂ ྆Ᏼፄ ASP .NET Web Application ဦϯĄ
VCL ܑॾ ֹϡ VCL ܑॾޙϲ۞ᑕϡёĂϡ VCL .NET ̮ІેҖٺ.NET ॰ߛĄଋΞ ͽֹϡ Borland Visual Component Library for .NET ۞ᙷҾޙϲ˘࣎ VCL ܑॾᑕϡёĄ тڍଋຐࢋனѣΒӣ VCL ଠ̮טІ۞ Delphi ᑕϡёொങז.NET ᒖဩĂ ٕ۰ߏଋ̏གྷሢଉ VCL ͷຐࢋֹϡιĂ֤ᆃ VCL ܑॾপҾѣϡĄ ୬х פVCL ܑॾĂኛᏴ File -> New -> Other ֭д Delphi for .NET Project ϫᐂ྆Ᏼፄ VCL .NET Application ဦϯĄ
IDE ̝ॠ
4-3
HTML Designer ֹϡ HTML designer ᑭෛበᏭ ASP .NET Web ܑॾٕ HTML შࢱĄѩ designer ೩ֻ˘࣎ Tag Editor ϡֽበᏭ HTML ۞ tagĄଋ˵ΞͽֹϡۏІᑭ ෛጡበᏭ HTML შࢱ˯Ξ֍ีϫ۞ᛳّĂ֭ពϯϫ݈д Tag Editor ྆Їң HTML tag ۞ᛳّĄҜ ٺTag Editor ˯͞۞Ъ͞ឰଋពϯበᏭ SCRIPT tagĄ ୬யϠ˘࣎າ۞ HTML ᑫ९ĂኛᏴ File -> New -> Other ֭д Markup File ϫᐂ྆Ᏼፄ HTML pageĄ༊ HTML შࢱពϯॡĂᏴಏົΐˢ˘࣎ Insert ᏴಏĄϡ࣎ᏴಏજၗгາᆧܑಏĂဦညĂֹϡ۰ଠ̮טІĄ
Designer Surface Designer surface ٕ designer ົдଋֹϡܑॾॡҋજனĄDesigner ۞γ៍ Αਕෛଋֹϡ۞ܑॾݭၗՙؠĄּтĂтڍଋдֹϡ ASP .NET Web ܑ ॾĂdesigner ពϯ˘࣎ HTML tag editorĄ୬хפѩ designerĂኛᕇᑝ IDE ۞ొغDesign ᇾចࢱĄ
ෛᛇ̼̮І ෛᛇ̼̮І(visual component)дనࢍഇมனдܑॾ˯Ăֹ҃ϡ۰ົдે Җഇม࠻זιĄιࣇΒӣตăᇾចă̍ЕăЕϯ͞ඈඈĄ
ܧෛᛇ̼̮І̮Іሹ ܧෛᛇ̼̮І(nonvisual component)ܢдܑॾ˯ĂҭιࣇΪົனдనࢍഇ มćֹϡ۰̙ົдેҖഇม࠻זιࣇĄଋֹϡܧෛᛇ̼̮І۞͞ёĂΞͽт ྤफ़ऱրۏІј۞ཏ˘ᇹгࢦኑֹϡĂٕߏညଋᑕϡёநྤ फ़ऱాቢЋຽఢ̶̶ొ۞ฟֹֽϡ˘ᇹĄ ༊ଋ˘࣎ܧෛᛇ̼̮ІΐॾܑזॡĂιࣇົனд designer surface ొغ ۞̮ІĄ̮ІឰଋΞͽෛᛇ̼̮Іܧෛᛇ̼̮Іડ̶ֽĄ
4-4
Delphi ԣిˢ͘ܝΊ
̍ሹĞTool Paletteğ ̍ሹΒӣ۞ีϫםӄଋฟ൴ᑕϡёĄֱன۞ีϫෛϫ݈۞൪ࢬ ҃ؠĄּтĂтڍଋϒд designer ߤ࠻˘ܑ࣎ॾĂ֤ᆃ̍ሹன۞ົߏዋ Ъྍܑॾ۞̮ІĄଋΞͽᗕᑝ˘࣎ଠ̮טІԯιΐזଋ۞ܑॾ˯Ąтڍଋϒ д࠻ёቅበᏭጡ྆۞ёቅĂ֤ᆃ̍ሹົனΞͽΐˢଋё۞ёቅ ͯ߱Ą
ҋᄦ۞̮І ੵ˞ Delphi 8 for .NET щ྅۞̮ІͽγĂଋΞͽҋᄦ۞̮Іٕ˧םᇄથ ̮۞ݡІΐˢ̍ሹĂ֭ᐼхдιࣇᛳ۞ᙷҾ̚Ą
̮Іᇹۍ ଋΞͽϡ˘ٕ࣎к̮࣎Іޙϲᇹ(ۍtemplate)Ąдܑॾ˯щଵр̮Іăనؠ ιࣇ۞ᛳّăᆷрιࣇ۞ёቅ̝ޢĂଋΞͽιࣇᐼхј˘̮࣎ІᇹۍĄ ޢـĂΪࢋд̍ሹᏴ࣎פᇹۍĂಶΞͽд˘࣎Վូְֱ྆Аޙၹр ۞ ̮ І ٸд ܑ ॾ ˯ ć Т ॡ ٙ ѣ ࠹ ᙯ ۞ ᛳ ّ (property) ְ І ந ё ቅ (event-handling code)ౌົΐזଋ۞९྆ĄଋΞͽ࣎Ҿгࢦາщଵֱ̮ І۞ҜཉĂనؠιࣇ۞ᛳّĂ֭ޙϲٕ࣒Լιࣇ۞ְІநёቅĂಶညι ࣇߏ࣎Ҿٸཉ۞˘ᇹĄ
ۏІᑭෛጡĞObject Inspectorğ ۏІᑭෛጡឰଋనؠనࢍഇม۞ᛳّĂͽ̈́ޙϲ̮І۞ְІநԔĄ೩ ֻ˞ᑕϡё۞ෛᛇγ៍ᄃឰᑕϡёેҖ۞ёቅ۰̝ม۞ాඕĄۏІ ᑭෛጡΒӣ࣎ᇾចࢱĈProperties EventsĄ ֹϡ Properties ࢱΞͽՀԼ̮І۞ᛳّĄֶፂଋ۞ᏴፄĂѣֱᙷҾឰଋд͛ ф྆͞ᏮˢࣃĂѣֱߏᅮࢋଋд˭ٛё྆͞Ᏼፄߙ࣎ࣃĄ၆ Boolean
IDE ̝ॠ
4-5
ྻზ҃֏Ăଋࢋд True False ̝มү̷ೱĄតՀԆ̮І۞ᛳّࣃ̝ޢĂଋ ΞͽޙϲְІநԔͽଠ̮טІ۞ྻүĄ ֹϡ Events ࢱΞͽؠଋᏴፄ۞ۏІ۞ְІĄт̏ڍགྷѣְІநԔĂ ֹϡ˭ٛё͞Ᏼፄ˘Ąдనଐ˭ڶĂѣֱۏІᑭෛጡ྆۞ᏴีົԶᝑ ֽĂଋΞͽдᙷҾय़۞ΐཱི (+) ᕇ˘˭ԯᏴีणฟĄ ѣֱܧෛᛇ̼۞̮Іּт Borland Data ProvidersĂΞឰଋԣిхפበᏭጡ т Connection Editor Command Text EditorĄଋΞͽдۏІᑭෛጡొغ ۞ Designer Verb ડાֹϡֱበᏭጡĄ୬ฟୁֱበᏭጡĂଋ۞ഫᇾொ זበᏭጡЩჍ˯ࢬۡזഫᇾតј˘͘ॡĂበᏭጡಶົតј˘࣎ాඕĄٕ۰Ă ଋΞͽΠᑝܧෛᛇ̼̮ІĂဂொ࠹זᙯా۞በᏭጡ֭ᏴפιĄኛڦຍĂ ֭ܧٙѣ۞ܧෛᛇ̼̮Іౌѣ࠹ᙯా۞በᏭጡĄੵ˞በᏭጡͽγĂડા˵ Ξͽѣాඕពϯҋࢎ۞̮ІበᏭጡăୁજ˘࣎ web შࢱăͽ̈́ពϯ၆ྖ͞ Ą
ۏІᚗऱĞObject Repositoryğ ࠎᖎ̼ฟ൴ĂDelphi 8 for .NET ೩ְֻАనࢍр۞ᇹۍăܑॾ̈́ีϫĂ ឰଋΞͽޝटֹ֭פٽϡٺଋ۞ᑕϡё̚ĄۏІᚗऱΞϤ File -> New -> Other хפĄѩॡ˘࣎ New Item ၆ྖົனĄଋ˵ΞͽགྷϤΠᑝۏ Іᚗऱ၅࠻በᏭᏴีĂበᏭۏІᚗऱ྆ߊѣ۞ۏІٕொੵιĄ ොĈᔵѩ၆ྖΨઇNew ItemsĂ၁ᅫ˯ιಶߏۏІᚗऱĄ
ۏІᚗऱ̰ొ ۏІᚗऱΒӣ۞ีϫஉᄏଋΞͽฟ൴۞.NET ᑕϡё۞ٙѣᙷݭĄιΒӣ ᇹۍăܑॾăధкีϫĄଋΞͽޙϲ९тᙷҾऱăଠ̮טІऱăଠ טέᑕϡёăHTML შࢱăͽ̈́ధкֹϡᇹۍฟ൴۞९Ą
4-6
Delphi ԣిˢ͘ܝΊ
ۏІᚗऱᇹۍ ଋΞͽଋҋ̎۞ۏІΐˢۏІᚗऱઇࠎᇹۍĂͽࢦܮኑֹϡٕߏᄃฟ ൴۰̶ֳĄࢦኑֹϡۏІឰଋдޙϲᑕϡёछॡֹϡ࠹Т۞ֹϡ۰̬ࢬ ΑਕĂтѩΞഴ͌ฟ൴ॡม֭ԼචݡኳĄ
९გநࣶĞProject Managerğ ˘࣎९ߏϤధкᑕϡёᑫ९јĄ९გநࣶឰଋ၅࠻֭ᖐଋ۞९ ᑫ९ĂтܑॾăેҖᑫăassemblyăۏІ library ᑫ९Ąд९გநࣶ྆Ă ଋΞͽΐˢăொੵăࢦາЩᑫ९Ąଋ˵Ξͽ࠹ᙯ۞९Ъј९ཏ ĂтѩଋΞͽТॡበᛌιࣇĄ
ΐˢણ (Reference) ଋΞͽଋߊѣ۞ COM Ҩڇጡ ActiveX ଠ̮טІፋЪזᑕϡё̚Ąᖣ ϤإϏৼˢგந۞(unmanaged) DLL ۞ણΐזଋ۞९̚Ăޢᕱᜓ ̚۞ᙷݭĂಶညଋдజგந۞(managed) assembly ྆ᕱᜓ˘ᇹĄᏴ פProject -> Add Reference ͽፋЪଋߊѣ۞ COM Ҩڇጡٕ ActiveX ଠ̮טІĄٕ۰Ă ଋ˵ΞͽΠᑝ९გநࣶ྆۞ Reference ӇĂ ޢAdd ReferenceĄଋΞ ͽֹϡѩপّΐˢ۞.NET assembliesăCOM/ActiveX ̮Іăٕݭၗऱ (type libraries)Ą
ણኑᄦזώгྮश дેҖॡഇĂٙѣ۞ assembly υืд९۞ᏮྮशĂٕߏдొཌ۞ Global Assemble Cache (GAC)྆Ąд९გநࣶ྆ĂଋΞͽΠᑝ˘࣎ assembly ֭ ֹϡ Copy Local నؠણኑᄦזώг۞ᏮྮशĄኛᏲͽ˭۞ֽࣧ ՙؠણߏӎυืኑᄦĈ y
тڍણົјࠎΩ˘࣎९྆யϠ۞ assemblyĂᏴፄ Copy Local నؠĄ
y
т ڍassembly д GAC ྆Ăኛ̙ࢋᏴፄ Copy Local నؠĄ
IDE ̝ॠ
4-7
ΐˢ Web ણ ଋΞͽԣిгWebણΐזଋ۞͗މბᑕϡё྆Ă֭хפଋຐࢋ۞Web ServiceĄ༊ଋΐˢ˘࣎WebણॡĂଋົԯೡߙ˘পؠWeb Service۞ WDSL͛І๗ˢଋ۞͗މბᑕϡё྆Ą˘όଋ๗ˢWDSL͛ІĂDelphi 8 for .NETயϠٙѣଋײΨྍWeb Serviceᅮࢋ۞̬ࢬᙷҾ۞ؠཌྷĄ୬ֹϡ ΐˢWebણ۞পّĂኛϤ९გநࣶΠᑝWeb Services༼ᕇĄ
Data Explorer Data Explorer ឰଋᕱᜓफ़ऱҨڇጡ۞ჩࢋۏІĂΒ߁ܑॾăҜăstored procedure ؠཌྷătriggers ৶͔Ąֹϡ̰टᏴಏ(context menu)ĂଋΞͽޙ ϲგநྤफ़ऱాቢĄଋ˵Ξͽྤफ़ଂྤफ़ֽ (data source) ٳѢז ९྆Ăͽԣిޙϲଋ۞ྤफ़ऱᑕϡёĄ
ёቅበᏭጡĞCode Editorğ ёቅበᏭጡ೩ֻ˞၅࠻࣒Լёቅ۞ܮӀ͞ёĄιߏ˘࣎ጾѣԆБΑ ਕăΞֶᅮࢋࢎү۞ ANSI በᏭጡĂ೩ֻΎពᄬ(ڱsyntax highlighting)ăк ࢦೇࣧ(multiple undo)ਕ˧ăͽ̈́ёᄬ֏̮৵۞ context-sensitive ᅃӄᄲ ځĄ
4-8
Delphi ԣిˢ͘ܝΊ
ฟؕາ۞९ ˘ ࣎ ९ ߏ ధ к ᑫ ९ ۞ ะ Ъ Ă Β ߁ ९ ᑫ Ğ Щ Ⴭ .bdsproj ğă assemblies ĞSystem.dllğăёྤफ़ऱ (program database) ᑫ९Ğ ЩჍ .pdbğăܧυࢋ ۞ྤᑫĞ.html, .jpeg, .gifğăેҖᑫĞ ЩჍ .exeğăͽ̈́ధк˘ј ᑕϡё۞ᑫ९Ą९ΞͽдనࢍഇมޙϲĂٕдበᛌ९ࣧؕᑫॡயϠĄ ࠎםӄฟ൴࿅ĂۏІᚗऱ೩ֻ˞ధкְАؠཌྷ۞ᇹۍăܑॾăᑫ९ă̈́ ีϫĂឰଋΞͽдޙϲ.NET ᑕϡёॡֹϡĄ ୬ޙϲ˘࣎າ۞९Ăኛдᝌࢬࢱܓᕇᑝ NewĂ֭Ᏼፄଋຐޙϲ۞ᑕϡё ᙷݭĂٕߏᏴፄ File -> New -> OtherĄ୬ฟୁ˘࣎ߊѣ۞९Ăኛдᝌࢱܓ ࢬᕇᑝ ProjectĂٕߏᏴፄ File -> Open ProjectĄ ώ༼Β߁۞ྤੈт˭Ĉ y
९۞ݭၗ
y
ᄃϏৼˢგந۞ёቅ˘ྻү
ฟؕາ۞९
5-1
९۞ݭၗ ॲፂଋֹٙϡ۞ Delphi 8 for .NET ۍώĂଋΞͽޙϲ็۞ෛᑕϡёă ASP .NET Web ᑕϡёăADO .NET ྤफ़ऱᑕϡёăWeb Service ᑕϡ ёăͽ̈́ధк۞ᑕϡёĄDelphi 8 for .NET ˵͚೯ assembliesăҋ ࢎ۞̮ІăкࢦેҖჰăͽ̈́ COMĄ୬ᒢྋଋֹϡ۞ۍώѣңপّ̍Ă ኛણ҂ http://www.borland.com/delphi_net ٙЕ۞পّܑĄ
ෛᑕϡё ଋΞͽֹϡෛܑॾޙϲෛᑕϡёĂ೩ֻநड़ਕ۞̰टពϯĄෛ ᑕϡёΞͽઇࠎ ADO .NET ྤफ़ऱ۞݈ბĄ ੵ˞ٳѢ̮Іෛᛇ̼ designers ͽγĂBorland ᔘ೩ֻ˘टޙٽϲᏴಏ ̄Ᏼಏ۞͞ёĄ.NET Menu Designers ۞ MainMenu ContextMenu ̮ ІឰଋΞͽෛᛇ̼నࢍᏴಏĂ֭ԣిᇤᆷ೩ֻΑਕ۞ёቅĄ
ASP .NET Web ᑕϡё ଋΞͽֹϡ ASP .NET Web ܑॾޙϲ Web ᑕϡёĂ೩ֻϤ Web хྤפफ़ ऱ Web ServicesĄWeb ܑॾ೩ֻ Web ᑕϡё۞ֹϡ۰̬ࢬĂΒӣ HTMLăҨڇጡଠ̮טІăͽ̈́ӣᑕϡёទᏭ۞ᑫ९ĄDelphi 8 for .NET ឰଋٳѢ̮І֭೩ֻдг۞ HTML በᏭĄ
ASP .NET Web Services ᑕϡё ଋΞͽޙϲ Web Service ᑕϡёĂд Web ็ᅍ̰टт HTML შࢱٕ XML ͛ІĄWeb Service ߏ˘ͽ Internet ࠎૄᖂ۞ፋЪ͞ڱĂឰᑕϡё࿅ Web ాତĂֹ֭ϡᇾ۞ੈिֽؠםϹೱྤੈĄ Delphi 8 for .NET ೩ֻޙϲ SOAP Ҩڇጡᑕϡё۞͞(ڱmethods)Ăͽᖎ ̼ Web Service ۞ޙϲĄ.asmx .dlls ᑫ९ົҋજޙϲĂ҃ଋΞͽд IDE ྆ ീྏ Web ServiceĂ̙ϡᆷЇң۞͗މბᑕϡёĄ
5-2
Delphi ԣిˢ͘ܝΊ
༊ଋᇤᆷֹϡ̏൴Ҷ۞ Web Service ۞͗މბᑕϡёॡĂΞͽϡ UDDI ᕱ ᜓጡԱזೡྍ Web Service ۞ WDSL ֭๗ˢזଋ۞͗މბᑕϡё྆Ą
VCL .NET ᑕϡё ଋΞͽֹϡ VCL ܑॾޙϲֹϡ VCL .NET ॰ߛ̮І۞.NET ෛᑕϡёĄ Delphi 8 for .NET೩ֻ̏ᕖᆧͷΞેҖٺ.NET॰ߛ˯۞VCL̮ІĂͽᖎ̼ޙ ၹ .NETᑕϡё۞̍үĄֹଋҺޙٺϲҋᄦ̮Іֽ೩ֻᇾ۞VCL̮І ਕ˧Ą˵ֹொങWin32 ᑕϡёז.NET۞࿅តՀटٽͷՀΞያĄ
ྤफ़ऱᑕϡё ኢଋ۞ᑕϡёֹϡෛܑॾăWeb ܑॾăٕߏ VCL ܑॾĂDelphi 8 for .NET ѣޝк̍ᑒӄଋटٽгాତྤफ़ऱăᕱᜓበᏭྤफ़ऱăેҖ SQL ߤྙăͽ̈́дనࢍഇมពϯϫ݈۞ྤफ़Ą ADO .NET ॰ߛ۞ data provider ឰଋх פMS SQLăOracleăͽ̈́ ODBC OLE DB Ξхྤ۞פफ़ऱĄBorland Data Providers (BDP .NET) ឰଋх פMS SQLăOracleăDB2 InterBase ྤफ़ऱĄଋΞͽాቢྤֱזफ़ֽ Ăιࣇ۞ྤफ़ពϯдྤफ़ะ྆Ă֭ϡ SQL ΄ፆүֱྤफ़Ąֹϡ DBP .NET ೩ֻͽ˭рĈ y
Ξொങ۞ёቅĂΪࢋᆷ˘ѨಶΞͽాቢזЇңѣ͚೯۞ྤफ़ऱĄ
y
ฟٸё۞ߛၹĂឰଋ೩ֻྤफ़ऱր۞͚೯Ą
y
ទᏭ˯۞ྤफ़ݭၗĂΞटٽг၆ᑕז.NET ۞ࣧѣݭၗ(native types)Ą
y
˘ّ۞ྤफ़ݭၗĂΞ၆ᑕזЧѣ͚೯ዋ༊ݭၗ۞ྤफ़ऱĄ
y
̙ည OLE DBĂ̙ᅮࢋ˘ᆸ COM/InteropĄ
ֹ ϡ VCL ܑ ॾ VCL .NET ॰ ߛ ̮ І ॡ Ă ଋ Ξ ͽ ϡ BDE .NET ă dbExpress .NET Midas Client for .NET ాቢԫఙֽᕖणྤफ़ऱ۞͚೯Ą
ฟؕາ۞९
5-3
ͽሀݭᜭજ۞ᑕϡё ሀ (modeling) ߏ˘࣎ϡֽೡహវనࢍ࿅۞ЩෟĄฟ൴˘࣎హវր ۞ሀֽ̂ݭᄲಶߏనࢍर (architect) ࠎ˘࣎̂۞ݭฟ൴९ޙϲ˘న ࢍဦĄಶည˘నࢍဦਠâ࣎ሀ̙ݭΪߏೡր۞̂ໄĂТॡ˵ឰଋჸ ൏дߙֱপ۞ؠг͞ĂтඕၹҖࠎ˯۞༼Ąሀݭឰٙѣдฟ൴ೈᒖ྆۞ ણᄃ۰ଂЇңপ۞ؠёᄬ֏Ğͽ̈́ࠤҌপؠԫఙ۞ߙֱᆸѨğ٩ᗓֽĂ ౌΞͽϡТᇹ۞ᄬ֏఼Ą Borland ۞ Model Driven Architecture (MDA) ೡ˞˘ሀ̍ԆБፋ Ъזฟ൴ᒖဩ྆۞హវ̍͞ёĄMDA ߏಛᖒ Borland ۞ Enterprise Core Objects (ECO) ॰ߛనࢍ۞ĄECO ॰ߛߏ˘̬ࢬăᙷҾҋࢎᛳّĂ೩ֻ ଋ۞ᑕϡё IDE ᄃሀѣᙯ۞পّ̝ม఼۞ሇĄ ECO পّΒ߁Ĉ y
ሀᙷ۞ݭҾăᛳّᙯాĂזᙯాёჩࢋ۞ҋજ၆ᑕĄ
y
ჩࢋᐌሀݭԼត۞ҋજႊซĄ
y
ޢბᐼх፟۞טఢॾĄଋΞͽᏴፄۏІᐼхдᙯాёྤफ़ऱٕߏ XML ᑫ९Ą
y
ሀ ݭObject Constraint Language (OCL) ܑϯёٺనࢍഇม۞ඕၹ ቁᄮĄ
y
OCL ܑϯёેٺҖഇม۞ቁᄮĄ
y
˘ְІ፟טĂឰଋдۏІາΐˢăԼតăٕொੵॡќ఼ۢזĄ
Delphi 8 for .NET IDE Ъ ˞׀ECO ॰ߛĂͽ೩ֻ˘࣎ፋЪ۞γ៍ឰଋฟ൴ ଋ۞ᑕϡёሀݭĄIDE ۞ሀγ៍পّΒ߁Ĉ
5-4
y
ޙϲͽሀݭᜭજ۞ᑕϡёĂઇࠎ˘າ۞९Ą
y
ۡତд surface ˯ޙϲᙷҾဦĂ֭ፆүሀ̮۞ݭ৵ĞӈइІᙷҾğĄ
y
дᙷҾဦ˯ΐˢăொੵԼតᙷҾ۞ᛳّڱ͞Ą
Delphi ԣిˢ͘ܝΊ
y
ࣧؕቅሀγ៍̝ม۞ᗕШՀາĄࣧؕቅ۞Հજົͅߍдဦԛ̼۞ೡ ˯Ă̝ͅϺĄ
y
ሀ̮ݭ৵ؕࣧቅ̝ม۞ᗕШ၅࠻ĄଋΞͽଂሀ̮ݭ৵۞ဦԛ̼ೡۡ ତ၅࠻ι၆ᑕ۞ࣧؕቅĄТᇹгĂଋΞͽଂࣧؕቅ྆̏གྷሀ۞ᙷҾۡ ତ၅࠻ιдሀγ៍˯۞ဦԛĄ
y ڦຍ
ֹϡ XMI 1.1 ๗๗ˢሀݭĄ
֭ܧٙѣ۞ Delphi 8 for .NET ۍώౌ೩ֻٙѣ۞ሀপّĄࢋۢଋ۞யݡ ۍώѣֱࣹሀপّĂኛણ҂ www.borland.com/delphi_net ٙЕ۞পّܑĄ
Assemblies ˘࣎ assembly ߏ˘࣎ޝည DLL ᑫ९۞ទᏭइІĂΒӣಏ(manifests)ăሀ ăΞொങ۞ેҖᑫ(PE)ăͽ̈́ྤᑫ(.html, .jpeg, .gif)ĂΞϡֽొཌડ ̶ۍώĄ˘࣎ᑕϡёΞͽѣ˘ٕк࣎۞ assembliesĂֱ҃ assemblies ˵ Тॡజ˘ٕк࣎ᑕϡёٙણĂפՙ ٺassemblies ߏӎҜٺᑕϡё۞ ϫᐂٕд˘࣎ global assembly cache (GAC) ྆Ą
ᗝγ۞९ ੵ˞˯۞९ᙷݭĂDelphi 8 for .NET ೩ֻᇹޙͽۍϲᙷҾऱăଠ̮טІ ऱăଠטέᑕϡёăVisual Basic ᑕϡёăಡܑă͛фᑫĄֱ ᇹۍᐼхдۏІᚗऱĂଋΞͽᏴፄ File -> New -> Other хפιࣇĄ
Ϗৼˢგந۞ёቅᄃ COM/Interop Ϗგந۞ёቅ՟ѣͽ.NET Framework Common Language Runtime (CLR)ࠎϫᇾ۞ᑕϡёѣᙯĄCOM/Interop ߏ˘.NET ڇચĂឰజგந ۞Ϗజგந۞ёቅ̝มΞͽม۞̢࠹ྻүĄCOM/Interop ڇચឰଋ дᑕϡё྆ྻϡனѣ۞ COM Ҩڇጡ ActiveX ଠ̮טІĂ֭ឰ็۞Ϗ జგந۞ᑕϡёΞͽ࠻ז.NET ̮ІĄDelphi 8 for .NET IDE Βӣ̍
ฟؕາ۞९
5-5
םӄଋଋߊѣ۞ COM Ҩڇጡ ActiveX ଠ̮טІፋЪזజგந۞ᑕϡ ё྆ĄΩγĂଋΞͽԯϏგந۞ DLL ۞ણΐזଋ۞९྆Ăޢᕱᜓ̚ ۞ᙷݭĂಶညଋдజგந۞ assemblies ྆ᕱᜓ˘ᇹĄ
5-6
Delphi ԣిˢ͘ܝΊ
ёቅበᏭጡ ёቅበᏭጡ೩ֻ˞၅࠻࣒Լёቅ۞ܮӀّĄιߏ˘࣎ጾѣԆБΑਕă Ξֶᅮࢋࢎү۞ ANSI በᏭጡĂ೩ֻΎពᄬڱăкࢦೇࣧਕ˧ăͽ̈́ёᄬ ֏̮৵۞ context-sensitive ᅃӄᄲځĄ ༊ଋనࢍᑕϡё۞ֹϡ۰̬ࢬॡĂDelphi 8 for .NET யϠ۞˭غёቅĄ ༊ଋ࣒ԼۏІ۞ᛳّॡĂֱԼតົҋજͅߍזёቅĄ Яࠎଋٙѣ۞ёົ̶ֳВТ۞পّĂDelphi 8 for .NET ֻᑕҋજயϠ۞ ёቅֽᑒӄଋฟؕүຽĄኛ̙ࢋ࣒Լ Initialize Components ̚͞ڱҋજயϠ ۞ёቅĄтѩົдଋᕇᑝ Design ᇾចࢱॡౄјܑॾ۞ঐεĄଋΞͽԯҋ જயϠ۞ёቅຐјޙϲёॡ۞ਨ९Ą ёቅበᏭጡ೩ֻͽ˭۞ΑਕםӄଋᇤᆷёĈ y
எˢёቅ
y
ᙷҾԆј
y
ёቅᕱᜓ
y
ёቅͯ߱
ёቅበᏭጡ
6-1
y
ёቅԶᝑ
y
ޞநಏ
y
ᔣᑝ۞λะ
எˢёቅĞCode Insightğ எˢёቅ۞ߏёቅበᏭጡ྆۞˘পّĂдᇤᆷё۞࿅̚೩ֻם ӄĄֱপّົពϯ context-sensitive ۞ᇅёෛ֭೩ֻͽ˭ڇચĈ y
םӄԱזଋԓ୕ΐˢёቅ྆۞૱ϡୃĄ
y
םӄᏴፄᛳّڱ͞Ą
y
ពϯߙপᙷؠҾΞϡ۞ְІĄ
y
೩ֻᙊҾф۞ކӘྤੈĄ
୬ֹϡஎˢёቅ۞পّĂኛᏴ Tools -> Options ֭ᕇᑝ Code InsightĄ
ᙷҾԆјĞClass Completionğ ᙷҾԆј۞পّᑒӄଋࠎކӘ۞ᙷҾјࣶயϠߛ(skeleton)ёቅĂͽᖎ̼ ؠཌྷ၁үາᙷҾ۞࿅Ąഫᇾٸдಏ̮(unit)۞̬ࢬડા۞ᙷҾކӘ˯Ă ֭˭ CTRL+SHIFT+CĂЇңإϏԆј۞ᛳّކӘಶົజԆјĂ҃ͷ၆Їңᅮ ࢋ၁ү۞ֽ͞ڱᄲĂ۩۞͞ົڱజΐז၁үડા྆Ą
ёቅᕱᜓ ༊ଋֹϡёቅበᏭጡֽበᏭ˘࣎ VCL ܑॾᑕϡёॡĂΞͽ CTRL ᔣᔣ֭ဂொזЇ˘ᙷҾăតᇴăᛳّă͞ڱăٕᙊҾф۞˯͞Ąѩ ॡဂᇾតј˘͘ĂᙊҾфజࡎពֽ֭ͷొغ൪ቢć˭ဂĂё ቅበᏭጡಶົྯྍזᙊҾф۞ކӘĂෛᅮࢋฟୁࣧؕᑫ९Ąଋ˵ΞͽΠᑝߙ ᙊҾф֭Ᏼፄ Find DeclarationĄ
6-2
Delphi ԣిˢ͘ܝΊ
ёቅᕱᜓΞͽԱ֭זฟୁ่Ҝд९۞ Search ྮशٕ Source ྮश྆Ăٕ ߏώய ۞ݡBrowsing ٕ Library ྮश྆۞ಏ̮Ąϫᐂͽ˭ึԔຩವĈ 1 ९۞ Search ྮशĞProject -> Options -> Directories/ConditionalsğĄ 2 ९۞ Source ྮशĞ९ᐼх۞ϫᐂğĄ 3 ᇃા۞ Browsing ྮशĞTools -> Options -> LibraryğĄ 4 ᇃા۞ Library ྮशĞTools -> Options -> LibraryğĄ Library ྮश่д IDE ྆՟ѣ९ฟୁॡ̖జຩವĄёቅᕱᜓڱԱזາ ۞ăإϏᐼх۞ಏ̮ᑫ९྆۞ᙊҾфĂТॡιдइІ(package)९྆˵՟ѣ үϡĄ ѩγĂёቅበᏭጡѣᙷҬ Web ᕱᜓጡ྆۞ன۞ᕱᜓตĄ୬ពϯ ֱตĂኛΠᑝ IDE ̍Е۞Їຍ۩Ϩડા֭Ᏼፄ BrowserĄ༊ଋдధкᑫ ९̝ม̷ೱॡĂёቅበᏭܲଋഅགྷז࿅۞ёቅҜཉĄଋΞͽ˭ᕱ ᜓตय़۞˭ٛᐝĂдֱ።Ϋᐂ྆ޢـٕ݈ـொજĄ
ёቅͯ߱ĞCode Snippetsğ ёቅͯ߱ߏ૱ϡт ifăwhileăfor ୃඈΞͽΐזё྆۞ёቅୃĄ ༊ёቅበᏭጡฟୁॡĂଋΞͽᗕᑝ̍ሹ˯۞ߙ˘ёቅͯ߱Ăιΐז ଋ۞ё̚Ąଋ˵Ξͽޙϲᛳٺҋ̎۞ёቅͯ߱ĂӈᏴפёቅበᏭጡ྆ ۞ёቅĂ֭˭ ALT ᔣĂֱёቅٛ̍זሹ˯Ą
ёቅԶᝑĞCode Foldingğ ёቅԶᝑឰଋёቅ߱རԶᝑֽĂͽޙϲёቅ۞ลᆸёᑭෛĂ֭ឰ ଋՀटٽዦፆଠёቅĄԶᝑֽ۞ёቅ֭՟ѣజӁੵĂΪߏᔳᖟ ֽĄ୬ֹϡёቅԶᝑĂኛёቅय़۞ΐഴཱིĄ
ёቅበᏭጡ
6-3
ޞநಏĞTo-Do Listsğ ˘࣎ޞநಏᐂ˞ߙ९υืԆј۞̍үีϫĄߙ˘̍үΐޞזந ಏޢĂଋΞͽበᏭྍ̍үăιזٸଋ۞ё྆༊үොྋăᇾϯι̏Ԇјă ͽ̈́ιଂಏ̚ொੵĄଋΞͽ࿅ᕭѩಏͽಏಏពϯଋຏᎸ۞̍үĄ
ᔣᑝ۞λะĞKeystroke Macrosğ ༊በᏭёॡĂଋΞͽᐂᄦ˘րЕ۞ᔣᑝઇࠎ˘࣎λะĄдᐂᄦ˘࣎λะ̝ ޢĂଋΞͽдϫ݈۞ IDE session ྆ᇫٸιͽࢦኑֱ࠹Т۞ᔣᑝĄᐂᄦ˘ ࣎λะᖬᄏ̝݈ᐂᄦ۞λะĄ
6-4
Delphi ԣిˢ͘ܝΊ
ᅃӄᄲੈྤ۞ځ ѩ༼Βӣͽ˭ྤੈĈ y
ࢦາనࢍ۞ Delphi 8 for .NET ᅃӄᄲځ
y
Microsoft .NET Framework SDK ᅃӄᄲځ
y
Borland ฟ൴۰͚೯ڇચ̈́შ৭
y
Delphi 8 for .NET ԣిˢ͔ܝ
y
ᅃӄᄲ۞ځଵۍၚּ
ࢦາనࢍ۞ Delphi 8 for .NET ᅃӄᄲځ Delphi 8 for .NET ᅃӄᄲ̏ځགྷజࢦາޙၹĂ̰टΒ߁ໄ۞هტ៍ăԔ۞ ͔ăͽ̈́ણ҂۞ྤੈĂֶፂଋ࣎ˠ۞ᅮࢋ೩ֻଋ˘ਠٕপੈྤ۞ؠĄ ੵѩ̝γĂᅃӄᄲځෛ྆۞ navigation ͞ॾឰଋՀटٽຩವ࿅ᕭྤੈĄ дనଐԛ˭՟ѣనؠ࿅ᕭ୧ІĂଋΞͽ၅࠻ٙѣ̏щ྅۞ᄲځĄ҃Ăࡶ ࢋдຩವᅃӄᄲֹٕځϡ৶͔ॡᒺ̈ቑಛĂΞͽϡ ContentăSearchă Index
ᅃӄᄲੈྤ۞ځ
7-1
͞ॾ྆۞˭ٛёᏴಏ࿅ᕭቑಛĄ୬ពϯ navigation ͞ॾĂኛᏴ View -> NavigationĄ
ໄ۞هტ៍ ෛໄ۞هტ៍೩ֻ۞ྤੈߏᙯٺயߛݡၹă̮Іăᖎ̼ฟ൴۞̍Ąтڍ ଋߏߙฟ൴ᅳા۞າ͘Ăּтሀٕ ADO .NETĂኛ࠻ቢ˯ᅃӄᄲځՏ࣎ౢ ༼ฟؕ۞ტ៍ᗟĄ д̂ొ̶ტ៍۞ඕԍĂଋົ൴னᄃྍᗟ࠹ᙯͷՀஎˢ۞ాඕĄֱాඕົ ాז.NET SDKă˧םᇄથ۞ᅃӄᄲځăᔘߏߙ࣎შ৭ĂົϡဦϯܑனֽĄ ώᗟൾົޢྋᛖֱဦϯĄ
Ԕ۞͔ Ԕ۞͔೩ֻՎ۞ϯĄ၆Β߁ధк̄Їચ۞ฟ൴̍ү҃֏Ăѣֱ८͕ Ԕ(core procedures)ࢋઇĂ֭ͷߏᅮࢋ˘ֱ̄ЇચֽԆј˘Іྵ̂۞Ї ચĄтڍଋϒฟؕ˘࣎ฟ൴९Ă֭ຐۢᅮࢋֱࣹՎូĂኛ࠻ྍᅳા۞८ ͕ԔĄ ੵ˞८͕ԔͽγĂᔘѣధкಏ˘Їચ۞ԔĄ ٙѣ۞Ԕౌٸдᅃӄᄲځෛ྆ Content ͞ॾ۞ Procedure ᇾᗟ̝˭Ąѩ γĂ̂ొ̶ໄ۞هტ៍ౌ೩ֻ࠹ᙯԔ۞ాඕĄ
ણ҂ᗟ ણ҂ᗟ೩ֻ API ̮৵ăDelphi ᄬ֏በᛌ΄ඈᗟ۞ྎྤੈĄ ٙѣ۞ણ҂ᗟౌٸдᅃӄᄲځෛ྆ Content ͞ॾ۞ Reference ᇾᗟ̝ ˭Ąੵѩ̝γĂ̂ొ̶ᅃӄᄲ ۞྆ځAPI ણౌົ൪غቢ֭ۡତాඕזዋ༊ ۞ણ҂ᗟĄ
7-2
Delphi ԣిˢ͘ܝΊ
Context Sensitive ۞ F1 ᅃӄᄲځ Context sensitive ᅃӄᄲځд IDE ྆ΞͽАᏴߙีϫГ F1 ᔣĈ y
дёቅበᏭጡ྆ĂᏴפፋ̮࣎৵Ăּтߙ࣎ namespaceăᙯᔣфăٕ ͞ڱĂГ F1
ڦຍ
y
дܑॾ۞ Design ᇾចࢱ˯Ᏼ̮פІĂГ F1
y
дੈिෛ྆Ᏼੈ࣎ߙפिĂГ F1
y
д IDE ۞ෛ྆т९გநࣶٕ Model ViewĂдෛ۞ቑಛ྆ F1
д VCL .NET ॰ߛ۞̮৵˯ F1 ពϯ Delphi 8 for .NET ᅃӄᄲځćд.NET ॰ߛ۞̮৵˯ F1 ពϯ Microsoft .NET ᅃӄᄲځĄ
Microsoft .NET Framework SDK ᅃӄᄲځ Delphi 8 for .NET ۞ ൴ Ҷ Β ӣ ѣ ̂ ณ ᅃ ӄ ᄲ ۞ ځMicrosoft .NET Framework SDKĄDelphi 8 for .NET ᅃӄᄲົځдዋ༊۞г͞Ă೩ֻז.NET Framework SDK ቢ˯ᅃӄᄲా۞ځඕĄ࠹ͅгĂଋΞͽۡତଂ Start -> Programs -> Microsoft .NET Framework SDK -> Documentation хפԆፋ ۞.NET Framework SDK ቢ˯ᅃӄᄲځĄ
Borland ฟ൴۰͚೯ڇચ̈́შ৭ Borland ೩ֻధк͚೯ͽЪᇃ̂ฟ൴ۤཏ۞ᅮࢋĄ୬Ա࠹זᙯ۞͚೯Ăኛ ણ҂ www.borland.com/devsupportĄଂ࣎შ৭ĂଋΞͽхפధкฟ൴۰ϡ ֽϹೱྤੈă৪థԫఙ۞າჷཏĄྍშ৭˵Β߁˘րЕ۞ Delphi 8 for .NET ३ᚱăԫఙ͛ౢ૱֍યᗟะ(FAQ)ĄѩγĂଋΞͽх פBorland Developer NetworkĄ
ᅃӄᄲੈྤ۞ځ
7-3
Delphi 8 for .NET ԣిˢ͔ܝ Delphi 8 for .NET ԣిˢ͔ܝ೩ֻ Delphi 8 for .NET ฟ൴ᒖဩ۞ໄ៍Ăͽ םӄଋщ྅ϲӈֹϡྍயݡĄԣిˢ͔̏ܝдଋᔉ෴ய۞ݡТॡϹ;ග ଋĄ
ᅃӄᄲ۞ځଵۍၚּ ͽ˭۞ଵۍၚֹּϡ ٺDelphi 8 for .NET ٙѣ۞ቢ˯ᅃӄᄲځĈ ၚּ Monospace type
ϡֽܑϯ ଋυืᏮˢ۞ёቅ͛фĄ
វ
ܲ۞ёᄬ֏ᙯᔣфٕበᛌጡᏴีĂ၆ྖ͞۞̍ણĄ
វ
Delphi 8 for .NETᙊҾфĂтតᇴٕᙷݭЩჍĄវф˵ϡٺ३ ώ۞ᇾᗟͽ̈́າЩෟ۞ΐૻĄ
̂ᆷ
ᔣሹ˯۞ߙᔣĂּтCTRLٕENTERĄ זშྮྤ۞ాඕĄ זMicrosoft SDK͛І۞̰ొాඕĄ זBorland˧םᇄથٙ೩ֻ͛І۞γొాඕĄ
7-4
Delphi ԣిˢ͘ܝΊ