CILY Final Report Jiwan Choi Edward Ishak Jonathan Liu Makiko Yasui 2 Table of Contents 1 Introduction 5 1 1 Overview of CILY 1 2 Background Related Work 1 3 Motivations for the Language 1 4 Goals for the Language 1 5 Features 1 6 Model of Computation 2 CILY Tutorial 10 2 1 Introduction 2 2 First Example of Basic CILY Syntax 2 3 Automation Using foreach Loops 2 4 CILY s Webpage Automation 3 Language Reference Manual 14 3 1 Introduction 3 2 Syntax Notation of CILY LRM 3 3 Lexical Conventions 3 3 1 Programs 3 3 2 Separators 3 3 3 Types of Tokens 3 4 Storage Class Types 3 4 1 Storage Class 3 4 2 Primitive Types 3 4 3 Built in Types 3 4 4 Derived Types 3 5 Variables 3 5 1 Variable Categories 3 5 2 Default Values 3 6 Conversions 3 6 1 Integer to Double Implicit Conversion 3 6 2 Explicit Conversions 3 7 Expressions 3 7 1 Left Value Primary Expressions 3 7 2 Right Value Primary Expressions 3 7 3 Unary Operators 3 7 4 Arithmetic Operators 3 7 5 Relational Operators 3 7 6 Equality Operators 3 7 7 Local Operators 3 7 8 Assignment Operators 3 7 9 Constant Expressions 3 3 8 Declarations 3 8 1 Variable declaration 3 8 2 Array declaration 3 8 3 Const declaration 3 9 Blocks and Statements 3 9 1 Declaration statements 3 9 2 Assignment statements 3 9 3 Functioncall statements 3 9 4 Selection statements 3 9 5 Iteration statements 3 9 6 Return statements 3 9 7 Block statements 3 10 Functions 3 10 1 Function definition 3 10 2 Library Functions 3 11 Lexical Scope Appendix CILY Grammar 4 Project Plan 44 4 1 Organization of the project processes 4 1 1 Planning 4 1 2 Developing 4 1 3 Testing 4 2 Roles and Responsibilities 4 3 Programming Style Guide 4 3 1 Introduction to Coding Standards 4 3 2 ANTLR Style Guide 4 3 3 Java Style Guide 4 4 Software Development Environment 4 5 Project Timeline 4 6 Project Log 5 Architectural Design 50 5 1 Design of CILY Compiler 5 1 1 Overview 5 1 2 CILY Lexer 5 1 3 CILY Parser 5 1 4 AST Parser 5 1 5 Symbol Table 5 1 6 Error Checker 5 1 7 Code Generator 5 1 8 CILY Library 5 2 Input and Output 5 3 Error Handling 5 3 1 Error Checking 5 3 2 Error Response 5 3 3 Error Recovery 5 4 Interaction Between Components 4 6 Test Plan 55 6 1 Expectations 6 2 Testing Strategy 6 3 Three stage Testing 6 3 1 Stage 1 Syntax Lexer and Parser 6 3 2 Stage 2 Semantics Semantic Analyzer and Symbol Table 6 3 3 Stage 3 Final Test Phase More Complex Programs 6 4 Automation 6 5 Implementation 6 6 Individual Responsibilities 7 Lessons Learned 60 7 1 Jiwan Choi 7 2 Edward Ishak 7 3 Makiko Yasui 7 4 Jonathan Liu 8 Appendix 62 5 Chapter 1 Introduction 1 1 Overview of CILY In the computer industry s recent progression there has been a shift from a textbased world to a graphical based one Users would rather see pictures images and fancy graphics rather than just textual information Until recently manipulating images was a very expensive operation It required a lot of space computer time and even user time Graphics artists today still have to invoke an interactive application such as Adobe Photoshop in order to change colors brightness scale etc The Choi Ishak Lui Yasui CILY pronounced silly Programming Language is designed to give the user the ability to programmatically manipulate 2D images The language gives the user flexibility to perform a broad range of procedures by supporting large scale batch operations and also allowing the programmer to automate these processes This dramatically saves valuable user time and allows quick preparation of images for a wide range of uses CILY even provides an automated set of procedures to dynamically produce web sites for image viewing CILY is a safe programming language automatically taking care of memory management and garbage collection It is robust scalable and very intuitive to use Overall CILY will dramatically increase user productivity and programmers world wide will be asking Why didn t we have this available before 1 2 Background Related Work As electronic services such as e mail and e commerce became vital parts of our lives the World Wide Web has shifted from a text based user interface to a graphics based one Websites with graphical components help users navigate and visualize their needs and desires effortlessly Consequently the computer industry has produced many applications for image manipulation and website development Adobe Photoshop and Macromedia Dreamweaver are two commonly used applications that are widely used by web developers around the world 6 Photoshop s primary tools are the image manipulation options it offers In web development today image manipulation such as a simple resizing or a more complex brightness contrast control is an essential part of creating user friendly and visually pleasing interfaces Furthermore it is very likely that mass image manipulation is needed to create a website Photoshop provides this mass image manipulation functionality called batch processing Using batch processing the user can record a series of actions performed on one image and subsequently apply the same exact series of actions on a directory of images Macromedia s Dreamweaver is an application that generates actual HTML code for a website Dreamweaver made it possible for all users even those with little knowledge of HTML to create a website without any difficulty by making the interface graphical At the same time it allows advanced users to hardcode HTML Similar to Photoshop Dreamweaver allows mass file manipulations For example the users can create a template page and apply the template on numerous pages to put these files in the same format Although these two applications and many others help web developers in mass image manipulation and mass HTML file manipulation there are limitations these processes Once the user decides on the set of actions for batch processing or a template for a web page the user cannot add extra specifications according to the properties of each image or each web page CILY combines the basic functionalities of these two applications without these limitations 1 3 Motivations for the Language The users of CILY will appreciate the rich set of features offered in the language over other interactive image manipulation applications such as Photoshop Dreamweaver and PhotoEditor because it combines many of their functionalities and creates a new tool that extends image manipulation and web development in a new direction The function calls and primitive data types are intuitive yet powerful allowing both novice and advanced
View Full Document
Unlocking...