API-Application Programming Interface Presented By: Konkani NLP Team Goa University.

Slides:



Advertisements
Similar presentations
Connecting to Databases. relational databases tables and relations accessed using SQL database -specific functionality –transaction processing commit.
Advertisements

Chapter 10: Designing Databases
Database System Concepts and Architecture
File Management Chapter 12. File Management File management system is considered part of the operating system Input to applications is by means of a file.
Chapter Information Systems Database Management.
File Management Systems
1 SWE Introduction to Software Engineering Lecture 22 – Architectural Design (Chapter 13)
10.1 Silberschatz, Galvin and Gagne ©2005 Operating System Principles Chapter 10: File-System Objectives To discuss file-system design tradeoffs, including.
1 Foundations of Software Design Lecture 27: Java Database Programming Marti Hearst Fall 2002.
Naming Names in computer systems are used to share resources, to uniquely identify entities, to refer to locations and so on. An important issue with naming.
Operating Systems Concepts 1. A Computer Model An operating system has to deal with the fact that a computer is made up of a CPU, random access memory.
C o n f i d e n t i a l Developed By Nitendra NextHome Subject Name: Data Structure Using C Title: Overview of Data Structure.
A GUIDE TO SHAREPOINT 2007 CUSTOMIZATION OPTIONS Heather Solomon, WSS MVP.
2. Introduction to the Visual Studio.NET IDE 2. Introduction to the Visual Studio.NET IDE Ch2 – Deitel’s Book.
DHTML. What is DHTML?  DHTML is the combination of several built-in browser features in fourth generation browsers that enable a web page to be more.
Classes and objects Practice 2. Basic terms  Classifier is an element of the model, which specifies some general features for a set of objects. Features.
Introduction to Object-oriented Programming CSIS 3701: Advanced Object Oriented Programming.
CSCI 6962: Server-side Design and Programming
Database System Concepts and Architecture Lecture # 3 22 June 2012 National University of Computer and Emerging Sciences.
Copyright © 2003 by Prentice Hall Computers: Tools for an Information Age Chapter 13 Database Management Systems: Getting Data Together.
PHP Programming with MySQL Slide 8-1 CHAPTER 8 Working with Databases and MySQL.
Implementation Yaodong Bi. Introduction to Implementation Purposes of Implementation – Plan the system integrations required in each iteration – Distribute.
Chapter 1. Introduction.
Information Systems: Databases Define the role of general information systems Describe the elements of a database management system (DBMS) Describe the.
Chapter 7 Working with Databases and MySQL PHP Programming with MySQL 2 nd Edition.
Object Oriented Analysis & Design & UML (Unified Modeling Language)1 Part V: Design The Design Workflow Design Classes Refining Analysis Relationships.
CSCI 6962: Server-side Design and Programming Database Manipulation in ASP.
1 File Management Chapter File Management n File management system consists of system utility programs that run as privileged applications n Concerned.
COMP201 Java Programming Topic 15: Database Connectivity JDBC Reading: Chapter 4, Volume 2.
The Digital Archive Database Tool Shih Lin Computing Center Academia Sinica.
By N.Gopinath AP/CSE Cognos Impromptu. What is Impromptu? Impromptu is an interactive database reporting tool. It allows Power Users to query data without.
1. 2 Preface In the time since the 1986 edition of this book, the world of compiler design has changed significantly 3.
IndoWordNet Database Design Presented By: Konkani NLP Team Goa University IndoWordNet Database Design 1.
User Profiling using Semantic Web Group members: Ashwin Somaiah Asha Stephen Charlie Sudharshan Reddy.
DATABASE CONNECTIVITY TO MYSQL. Introduction =>A real life application needs to manipulate data stored in a Database. =>A database is a collection of.
CE Operating Systems Lecture 17 File systems – interface and implementation.
NMD202 Web Scripting Week5. What we will cover today PHP & MySQL Displaying Dynamic Pages Exercises Modifying Data PHP Exercises Assignment 1.
SQL Based Knowledge Representation And Knowledge Editor UMAIR ABDULLAH AFTAB AHMED MOHAMMAD JAMIL SAWAR (Presented by Lei Jiang)
Object storage and object interoperability
Basics of JDBC Session 14.
© 2012 LogiGear Corporation. All Rights Reserved FitNesseFitNesse Authors: Nghia Pham 1.
Copyright (c) 2014 Pearson Education, Inc. Introduction to DBMS.
Introduction to Databases Angela Clark University of South Alabama.
JDBC Java and Databases. SWC – JDBC JDBC – Java DataBase Connectivity An API (i.e. a set of classes and methods), for working with databases in.
2) Database System Concepts and Architecture. Slide 2- 2 Outline Data Models and Their Categories Schemas, Instances, and States Three-Schema Architecture.
ORM Basics Repository Pattern, Models, Entity Manager Ivan Yonkov Technical Trainer Software University
Ontology Technology applied to Catalogues Paul Kopp.
Building Preservation Environments with Data Grid Technology Reagan W. Moore Presenter: Praveen Namburi.
DBS201: Data Modeling. Agenda Data Modeling Types of Models Entity Relationship Model.
By ILTAF MEHDI (MCS, MCSE, CCNA) 1 Remember: Examination is a chance not ability. 6/12/2016.
 Project Team: Suzana Vaserman David Fleish Moran Zafir Tzvika Stein  Academic adviser: Dr. Mayer Goldberg  Technical adviser: Mr. Guy Wiener.
A Presentation Presentation On JSP On JSP & Online Shopping Cart Online Shopping Cart.
ISC321 Database Systems I Chapter 2: Overview of Database Languages and Architectures Fall 2015 Dr. Abdullah Almutairi.
CS 562 Advanced Java and Internet Application Computer Warehouse Web Application By Team Alpha :-  Puja Mehta (102163)  Mona Nagpure (102147)
The Bookstore Problem. Contents I.Problem Description II.Solution III.Exercise.
DHTML.
System Design.
Chapter 12 Information Systems.
Chapter 2 Database Environment.
MANAGING DATA RESOURCES
Chapter 8 Working with Databases and MySQL
GEOMATIKA UNIVERSITY COLLEGE CHAPTER 2 OPERATING SYSTEM PRINCIPLES
Database Fundamentals
Data Model.
Introduction of Week 11 Return assignment 9-1 Collect assignment 10-1
DATABASES WHAT IS A DATABASE?
Database & Information Systems
Understanding Core Database Concepts
CMPE/SE 131 Software Engineering March 7 Class Meeting
Unit – V Data Controls.
Presentation transcript:

API-Application Programming Interface Presented By: Konkani NLP Team Goa University

Brief Outline API’s  IndoWordNet API  Layers of API  Sample API codes

API’s An Application Programming Interface (API) is a set of commands, functions and protocols which programmers can use when building a software. It allows the programmers to use predefined functions to interact with systems, instead of writing them from scratch. Characteristics of good API – Easy to learn and use, Hard to misuse. – Easy to read and maintain code that uses it. – Is programming language neutral. – Sufficiently powerful to support all computational requirements. IndoWordNet Database Design3

IndoWordNet API It allows a user to access wordnet database and to create wordnet tools without the knowledge of the underlying database design. The API is object-oriented design. The API is designed in such a way that it supports single/ multiple languages. The API is designed in two layers: – Application layer – Database layer IndoWordNet Database Design4

Implementation of API’s is done in:  JAVA  Php

Database layer The Database layer deals with encapsulation of the database design. It provides a standard interface to the application layer. The Database layer supports all the operations needed to be performed on the database. IndoWordNet Database Design6

Database Layer consists of the following classes: – IWDb A class that connects to the Database. – IWCon A class that sets up a connection to a database – IWStatement A class which contains all the queries pertaining to the application layer Also the basic functions such as updating, deletion, insertion, selection, etc. – IWResult A class which returns results to the application layer, the results of executed queries IndoWordNet Database Design7

Application layer The Application layer incorporates the logical part of the IndoWordNet requirements, so as to provide classes and objects to perform all the operations to be performed on the synset, relations, ontology, other master data, etc. The Application Layer allows us to perform operations such as: – get all the synsets – get all words – get all synsets from a given start id to a given end id – get various relations for a given synset/ word – get words for a given synset – add a new source or domain, a new relation – to create sysnet, to create words, – update the records in the table – delete a synset/ source/ domain – modify ontology information – Etc… IndoWordNet Database Design8

Application Layer consists of the following classes: – IWAPIClass A class that allows to initialise API library for use. Maintain master tables. Manage connectivity to language specific databases. – IWSynset A class that represents a Synset – IWWord A class that represents a Word – IWSynsetCollection Collection of Synsets – IWWordCollection Collection of words for a synset – IWOntology A class that represents Ontology Each synset is mapped into some place in the ontology tree IndoWordNet Database Design9

– IWOntologyCollection Collection of child nodes for a given onto node – IWExampleCollection Collection of examples – IWFile A class that represents a File – IWDataFile A class that represents a data file – IWPictureFile A class that represents a picture files – IWFileCollection Collection of files IndoWordNet Database Design10

Where to copy the API sample codes – For java: Open the sampleCodesInJava folder in Netbeans and import the libraries from the lib folder. – For Php: Copy the sampleCodesInPhp Folder in htdocs and open it in Netbeans IndoWordNet Database Design11

IWAPIClass – A class that allows initialising API library for use, – Maintains master tables, – Manage connectivity to language specific databases, – A class that allows to get all synsets from the database, – It consists of all the language database names, the various antonymy property values, meronymy_holonymy property values, etc... – To create new synsets, – To get synsets belonging to a domain, – To get synset belonging to a grammatical category, – To get synsets belonging to a given source, – To get synsets for a given range of Id’s, – To get all files, – To create a new word, new source, new domain, new category, etc… – To destroy a synset, word, relation, – Etc…

The object of the IWAPIClass is declared as follows: In Java: IWAPIClass apiObject = new IWAPIClass("root", ""); IWDb dbObj = apiObject.connectLanguageDb(IWAPIClass.KONKANI); In Php:$apiObject = new IWAPIClass("root", ""); $dbObj = $apiObject->connectLanguageDb(IWAPIClass::$KONKANI); Where “root” is the username of the database, password is “”. It will connect to the master database.

IWSynset – A class that represents a Synset. – To get the concept, translated concept, transliterated concept of a given synset which is present in the database. – To get words and relations of a given synset. – To get examples belonging to a synset. – To get the category, domain, source, concept of a given synset present in the database. – To add examples, files and various semantic relations to a synset. – To remove semantic relations. – To set a new concept, a new category, a new domain for a synset. – Etc…

The object of the IWSynset is declared as follows: In Java:IWSynset synsetObject = new IWSynset (dbObject, synset_id); In Php:$synsetObject = new IWSynset ($dbObject, $synset_id);

IWSynsetCollection – A class that represent a Collection of Synset. – To get the length of the collection i.e the number of synsets present in the collection, use length(); – To get the first element from the collection, the next element from the collection, the previous element from the collection and the last element from the collection, use first(); next(); previous(); last(); respectively. – To get the current element, use getElement();

IWWord – A class that represents a Word. – To get various lexical relation such as antonymy relation, compounding relation, gradation relation, etc. – To get all the synsets for a given word. – To get the lex id. – To remove lexical relations for specified synset and word. – Etc…

IWWordCollection – A class that represent a Collection of words for a synset. – To get the length of the collection i.e the number of words present in the collection, use length(); – To get the first element from the collection, the next element from the collection, the previous element from the collection and the last element from the collection, use first(); next(); previous();and last(); respectively. – To get the current element, use getElement();

IWExampleCollection – Collection of examples for a synset. – To get the length of the collection i.e the number of examples present in the collection, use length(); – To get the first element from the collection, the next element from the collection, the previous element from the collection and the last element from the collection, use first(); next(); previous();and last(); respectively. – To get the current element, use getElement();

IWOntology – A class that represents Ontology node. – Each synset is mapped into some place in the ontology tree. – To get ontology Id, use getOntologyID(); – To get ontology data, ontology translated data, ontology transliterated data, use getOntologyData(); getOntologyTranslatedData(); and getOntologyTransliteratedData(); – To get ontology description, ontology translated description, ontology transliterated description, use getOntologyDescription(); getOntologyTranslatedDescription(); and getOntologyTransliteratedDescription(); – To set ontology data, ontology translated data, ontology transliterated data, use setOntologyData(); setOntologyTranslatedData(); and setOntologyTransliteratedData(); – To set ontology description, ontology translated description, ontology transliterated description, use setOntologyDescription(); setOntologyTranslatedDescription(); and setOntologyTransliteratedDescription(); – Etc…

IWOntologyCollection – Collection of child nodes for a given onto node. – To get the length of the collection i.e the number of ontology nodes present in the collection, use length(); – To get the first element from the collection, the next element from the collection, the previous element from the collection and the last element from the collection, use first(); next(); previous();and last(); respectively. – To get the current element, use getElement();

IWFile – A class that represents Files. – To get the file content, to get the file Id, to get file size, to get file type. – To set a new file type, to set a new file name. – Etc...

IWFileCollection – Collection of files. – To get the length of the collection i.e the number of files in the collection, use length(); – To get the first element from the collection, the next element from the collection, the previous element from the collection and the last element from the collection, use first(); next(); previous();and last(); respectively. – To get the current element, use getElement();

IWAntonymyCollection – Collection of words belonging to a synset having antonymy relation for a given synset and lex words. – To get the length of the collection i.e the number of antonymy relation for a given synset and lex word present in the collection, use length(); – To get the first element from the collection, the next element from the collection, the previous element from the collection and the last element from the collection, use first(); next(); previous(); and last(); respectively. – To get the current element, use getElement(); – To get anto word and anto synset use getAntoWord(); and getAntoSynset(); respectively. – To get the antonymy property value, use getAntonymyValue();

IWGradationCollection – A collection of gradation relation obtained for a given synset and lex words. – To get the gradation property for a given synset and lex words, use getGradationValue(); – To get the length of the collection i.e the number of gradation relation for a given synset and lex word present in the collection, use length(); – To get the first element from the collection, the next element from the collection, the previous element from the collection and the last element from the collection, use first(); next(); previous(); and last(); respectively. – To get the current element, use getElement(); – To get the mid lex word and to get the last lex word use getMidLexWord(); and getLastLexWord(); respectively. – To get the mid synset and to get the last synset use getMidSynset(); and getLastSynset(); respectively.

IWLexicalRelationCollection – Collection of Lexical relation for a given word. – The different types of lexical relations are: antonymy (opposites), gradation, compounding, conjunction, etc. – To get the length of the collection using length(); – To get the first element from the collection, the next element from the collection, the previous element from the collection and the last element from the collection, use first(); next(); previous(); and last(); respectively. – To get the current element, use getElement(); – To get the lex word and synset id, use getLexWord(); and getSynsetID() respectively.

IWMeroHoloCollection – Collection of Meronymy Holonymy relation for a given synset. – To get the Meronymy_holonymy property value, use getMeroHoloValue(); – To get the length of the collection using length(); – To get the first element from the collection, the next element from the collection, the previous element from the collection and the last element from the collection, use first(); next(); previous(); and last(); respectively. – To get the current element, use getElement();

IWNounVerbLinkCollection – Collection of NounVerbLink relation for a given synset. – To get the link property value getLinkValue(); – To get the length of the collection using length(); – To get the first element from the collection, the next element from the collection, the previous element from the collection and the last element from the collection, use first(); next(); previous(); and last(); respectively. – To get the current element, use getElement(); – To get NounVerbSynsetId, use getNounVerbSynsetID();

Questions? IndoWordNet Database Design29

THANK YOU IndoWordNet Database Design30