Fundamentals Table of Contents

Total Page:16

File Type:pdf, Size:1020Kb

Fundamentals Table of Contents Fundamentals Table of Contents 1. Fundamentals . 1 1.1. Other Guides . 1 2. Core Concepts . 2 2.1. Philosophy and Architecture . 2 2.2. Principles and Values . 12 2.3. Apache Isis vs … . 16 2.4. Deployment Options . 19 3. Building Blocks . 22 3.1. A MetaModel . 22 3.2. Type of Domain Objects . 22 3.3. Identifiers. 30 3.4. Object Members . 32 3.5. Events . 33 3.6. Modules . 35 4. Getting Started . 37 4.1. Prerequisites . 37 4.2. HelloWorld Archetype . 38 4.3. SimpleApp Archetype . 57 4.4. Datanucleus Enhancer . 66 5. Programming Model . 68 5.1. Domain Entities . 69 5.2. Domain Services . 73 5.3. Property . 80 5.4. Collections . 87 5.5. Actions . 89 5.6. Injecting services . 95 5.7. Properties vs Parameters . 97 5.8. View Models . 97 5.9. Mixins . 110 6. UI Hints . 117 6.1. Layout . 117 6.2. Object Titles and Icons . 117 6.3. Action Icons and CSS . 123 6.4. Names and Descriptions. 125 6.5. Eager rendering . 126 7. Object Management (CRUD) . 128 7.1. Instantiating . 128 7.2. Persisting . 129 7.3. Finding Objects . 130 7.4. Updating Objects . 131 7.5. Deleting Objects . 132 8. Business Rules . 133 8.1. Visibility ("see it"). 133 8.2. Usability ("use it") . 134 8.3. Validity ("do it") . 134 8.4. Actions . 135 8.5. Side effects . 135 9. Drop Downs and Defaults . 137 9.1. Choices and Default . ..
Recommended publications
  • Naked Objects: a Technique for Designing More Expressive Systems
    Naked objects: a technique for designing more expressive systems Richard Pawson Robert Matthews Computer Sciences Corporation NakedObjects.org and Computer Science Department, Tdnity College, Dublin, IE rpawson@csc;com ABSTRACT OOUIs provide a number of advantages to the user including Naked objects is an approach to systems design in which core reduced modality [6], and greater expressiveness for the user business objects show directly through to the user interface, and [10], and have become the norm for 'creative' applications such in which all interaction consists of invoking methods on those as drawing, computer aided design (CAD), page make-up and objects in the noun-verb style. One advantage of this approach multimedia editing. OOUIs are far less common in transactional is that it reaults in systems that arc more expressive from the business systems. This may be because the need for viewpoint of the user: they treat the user like a problem solver, expressiveness is less clear. It may also be because the not as merely a process-follower. Another advantage is that the underlying structure of most transactional business applications, 1:1 mapping between the user's representation and the comprising scripted procedures and data operations, does not underlying model means that it is possible to auto-generate the map well onto an OOUI. former from the latter, which yields benefits to the development Surprisingly, though, even where a transactional business process. The authors have designed a Java-based, open source system is based upon a true business object model, the core toolkit called Naked Objects which facilitates this style of business objects are typically hidden from the user.
    [Show full text]
  • Design Patterns Design Patterns
    Design Patterns CSC207 – Software Design Design Patterns • Design pattern: – A general description of the solution to a well- established problem using an arrangement of classes and objects. • Patterns describe the shape of code rather than the details. – There are lots of them in CSC 301 and 302. Loop patterns from first year • Loop pattern: – A general description of an algorithm for processing items in a collection. • All of you (hopefully) have some loop patterns in your heads. • You don’t really need to think about these any more; you just use them, and you should be able to discuss them with your fellow students. • Some first-year patterns: – Process List – Counted Loop – Accumulator – Sentinel Process list pattern • Purpose: to process every item in a collection where you don’t care about order or context; you don’t need to remember previous items. • Outline: • Example: • Other example: darken every pixel in a picture Counted loop pattern • Purpose: to process a range of indices in a collection. • Outline: • Example: • Other example: print indices of even-length string Accumulator pattern • Purpose: to accumulate information about items in a collection. • Outline: • Example: • Other examples: sum, min, accumulate a list of items meeting a particular criterion. Sentinel pattern • Purpose: to remove a condition in a loop guard. • Outline: • Example: Sentinel pattern, continued • Here is the code that Sentinal replaces; note that i != list.size() is evaluated every time through the loop, even though it is false only once. Design Pattern
    [Show full text]
  • Presentación De Powerpoint
    Software Architecture of Oviedoof University Modularity Science Computer of of Course 2018/2019 Jose E. Labra Gayo School Software Software School of Computer Science University of Oviedo Modularity Architecture Software Architecture of Oviedoof University Big Ball of Mud Modular decomposition Definitions Recommendations Modularity styles Layers Aspect Oriented decomposition Domain based decomposition Science Computer of of School Software Architecture Big Ball of Mud of Oviedoof Big Ball of Mud University Described by Foote & Yoder, 1997 Elements Lots of entities intertwined Constraints None Science Computer of of School Software Architecture Big Ball of Mud of Oviedoof Quality attributes (?) University Time-to-market Quick start It is possible to start without defining an architecture Incremental piecemeal methodology Solve problems on demand Cost Cheap solution for short-term projects Science Computer of of School Software Architecture Big Ball of Mud of Oviedoof Problems University High Maintenance costs Low flexibility at some given point At the beginning, it can be very flexible After some time, a change can be dramatic Inertia When the system becomes a Big Ball of Mud it is very difficult to convert it to another thing A few prestigious developers know where to touch Science Clean developers run away from these systems Computer of of School Software Architecture Big Ball of Mud of Oviedoof Some reasons University Throwaway code: You need an immediate fix for a small problem, a quick prototype or proof of concept When it is good
    [Show full text]
  • Full-Graph-Limited-Mvn-Deps.Pdf
    org.jboss.cl.jboss-cl-2.0.9.GA org.jboss.cl.jboss-cl-parent-2.2.1.GA org.jboss.cl.jboss-classloader-N/A org.jboss.cl.jboss-classloading-vfs-N/A org.jboss.cl.jboss-classloading-N/A org.primefaces.extensions.master-pom-1.0.0 org.sonatype.mercury.mercury-mp3-1.0-alpha-1 org.primefaces.themes.overcast-${primefaces.theme.version} org.primefaces.themes.dark-hive-${primefaces.theme.version}org.primefaces.themes.humanity-${primefaces.theme.version}org.primefaces.themes.le-frog-${primefaces.theme.version} org.primefaces.themes.south-street-${primefaces.theme.version}org.primefaces.themes.sunny-${primefaces.theme.version}org.primefaces.themes.hot-sneaks-${primefaces.theme.version}org.primefaces.themes.cupertino-${primefaces.theme.version} org.primefaces.themes.trontastic-${primefaces.theme.version}org.primefaces.themes.excite-bike-${primefaces.theme.version} org.apache.maven.mercury.mercury-external-N/A org.primefaces.themes.redmond-${primefaces.theme.version}org.primefaces.themes.afterwork-${primefaces.theme.version}org.primefaces.themes.glass-x-${primefaces.theme.version}org.primefaces.themes.home-${primefaces.theme.version} org.primefaces.themes.black-tie-${primefaces.theme.version}org.primefaces.themes.eggplant-${primefaces.theme.version} org.apache.maven.mercury.mercury-repo-remote-m2-N/Aorg.apache.maven.mercury.mercury-md-sat-N/A org.primefaces.themes.ui-lightness-${primefaces.theme.version}org.primefaces.themes.midnight-${primefaces.theme.version}org.primefaces.themes.mint-choc-${primefaces.theme.version}org.primefaces.themes.afternoon-${primefaces.theme.version}org.primefaces.themes.dot-luv-${primefaces.theme.version}org.primefaces.themes.smoothness-${primefaces.theme.version}org.primefaces.themes.swanky-purse-${primefaces.theme.version}
    [Show full text]
  • JDO Getting Started Guide (V5.0) Table of Contents
    JDO Getting Started Guide (v5.0) Table of Contents Key Points. 2 Understanding the JARs . 3 JDO Tutorial (v5.0) . 4 Background . 4 Step 0 : Download DataNucleus AccessPlatform . 4 Step 1 : Take your model classes and mark which are persistable . 4 Step 2 : Define the 'persistence-unit' . 7 Step 3 : Enhance your classes . 8 Step 4 : Write the code to persist objects of your classes . 10 Step 5 : Run your application . 12 Step 6 : Controlling the schema . 14 Step 7 : Generate any schema required for your domain classes . 17 Any questions? . 18 Developing applications is, in general, a complicated task, involving many components. Developing all of these components can be very time consuming. The Java Data Objects API (JDO) was designed to alleviate some of this time spent, providing an API to allow java developers to persist object-oriented data into any database, and providing a query language using the same Java syntax as the developer is already familiar with. DataNucleus JDO provides an implementation of this JDO standard, allowing you, the user, to persist your object-oriented data to not only the RDBMS datastores the standard was intended for, but also to a wide range of other datastores. These include popular map stores such as Cassandra and HBase, the Neo4j graph store, spreadsheets in Excel or OpenDocument formats, JSON formatted Amazon and Google Storage options, the popular MongoDB JSON-like document store, as well as ubiquitous LDAP and more besides. DataNucleus doesn’t purport to be the best solution to every problem. For example, where you want to bulk persist large amounts of data then other solutions that get closer to the datastore API would be more appropriate.
    [Show full text]
  • A Project to Model-Driven Development with Naked Objects and Domain-Driven Design
    Elihu: A Project to Model-Driven Development with Naked Objects and Domain-Driven Design Samuel Alves Soares1 and Mariela Ines´ Cortes´ 2 1Federal Institute of Education, Science and Technology of Ceara,´ Taua,´ Ceara,´ Brazil 2State University of Ceara,´ Fortaleza, Ceara,´ Brazil Keywords: Model Driven Development, Naked Objects, Domain Driven Design, Domain Patterns, Design Patterns. Abstract: The model-driven development is a approach to creating software through well-defined models containing the information needed to generate the application. However, the software modeling in this approach requires the definition of application infrastructure artifacts in the model, such as user interface technologies and data persistence scheme, in order to transform modeling in final application. This makes the modeling complex, difficult to understand and maintain since new artifacts need to be added, failing to keep the focus on application business domain. To resolve this problem, we propose the Elihu project, a solution based on Naked Objects Pattern, Domain-Driven Design and software design patterns where the developer models just business objects and their characteristics related to the application domain. The full application is generated based on these software patterns and a Naked Objects Pattern framework is responsible for the application infrastructure code and the display of objects to users. The proposed solution benefits the creation of less complex models, that support evolution and modification of requirements along the development and the generation of full applications without manual intervention in the generated code. 1 INTRODUCTION 2006). On the other hand, the ambiguous nature of models and information redundancy along different The focus on the problem domain is pointed views of the same object make it difficult to maintain out as the ideal approach to the development of and make it difficult to adopt the MDD in the industry computer systems (Pawson, 2004).
    [Show full text]
  • Pawson Thesis.Pdf
    Naked objects A thesis submitted to the University of Dublin, Trinity College for the degree of Doctor of Philosophy Richard Pawson, Department of Computer Science, Trinity College, Dublin June 2004 1 Foreword by Trygve Reenskaug (Author’s note: Prof. Reenskaug was the external examiner for this thesis. One of the pioneers of object-oriented programming, he is best known as the inventor of the Model- View-Controller pattern. After the thesis was accepted, he generously agreed to write a foreword to the electronically-published version.) The world’s shipbuilding industry went through a heavy modernization program through the nineteen fifties and sixties. My colleague Kjell Kveim invented a control unit for the numerical control of machine tools such as flame cutters. The first unit was installed at the Stord shipyard in 1960 and opened the field for integrated computer aided design and manufacturing. The matching design system, Autokon, was first deployed at the Stord Yard in 1963. Autokon was subsequently adopted by most major shipyards around the world and was still in use by the late nineties. The purpose of Autokon was to empower the ship’s designers. It had a central database holding important information about the shape of the hull, the position of frames and decks, and the shapes of the parts. There was a language that permitted the designers to specify parts in shipbuilding terminology. There was a designer programming facility so that they could specify families of similar parts. Autokon was developed in close collaboration between shipbuilders and scientists. We considered ourselves as tool builders; the success criterion was that the tools should be handy, practicable, serviceable and useful.
    [Show full text]
  • Domain-Driven Design Using Naked Objects
    Extracted from: Domain-Driven Design Using Naked Objects This PDF file contains pages extracted from Domain-Driven Design, published by the Pragmatic Bookshelf. For more information or to purchase a paperback or PDF copy, please visit http://www.pragprog.com. Note: This extract contains some colored text (particularly in code listing). This is available only in online versions of the books. The printed versions are black and white. Pagination might vary between the online and printer versions; the content is otherwise identical. Copyright © 2009 The Pragmatic Programmers, LLC. All rights reserved. No part of this publication may be reproduced, stored in a retrieval system, or transmitted, in any form, or by any means, electronic, mechanical, photocopying, recording, or otherwise, without the prior consent of the publisher. Many of the designations used by manufacturers and sellers to distinguish their prod- ucts are claimed as trademarks. Where those designations appear in this book, and The Pragmatic Programmers, LLC was aware of a trademark claim, the designations have been printed in initial capital letters or in all capitals. The Pragmatic Starter Kit, The Pragmatic Programmer, Pragmatic Programming, Pragmatic Bookshelf and the linking g device are trademarks of The Pragmatic Programmers, LLC. Every precaution was taken in the preparation of this book. However, the publisher assumes no responsibility for errors or omissions, or for damages that may result from the use of information (including program listings) contained herein. Our Pragmatic courses, workshops, and other products can help you and your team create better software and have more fun. For more information, as well as the latest Pragmatic titles, please visit us at http://www.pragprog.com Copyright © 2009 Dan Haywood.
    [Show full text]
  • Object-Oriented Programming (VB Version)
    Object-Oriented Programming (VB version) by Richard Pawson v1.0.0 ©Richard Pawson, 2020. The moral right of the author has been asserted. This document is distributed under a Creative Commons Attribution-NonCommercial-NoDerivatives 4.0 International License: https://creativecommons.org/licenses/by-nc-nd/4.0/. The author is willing, in principle, to grant permission for distribution of derivative versions, on a case by case basis, and may be contacted as [email protected]. ‘Metal Up’ is a registered trademark, number UK00003361893. Author’s acknowledgements I am indebted to John Stout who has acted as a continuous reviewer throughout the writing of this book, offering many corrections and improvements to both text and program code. Responsibility for any remaining errors remains mine alone – please report any that you find to me as [email protected]. Foreword by Alan Kay In my first day in grad school in 1966, the head of the department gave me a thesis from just a few years earlier: “Sketchpad: A Man-Machine Communications System” by Ivan Sutherland at MIT. It completely turned upside down my ideas about computing. It was not just the invention of interactive computer graphics, but also allowed the user to define complex “Ideas” — such as beams for a bridge, rivets, transistors, linkages, text characters, and much more — produce as many “instances” of each Idea as needed to make more complex assemblies (which could themselves be turned into Ideas) — then use goal-solving graphical programming to give the Ideas dynamic relationships and larger simulation behaviors. For example, you could define a beam as being like a stiff spring, use many instances of them to make a bridge, hang simulated weights from the bridge, and Sketchpad would dynamically compute the tensions and compressions on the beams and show these numerically — all without the system knowing anything about beams or bridges, or even the numeral forms for numbers ahead of time.
    [Show full text]
  • Architectural Styles and Patterns
    Architectural Styles and Patterns Wednesday 13 February 13 Architectural Patterns & Styles Consensus Controversy • Established • Philosophy (context- Solutions problem-solution vs components- Common • connections) vocabulary Granularity (vs Document • • Design patterns) Reason over quality • • Categorization Wednesday 13 February 13 Architectural Patterns (Wikipedia) • Presentation- abstraction- • Peer-to-peer control • Service-oriented • Three-tier architecture • Pipeline • Naked Objects Implicit Invocation • Model-View • Controller • Blackboard Wednesday 13 February 13 Architectural Patterns (Shaw & Garland) • Dataflow Systems -- Batch, Pipes and Filters • Call-and-return systems -- Main program and subroutines, OO systems, Hierarchical Layers • Independent components -- Communicating processes, Event systems • Virtual Machines -- Interpreters, Rule-based systems • Data-Centered Systems -- Databases, Hypertext systems Blackboards Wednesday 13 February 13 Elements of Architecture (Shaw & Garland) Components Connectors • Clients • Procedure calls • Servers • Events broadcast • Filters • Database protocols • Layers • Pipes • Databases - What are the structural patterns permitted? - What is the underlying computational model? - What are the invariants of the style? BUT ... - What are examples of its use? - What are the tradeoffs? - ... Wednesday 13 February 13 Architectural Patterns (Baas, Clements & Kazman) • Dataflow Systems -- Batch, Pipes and Filters • Data-Centered -- Repository, Blackboard • Virtual machine -- Interpreter, Rule-based
    [Show full text]
  • Object Thinking
    PUBLISHED BY Microsoft Press A Division of Microsoft Corporation One Microsoft Way Redmond, Washington 98052-6399 Copyright © 2004 by David West All rights reserved. No part of the contents of this book may be reproduced or transmitted in any form or by any means without the written permission of the publisher. Library of Congress Cataloging-in-Publication Data pending. Printed and bound in the United States of America. 1 2 3 4 5 6 7 8 9 QWE 8 7 6 5 4 3 Distributed in Canada by H.B. Fenn and Company Ltd. A CIP catalogue record for this book is available from the British Library. Microsoft Press books are available through booksellers and distributors worldwide. For further information about international editions, contact your local Microsoft Corporation office or contact Microsoft Press International directly at fax (425) 936-7329. Visit our Web site at www.microsoft.com/mspress. Send comments to [email protected]. Microsoft, Visual Basic, Visual C++, Visual C#, Visual Studio, and Windows are either registered trademarks or trademarks of Microsoft Corporation in the United States and/or other countries. Other product and company names mentioned herein may be the trademarks of their respective owners. The example companies, organizations, products, domain names, e-mail addresses, logos, people, places, and events depicted herein are fictitious. No association with any real company, organization, product, domain name, e-mail address, logo, person, place, or event is intended or should be inferred. This book expresses the author’s views and opinions. The information contained in this book is provided without any express, statutory, or implied warranties.
    [Show full text]
  • Java LDAP Persistence with Datanucleus
    Java LDAP Persistence with DataNucleus Stefan Seelmann [email protected] Java LDAP Persistence with DataNucleus • Stefan Seelmann • Freelancer – Software Development with Java – LDAP, Identity- and Access-Management • Open Source Developer – Apache Directory Project – DataNucleus LDAP Store Java LDAP Persistence with DataNucleus Agenda • Motivation • Java Persistence, JDO and DataNucleus • Basic Demo • DataNucleus LDAP Store • Advanced Demo • Status and Conclusion Java LDAP Persistence with DataNucleus Java LDAP Development • Java APIs for LDAP – Mature: Netscape LDAP SDK, JLDAP (Novell/OL) – Modern: Unbound ID, Apache Directory, OpenDS • Hopefully a common Java LDAP API soon? – JNDI, Spring-LDAP • Drawback: – Developer has to deal with LDAP • DN, RDN, filters, modification items, error codes – Boiler-Plate code, exception handling Java LDAP Persistence with DataNucleus Java Persistence • Standards – JPA (Java Persistence API): JSR 220, RDBMS only – SDO (Service Data Objects): JSR 235 – JDO: (Java Data Object): JSR-12 and JSR-243 • Products – O/R Mapper: Hibernate, TopLink/EclipseLink, ... – Apache iBATIS, Cayenne, OpenJPA, Tuscany, ... – DataNucleus – ... Java LDAP Persistence with DataNucleus JDO • Java-centric API to access persistent data • Datastore independent • Started by Sun, now driven by Apache JDO • Versions 1.0, 2.0, 2.1, 2.2, 2.3 in progress • Three main parts – Persistence definition (metadata) – Persistence API – Query language/API Java LDAP Persistence with DataNucleus DataNucleus • Reference implementation of JDO • Apache
    [Show full text]