Under the hood on extending the my namespace
Download
1 / 21

Under the Hood on Extending the My Namespace - PowerPoint PPT Presentation


  • 212 Views
  • Uploaded on

Under the Hood on Extending the My Namespace. Joe Binder TLN414 Program Manager Microsoft Corporation. Agenda. Design goals My and the .NET Framework Extensibility Model Customizing My, Step-by-Step Deploying My Extensions and Customizations Questions. The My Namespace Vision.

loader
I am the owner, or an agent authorized to act on behalf of the owner, of the copyrighted work described.
capcha
Download Presentation

PowerPoint Slideshow about 'Under the Hood on Extending the My Namespace' - Olivia


An Image/Link below is provided (as is) to download presentation

Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author.While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server.


- - - - - - - - - - - - - - - - - - - - - - - - - - E N D - - - - - - - - - - - - - - - - - - - - - - - - - -
Presentation Transcript
Under the hood on extending the my namespace l.jpg

Under the Hood on Extending the My Namespace

Joe Binder

TLN414

Program Manager

Microsoft Corporation


Agenda l.jpg
Agenda

  • Design goals

  • My and the .NET Framework

  • Extensibility Model

  • Customizing My, Step-by-Step

  • Deploying My Extensions and Customizations

  • Questions


The my namespace vision l.jpg
The My Namespace Vision

… To provide a highly approachable, unified runtime environment for Visual Basic developers.


Design pillars l.jpg
Design Pillars

  • Task-based APIs

  • Default configurations for extensible components

  • Promote best-practice usage patterns

  • Use .NET Framework constructs directly


Example interaction model my application log l.jpg
Example Interaction ModelMy.Application.Log

.NET Framework 2.0 contains powerful and extensible tracing architecture

  • Highly factored design

  • Enterprise scenarios require extension to existing services

  • Configuration is hard!

    My.Application.Log provides a simple entry point and default configuration



Inside the my namespace extensibility points l.jpg

Add new top-level properties

Devices

Inside The My NamespaceExtensibility Points

— Customize application model, events, …

— Add device support, hardware events, …

— Custom authorization and authentication

— Use external store (e.g., settings) for settings


Inside the my namespace architectural overview l.jpg

WindowsApplication1

Namespace My

ReadOnly Property Application As MyApplication

...

Class MyApplication

Inherits ApplicationServices.ApplicationBase

End Class

End Namespace

Microsoft.VisualBasic.dll

Namespace ApplicationServices

Public Class ApplicationBase

ReadOnly Property Log As Log

End Class

End Namespace

Inside The My NamespaceArchitectural Overview


Extending my at the root level l.jpg

Extending My at the Root-Level

Adding My.Devices to the Hierarchy


Application model architectural overview l.jpg
Application ModelArchitectural Overview

Shared Sub Main(ByVal Args As String())

My.Application.Run(Args)

End Sub

Namespace My

Partial Friend Class MyApplication

Inherits WindowsFormsApplicationBase

End Class

End Namespace

Startup

Namespace Microsoft.VisualBasic.ApplicationServices

Class WindowsFormsApplicationBase

Inherits ConsoleApplicationBase

End Class

End Namespace

NetStatusChanged



My settings architectural overview l.jpg
My.Settings Architectural Overview

SettingsBase

SettingsProvider

ApplicationSettingsBase

LocalFileSettingsProvider

<userSettings>

<WindowsApplication1.My.MySettings>

<setting name="FavoriteColor">

<value>0, 192, 0</value>

</setting>

</WindowsApplication1.My.MySettings>

</userSettings>

My.Settings

Property FavoriteColor As Color

Property LastLoggedIn As Date



Customizing my user l.jpg
Customizing My.User

  • Thin wrapper atop IPrincipal/IIdentity

  • WindowsPrincipal used as default

  • Custom Authentication and Authorization are wired in through IPrincipal/IIdentity

IPrincipal

WindowsPrincipal

My.User

IIdentity

WindowsIdentity


Customizing my user15 l.jpg

Customizing My.User

Leveraging ASP.NET Personalization in Windows Forms


Extending the my namespace design guidelines l.jpg
Extending the My NamespaceDesign Guidelines

  • Stateless APIs when appropriate

  • Global Instances.

  • Simple Parameter Types

  • Factory Methods

  • Thread-safe

  • .NET Framework Guidelines still apply!


Extending the my namespace deployment l.jpg
Extending the My NamespaceDeployment

  • Class libraries factored into standalone assemblies

  • Extensibility code factored into Visual Studio Template

  • All components packaged and deployed as .VSI

MyAppExtension.vb

.vsi

.vstemplate

CustomTypes.dll


Where to go from here l.jpg
Where to go from here?

  • Attend HOL TLN023!

  • Stop by Tools & Language Track Lounge!

  • Additional resources:

    • http://msdn.microsoft.com/msdnmag/issues/05/07/My/default.aspx

    • http://msdn.microsoft.com/vbasic/default.aspx?pull=/library/en-us/dnvs05/html/vbmy.asp


Questions l.jpg
Questions

Email: jbinder@microsoft.com


Slide20 l.jpg

Please Complete An Evaluation FormYour Input Is Important!

Two ways to access Online Evaluation Forms:

CommNet stations located throughout conference venues

From any wired or wireless connection to: http://www.MyTechReady.com

For more information please refer to your Pocket Guide


Slide21 l.jpg

© 2005 Microsoft Corporation. All rights reserved.

This presentation is for informational purposes only. Microsoft makes no warranties, express or implied, in this summary.