Castle Manoj Waikar Pune, India.. Introduction Castle aspires to simplify the development of enterprise and web applications. It offers a set of tools.

Slides:



Advertisements
Similar presentations
The Hydra Framework as a Series of Diagrams Naomi Dushay Stanford University Libraries April,
Advertisements

Apache Struts Technology
Aspect Oriented Programming. AOP Contents 1 Overview 2 Terminology 3 The Problem 4 The Solution 4 Join point models 5 Implementation 6 Terminology Review.
Spring, Hibernate and Web Services 13 th September 2014.
.NET Database Technologies: Open-Source Frameworks.
1 Introduction to SOA. 2 The Service-Oriented Enterprise eXtensible Markup Language (XML) Web services XML-based technologies for messaging, service description,
Component Patterns – Architecture and Applications with EJB copyright © 2001, MATHEMA AG Component Patterns Architecture and Applications with EJB JavaForum.
Ruby on Rails by Manik Juneja Ruby On Rails. Ruby on Rails by Manik Juneja Rails is a Web Application development framework. Based on the MVC pattern.
Review Amit Shabtay. March 3rd, 2004 Object Oriented Design Course 2 Review What have we done during the course? Where to learn more? What is for the.
Kashif Jalal CA-240 (072) Web Development Using ASP.NET CA – 240 Kashif Jalal Welcome to week – 2 of…
Performed by:Gidi Getter Svetlana Klinovsky Supervised by:Viktor Kulikov 08/03/2009.
CS 290C: Formal Models for Web Software Lecture 6: Model Driven Development for Web Software with WebML Instructor: Tevfik Bultan.
UNIT-V The MVC architecture and Struts Framework.
Enterprise Object Framework. What is EOF? Enterprise Objects Framework is a set of tools and resources that help you create applications that work with.
A little engineering on Rails Robert W. Hasker. Goals Intro to the Rails framework ▫Basic concepts: MVC, Active Record ▫A bit of Ruby Using Rails to build.
Storm-The-Castle an introduction to MVC, AR design pattern using Castle MonoRail and ActiveRecord rev 2 Date: 2009/10/04.
©Ian Sommerville 2006Software Engineering, 8th edition. Chapter 18 Slide 1 Software Reuse.
Introduction to the Enterprise Library. Sounds familiar? Writing a component to encapsulate data access Building a component that allows you to log errors.
Software Engineering Muhammad Fahad Khan
©Ian Sommerville 2004Software Engineering, 7th edition. Chapter 18 Slide 1 Software Reuse.
LAYING OUT THE FOUNDATIONS. OUTLINE Analyze the project from a technical point of view Analyze and choose the architecture for your application Decide.
Pittsburgh Java User Group– Dec Java PureFaces: A JSF Framework Extension.
Architecture Of ASP.NET. What is ASP?  Server-side scripting technology.  Files containing HTML and scripting code.  Access via HTTP requests.  Scripting.
Outline Introduction Problem Statement Object-Oriented Design Aspect-Oriented Design Conclusion Demo.
Design Patterns.
NOTE: To change the image on this slide, select the picture and delete it. Then click the Pictures icon in the placeholder to insert your own image. WEB.
Agile Web Development with the Castle Project 15/05/2008, Skills Matter Gojko Adzic
© 2008 Dr. Paul Walcott – The University of the West Indies: Cave Hill CampusDr. Paul Walcott COMP6325 Advanced Web Technologies Dr. Paul Walcott The University.
Copyright © 2012 Accenture All Rights Reserved.Copyright © 2012 Accenture All Rights Reserved. Accenture, its logo, and High Performance Delivered are.
Todd Snyder Development Team Lead Infragistics Experience Design Group.
Standalone Java Application vs. Java Web Application
An Introduction to Design Patterns. Introduction Promote reuse. Use the experiences of software developers. A shared library/lingo used by developers.
1 Dr Alexiei Dingli Web Science Stream Introducing Rails.
A Presentation By V AIBHAV S AHARAN Web-enHanced Information Management COMS E6125.
Chapter 38 Persistence Framework with Patterns 1CS6359 Fall 2011 John Cole.
Developing AJAX Web applications with Castle Monorail David De Florinier Gojko Adzic Skills Matter 12/06/08.
Alternative Architectures: Inversion of Control Mike Hadlow mikehadlow.blogspot.com.
Introducing Allors Applications, Tools & Platform.
Model View Controller MVC Web Software Architecture.
©Ian Sommerville 2006Software Engineering, 8th edition. Chapter 18 Slide 1 Software Reuse.
Java EE Patterns Dan Bugariu.  What is Java EE ?  What is a Pattern ?
XFormsDB An XForms - Based Framework for Simplifying Web Application Development Markku Laine Master’s Thesis Presentation March 9, 2010.
© FPT SOFTWARE – TRAINING MATERIAL – Internal use 04e-BM/NS/HDCV/FSOFT v2/3 JSP Application Models.
Preface IIntroduction Objectives I-2 Course Overview I-3 1Oracle Application Development Framework Objectives 1-2 J2EE Platform 1-3 Benefits of the J2EE.
Date : 3/04/2010 Web Technology Solutions Class: PHP Web Application Frameworks.
Declarative Languages and Model Based Development of Web Applications Besnik Selimi South East European University DAAD: 15 th Workshop “Software Engineering.
Component Patterns – Architecture and Applications with EJB copyright © 2001, MATHEMA AG Component Patterns Architecture and Applications with EJB Markus.
Virtual techdays INDIA │ 9-11 February 2011 SESSION TITLE Kamala Rajan S │ Technical Manager, Marlabs.
APACHE STRUTS ASHISH SINGH TOMAR ast2124. OUTLINE Introduction The Model-View-Controller Design Pattern Struts’ implementation of the MVC Pattern Additional.
Singleton Academy, Pune. Course syllabus Singleton Academy Pune – Course Syllabus1.
Model-View-Controller an introduction to MVC design pattern with Castle.MonoRail Presentation: v1.0 Prepared by: Chorn Sokun
Introduction to ASP.NET development. Background ASP released in 1996 ASP supported for a minimum 10 years from Windows 8 release ASP.Net 1.0 released.
Apache Struts Technology A MVC Framework for Java Web Applications.
Understanding Dependency Injection… and those pesky containers Miguel A. Castro Architect -
Submitted by: Moran Mishan. Instructed by: Osnat (Ossi) Mokryn, Dr.
Presented by Alexey Vedishchev Developing Web-applications with Grails framework American University of Nigeria, 2016 Intro To MVC Architecture.
© Copyright SELA software & Education Labs Ltd Baruch Hirsch St.Bnei Brak Israel
Cake PHP – OOPS approach for PHP
Jim Fawcett CSE686 – Internet Programming Spring 2014
Jim Fawcett CSE686 – Internet Programming Spring 2012
Haritha Dasari Josue Balandrano Coronel -
Top Reasons to Choose Angular. Angular is well known for developing robust and adaptable Single Page Applications (SPA). The Application structure is.
MVC Framework, in general.
Ruby on Rails by Manik Juneja
Web Development Using ASP .NET
Ruby on Rails by Manik Juneja
The Model Layer What is Model?
…and web frameworks in general
Developing and testing enterprise Java applications
CSE591: Data Mining by H. Liu
Presentation transcript:

Castle Manoj Waikar Pune, India.

Introduction Castle aspires to simplify the development of enterprise and web applications. It offers a set of tools (working together or independently) and integration with other open source projects, thereby helping you get more done with less code.

Castle Stack

Different projects under Castle Rapid Web Application Development MonoRail Object Relational Database Mapping ActiveRecord – The enterprise data mapping pattern implemented using Nhibernate. ActiveRecord Generator - A desktop application to generate ActiveRecord classes based on database schema. Inversion of Control Containers MicroKernel / Windsor Container Facilities Components Services contd...

Different projects under Castle General Tools Dynamic Proxy Aspect Oriented Programming AspectSharp

MonoRail MonoRail (formerly, Castle on Rails) is an MVC web framework inspired by Ruby on Rails. MonoRail differs from the standard WebForms way of development as it enforces separation of concerns; controllers just handle application flow, models represent the data, and the view is just concerned about presentation logic. Consequently, you write less code and end up with a more maintainable application. contd...

MonoRail – How it works

MVC in MonoRail MonoRail supports MVC out of the box. The following simple steps are needed to build a web application (that inherently uses the MVC pattern) - Map the extension.rails with IIS. Structure all the URLs as.../ /.rails e.g. Structure your (C#) projects and solutions as - All the controllers in the Controllers sub-directory. All the views (.aspx or.rails) under a Views sub-directory. All the Master Pages under the /Views/Layouts sub-directory. All the rescues in the /Views/Rescues sub-directory.

MonoRail Features Filters Filters are executed before and / or after your actions. It's useful for security, dynamic content and to keep away repetitive code. contd... namespace Yournamespace { public class SecurityFilter : IFilter { public bool Perform(ExecuteEnum exec, IRailsEngineContext context, Controller controller) { if (context.Session.Contains("user")) { return true; } else { context.Response.Redirect("account", "login"); } return false; }

MonoRail Features contd... [Filter(ExecuteEnum.BeforeAction, typeof(SecurityFilter))] public class HomeController : Controller { public void MyAction() { } [SkipFilter] public void SomeOtherAction() { }

MonoRail Features Rescues Rescue is a way to associate a nice page to display some nasty error information. contd... [Rescue("generalerror")] public class HomeController : Controller { public void Index() { } [Rescue("databaseerror")] public void Save() { }

MonoRail Features Layouts Layouts allow you to build templates for your site by specifying common HTML and controls (such as structural HTML and navigation controls), in one place, that are available for any view to use. NVelocity Layouts There are other features too like Data Binding, support for AJAX, JavaScript validations. Welcome! $childContent Footer

ActiveRecord ActiveRecord is a well-known pattern described in Patterns of Enterprise Application Architecture (by Martin Fowler). Basically all static methods act on the whole set of records, while instances represents each row. ActiveRecord is an implementation of the (above) ActiveRecord pattern for.Net. ActiveRecord uses NHibernate, but you don't need to write any fancy XML mapping as it handles everything for you. You just need to decorate your classes with attributes to declare behavior and meaning.

ActiveRecord vs. NHibernate How does it differ from pure NHibernate usage? Fast development (it handles the mapping and infers as much as it can so you don't have to dig into documentation or deal with tons of xmls everytime something changes on your schema). Predefined common methods like Create, Update, Save, Delete. Easy to implement methods like Find, FindAll, FindByName etc. Session and transaction scopes that abstract the (NHibernate) ISession and translates it to a more natural idiom.

ActiveRecord Generator ActiveRecord Generator is a desktop application that generates ActiveRecord classes (code) based on a database schema. It currently uses OleDb to extract the meta information and to infer the relationships. Currently works only with MS Sql Server.

Inversion of Control A principle that dictates how you design and implement system components and their interdependencies in a way that decreases coupling. A principle that dictates that an external entity should send messages to programmer's objects in order to perform some specialised action or to allow the programmer to override some logic. The major difference between an object-oriented framework and a class library is that the framework calls the application code. Normally the application code calls the class library. This inversion of control is sometimes named the Hollywood principle, Do not call us, we call You. contd...

MicroKernel / Windsor Container The MicroKernel offers an extensible inversion of control container core. The Windsor Container aggregates the MicroKernel providing a simpler interface and a set of important features that rely on MicroKernel extension points. The concern of the Windsor container is to offer a façade to the kernel and deal with external configuration, proxies and automatic component/facilities install.

How to use... NOTE: If you just need the container (no external configuration, no proxies) then MicroKernel is the right choice. However most common applications require the features that Windsor Container provides. The more straightforward usage is to instantiate the container and register the components: and then to get the component: IWindsorContainer container = new WindsorContainer(); container.AddComponent("mail", typeof(IMailServer), typeof(SmtpMailServer)); SmtpMailServer instance = container[“mail”] as SmtpMailServer;

Dynamic Proxy The DynamicProxy project was created to overcome the CLR's proxy (in)capabilities. There are proxies in the CLR world, but they can be considered a bit intrusive as it forces one to extend MarshalByRefObject or ContextBoundObject. DynamicProxy can be used to generate proxies on the fly for one or more interfaces or even concrete classes (but only virtual methods will be intercepted). To achieve good performance, DynamicProxy generates a Multicast delegate for each method that is going to be intercepted. Thus no invocation happens using reflection and delegates have an extremely good performance compared to reflection based invocations.

AspectSharp Aspect-oriented programming (AOP) is a new programming paradigm that allows modular implementation of crosscutting concerns. Aspect# is an AOP (Aspect Oriented Programming) framework for the CLI (.Net and Mono). It relies on DynamicProxy and offers a built-in language to declare and configure aspects, and is compliant with AopAlliance. Aspect# promotes - Separation of concerns Code reuse Decomposition

Related Links Castle Project Introducing Castle – 1 Introducing Castle – 2 I want my AOP (three part series) aspect.html