Cpp-Skript SS18.Pdf

Total Page:16

File Type:pdf, Size:1020Kb

Cpp-Skript SS18.Pdf Programmierung mit C++ für Computerlinguisten CIS, LMU München Max Hadersbeck Mitarbeiter Daniel Bruder, Ekaterina Peters, Jekaterina Siilivask, Kiran Wallner, Stefan Schweter, Susanne Peters, Nicola Greth — Version Sommersemester 2018 — Inhaltsverzeichnis 1 Einleitung1 1.1 Prozedurale und objektorientierte Programmiersprachen . .1 1.2 Encapsulation, Polymorphismus, Inheritance . .1 1.3 Statische und dynamische Bindung . .2 1.4 Die Geschichte von C++ . .2 1.5 Literaturhinweise . .3 2 Traditionelle und objektorientierte Programmierung4 2.1 Strukturiertes Programmieren . .4 2.2 Objektorientiertes Programmieren . .5 3 Grundlagen7 3.1 Installation von Eclipse und Übungsskript . .7 3.2 Starten eines C++ Programms . .7 3.3 Allgemeine Programmstruktur . .8 3.4 Kommentare in Programmen . 10 3.5 Variablen . 11 3.5.1 Was sind Variablen? . 11 3.5.2 Regeln für Variablen . 12 3.5.3 Grundtypen von Variablen . 12 3.5.4 Deklaration und Initialisierung von Variablen . 13 3.5.5 Lebensdauer von Variablen . 14 3.5.6 Gültigkeit von Variablen . 15 3.6 Namespace . 16 3.6.1 Defaultnamespace . 16 3.7 Zuweisen von Werten an eine Variable . 17 3.8 Einlesen und Ausgeben von Variablenwerten . 19 3.8.1 Einlesen von Daten . 19 3.8.2 Zeichenweises Lesen und Ausgeben von Daten . 21 3.8.3 Ausgeben von Daten . 22 3.8.4 Arbeit mit Dateien . 23 3.8.4.1 Textdateien unter Unix ................... 23 3.8.4.2 Textdateien unter Windows ................ 24 3.8.4.3 Lesen aus einer Datei . 25 3.8.4.4 Lesen aus einer WINDOWS Textdatei . 26 i ii Inhaltsverzeichnis 3.8.4.5 Schreiben in eine Datei . 26 3.9 Operatoren . 29 3.9.1 Arithmetische Operatoren . 30 3.9.2 Relationale und Logische Operatoren . 30 3.9.3 Die Wahrheitstabelle bei logischen Ausdrücken . 31 3.9.4 String Operatoren . 31 3.9.4.1 Zuweisungsoperator: = .................... 31 3.9.4.2 Verknüpfungsoperator: + .................. 31 3.9.4.3 Lexikographischer Vergleich bei Strings: . 32 4 Konstanten 33 5 Strukturierung von Programmen 37 5.1 Kontrollstrukturen . 37 5.1.1 Statements und Blöcke . 37 5.2 compound statement . 37 5.3 Selection-Statements . 38 5.3.1 Selection-Statement: if , if - else ................. 38 5.3.2 Selection-Statement: switch ..................... 39 5.4 Iteration-Statements . 40 5.4.1 Iteration-Statement: while ...................... 40 5.4.2 Iteration-Statement: do ........................ 41 5.4.3 Iteration-Statement: for ........................ 42 5.4.4 Iteration-Statement: range-for .................... 43 5.5 Das Wichtigste in Kürze . 44 6 Einsatz von Strings 46 6.1 Einf�hrung . 46 6.1.1 Bitbreite der Buchstaben von Strings . 46 6.1.2 Deklaration und Initialisierung von Stringvariablen mit 8-Bit Buch- stabencode . 47 6.2 Methoden f�r Stringobjekte . 47 6.3 Konstruktion eines Strings . 49 6.4 Destruktion eines Strings . 49 6.5 Zugriff auf die Buchstaben eines Strings . 49 6.6 Alphabetischer Vergleich von Strings . 50 6.7 Suchen innerhalb eines Strings . 53 6.8 Modifizieren eines Strings . 53 6.9 C++ Strings und C Strings . 57 6.10 Das Wichtigste in K�rze . 57 Inhaltsverzeichnis iii 7 Funktionen 59 7.1 Motivation . 59 7.2 Funktionstyp . 61 7.3 Funktionsname . 62 7.4 Funktionsargumente . 62 7.5 Defaultwerte für Funktionsargumente . 62 7.6 Funktionsrumpf . 63 7.7 Die Argumentübergaben . 63 7.7.1 Übergabe des Werts eines Arguments . 64 7.7.2 Übergabe einer Referenz auf ein Argument . 64 7.7.3 Beispiele Value vs. Referenz . 64 7.7.4 Seiteneffekte . 65 7.8 Überladen von Funktionen . 67 7.9 Mehrdeutigkeiten durch Überladen der Funktionen . 68 8 Internationalisierung unter C++ 70 8.1 Einführung in Kodierungen . 70 8.2 Unicode Transformation Format: UTF-8 . 70 8.3 Datentypen für Unicode-Zeichen . 72 8.4 Locales und Imbuing . 73 8.4.1 Localeabhängiges Arbeiten bei UCS Codierung . 74 8.5 UCS Zeichen und Datei-Streams . 76 8.5.1 Konvertierung von utf8 nach ISO-Latin . 76 8.5.2 Ausgabe einer UTF8- kodierten Datei . 77 8.6 Das Wichtigste in Kürze . 78 9 Programmieren von Klassen 80 9.1 Einführung . 80 9.2 Deklaration von Klassen . 80 9.3 Deklaration von Klassenobjekten . 81 9.4 Beispiel mit Klassen . 82 9.5 Initialisierung der Daten eines Objekts . 85 9.6 Löschen der Daten eines Objekts . 87 9.7 Kopieren der Daten eines Objekts . 87 9.8 Das Überladen von Operatoren . 88 9.9 Überladen von relationalen und logischen Operatoren . 89 9.10 Überladen von unären Operatoren . 89 9.11 Überladen des Output-Operators . 90 10 Vererbung 92 10.1 Einleitung . 92 10.2 Vererbung von Zugriffsrechten . 93 iv Inhaltsverzeichnis 10.3 Spezielle Methoden werden nicht vererbt . 94 10.4 Zuweisung von Objekten einer Unterklasse an Objekte der Oberklasse . 97 10.5 Überschreiben von Methoden/Funktionen in der abgeleiteten Klasse . 97 10.6 Polymorphismus . 98 11 Templates 101 11.1 Generische Funktionen . 101 11.2 Generische Klassen . 103 11.3 Erweiterung des Beispiels memory . 106 12 Standard Template Library (STL) 111 12.1 Iteratoren der STL . 111 12.2 Klassen der STL für die Computerlinguistik . 115 12.2.1 wchar_t . 115 12.2.2 wstring ................................. 115 12.3 Utilities der STL für die Computerlinguistik . 116 12.3.1 pair <type1, type2> ......................... 116 12.3.1.1 make_pair()- Hilfsfunktion . 116 12.4 Container der STL für die Computerlinguistik . 119 12.4.1 Überblick . 119 12.4.2 Einsatz der Container . 119 12.4.3 vector <type> ............................. 120 12.4.4 list<type> ............................... 124 12.4.5 deque<type> . 127 12.4.6 set <type> . 127 12.4.6.1 Beispiel mit dem Container set .............. 128 12.4.7 map <type1,type2> . 129 12.4.7.1 Beispiel zur Berechnung einer Frequenzliste mit map ... 130 12.4.8 unordered_set<type>, unordered_map<type1,type2> . 132 12.4.8.1 Implementation der Hash-Templates der STL mit dem gcc 132 12.5 STL-Algorithmen . 136 12.5.1 Vorbemerkung: Laufzeiten . 136 12.5.1.1 Der Headerfile algorithm für Algorithmen . 137 12.5.1.2 find():............................ 138 12.5.1.3 find_first_of():...................... 139 12.5.1.4 find_last_of():...................... 139 12.5.1.5 find_first_not_of():................... 141 12.5.1.6 find_last_not_of():.................... 142 12.5.1.7 find_if():.......................... 142 12.5.1.8 find_end():......................... 143 12.5.1.9 adjacent_find():...................... 144 12.5.1.10 search():.......................... 145 Inhaltsverzeichnis v 12.5.1.11 search_n():......................... 146 12.5.1.12 count():........................... 147 12.5.1.13 count_if():......................... 148 12.5.1.14 equal():........................... 149 12.5.1.15 mismatch():......................... 150 12.5.1.16 replace():.......................... 151 12.5.1.17 replace_copy():...................... 151 12.5.1.18 replace_copy_if():.................... 151 12.5.1.19 replace_if():........................ 152 12.5.1.20 unique():.......................... 152 12.5.1.21 unique_copy():....................... 152 12.5.1.22 sort():............................ 153 12.5.1.23 transform():........................ 154 12.5.1.24 for_each():......................... 155 13 Erweiterung um reguläre Ausdücke, die Bibliothek Boost::Regex 156 13.1 Integration des Pakets Boost . 156 13.1.1 Installation des Pakets Boost . 156 13.1.2 Kompilieren unter Verwendung der Bibliothek Boost::Regex ... 157 13.1.3 Einbinden von Boost::Regex in Eclipse . 157 13.1.4 Verwendung von Boost::Regex .................... 158 13.2 Verwendung von Regex mit C++11 . 158 13.3 Suchen nach einem regulären Ausdruck: regex_match ........... 158 13.4 Suchen nach einem regulären Ausdruck: regex_search() ......... 160 13.5 Ersetzen in einem String mit einem regulären Ausdruck: regex_replace() 162 13.6 UNICODE und Lokalisierung mit boost . ..
Recommended publications
  • Boenig-Liptsin / Entrepreneurs of the Mind / 1 Citizen's Mind
    Margo Boenig-Liptsin SIGCIS Workshop, November 9, 2014 Work in !rogress Session "orking draft – please do not cite (ear SIGCIS Workshop !articipants) *hank you $or reading this partial draft of one of my dissertation 'hapters) I-m submitting to your review a draft of a 'hapter $rom the mi##&e of my dissertation, therefore to contextualize the "riting that you "i&& be reading, I inc&ude be&ow an abstract of my "hole dissertation project and a chapter out&ine. 2s you "i&& see, this early draft of Chapter 2 is based primari&y on empirical research of my three national cases1 I haven't yet integrated into it any secondary &iterature. I "ould be very gratef,& $or your suggestions of re$erences that you $eel "ould be interesting $or me to incorporate/refect upon, especial&y $rom the &iterature on the history of computing, given the topi's that I am exploring in this chapter or in the dissertation as a "hole. *his early draft is also missing complete $ootnotes—they are current&y 0ust notes $or mysel$ and references that I need to tidy up. I-m gratef,& $or al& of your comments, "hich "i&& no doubt make the next #raft of this signifcant&y better) Best "ishes, Margo (issertation abstract Making the Citi/en of the Information 2ge7 2 comparative study of computer &iteracy programs $or 'hi&dren, 1960s-1990s My dissertation is a comparative history of the frst computer &iteracy programs $or chi&dren. *he project examines how programs to introduce 'hi&dren to computers in the 9nited States, :rance, and the Soviet 9nion $rom the 1960s to 1990s embodied political, epistemic, and moral debates about the kind of citi/en required $or &i$e in the 21st century.
    [Show full text]
  • A Python Implementation for Racket
    PyonR: A Python Implementation for Racket Pedro Alexandre Henriques Palma Ramos Thesis to obtain the Master of Science Degree in Information Systems and Computer Engineering Supervisor: António Paulo Teles de Menezes Correia Leitão Examination Committee Chairperson: Prof. Dr. José Manuel da Costa Alves Marques Supervisor: Prof. Dr. António Paulo Teles de Menezes Correia Leitão Member of the Committee: Prof. Dr. João Coelho Garcia October 2014 ii Agradecimentos Agradec¸o... Em primeiro lugar ao Prof. Antonio´ Leitao,˜ por me ter dado a oportunidade de participar no projecto Rosetta com esta tese de mestrado, por todos os sabios´ conselhos e pelos momentos de discussao˜ e elucidac¸ao˜ que se proporcionaram ao longo deste trabalho. Aos meus pais excepcionais e a` minha mana preferida, por me terem aturado e suportado ao longo destes quase 23 anos e sobretudo pelo incondicional apoio durante estes 5 anos de formac¸ao˜ superior. Ao pessoal do Grupo de Arquitectura e Computac¸ao˜ (Hugo Correia, Sara Proenc¸a, Francisco Freire, Pedro Alfaiate, Bruno Ferreira, Guilherme Ferreira, Inesˆ Caetano e Carmo Cardoso), por todas as sug- estoes˜ e pelo inestimavel´ feedback em artigos e apresentac¸oes.˜ Aos amigos em Tomar (Rodrigo Carrao,˜ Hugo Matos, Andre´ Marques e Rui Santos) e em Lisboa (Diogo da Silva, Nuno Silva, Pedro Engana, Kaguedes, Clara Paiva e Odemira), por terem estado pre- sentes, duma forma ou doutra, nos essenciais momentos de lazer. A` Fundac¸ao˜ para a Cienciaˆ e Tecnologia (FCT) e ao INESC-ID pelo financiamento e acolhimento atraves´ da atribuic¸ao˜ de uma bolsa de investigac¸ao˜ no ambitoˆ dos contratos Pest-OE/EEI/LA0021/2013 e PTDC/ATP-AQI/5224/2012.
    [Show full text]
  • A Comparative Study of the First Computer Literacy Programs for Children in the United States, France, and the Soviet Union, 1970-1990
    Making Citizens of the Information Age: A Comparative Study of the First Computer Literacy Programs for Children in the United States, France, and the Soviet Union, 1970-1990 The Harvard community has made this article openly available. Please share how this access benefits you. Your story matters Citation Boenig-Liptsin, Margarita. 2015. Making Citizens of the Information Age: A Comparative Study of the First Computer Literacy Programs for Children in the United States, France, and the Soviet Union, 1970-1990. Doctoral dissertation, Harvard University, Graduate School of Arts & Sciences. Citable link http://nrs.harvard.edu/urn-3:HUL.InstRepos:23845438 Terms of Use This article was downloaded from Harvard University’s DASH repository, and is made available under the terms and conditions applicable to Other Posted Material, as set forth at http:// nrs.harvard.edu/urn-3:HUL.InstRepos:dash.current.terms-of- use#LAA Making Citizens of the Information Age: A comparative study of the first computer literacy programs for children in the United States, France, and the Soviet Union, 1970-1990 A dissertation presented by Margarita Boenig-Liptsin to The Department of History of Science in partial fulfillment of the requirements for the degree of Doctor of Philosophy in the subject of History of Science Harvard University Cambridge, Massachusetts August 2015 © 2015 Margarita Boenig-Liptsin All rights reserved. Dissertation Advisor: Professor Sheila Jasanoff Margarita Boenig-Liptsin Making Citizens of the Information Age: A comparative study of the first computer literacy programs for children in the United States, France, and the Soviet Union, 1970-1990 ABSTRACT In this dissertation I trace the formation of citizens of the information age by comparing visions and practices to make children and the general public computer literate or cultured in the United States, France, and the Soviet Union.
    [Show full text]
  • Benchmarking the Amazon Elastic Compute Cloud (EC2)
    Benchmarking the Amazon Elastic Compute Cloud (EC2) A Major Qualifying Project Report submitted to the Faculty of the WORCESTER POLYTECHNIC INSTITUTE in partial fulfillment of the requirements for the Degree of Bachelor of Science by Patrick Coffey Niyanta Mogre Jason Beliveau Andrew Harner Approved By: WPI Project Advisor Professor Donald R. Brown March 9, 2011 Abstract This project sought to determine whether Amazon EC2 is an economically viable environment for scientific research-oriented activities within a university setting. The methodology involved benchmarking the performance of the cloud servers against the best systems available at the WPI ECE department. Results indicate that the newest ECE server outperformed the best EC2 instance by approximately 25% in most cases. A comprehensive cost analysis suggests that EC2 instances can achieve up to 60% better cost to performance ratios in the short-term when compared against the ECE servers. However, a long-term projected cost analysis determined that the overall cost of owning a large set of reserved instances comes out to almost 60% more than the cost of comparable in-house servers. Acknowledgments We would like to thank our advisor, Professor Donald R. Brown for his guidance throughout the course of this project. We would also like to thank Professor Sergey Makarov for providing us access to his research for our case study, as well as Professor Berk Sunar for advising us on the aspects of computer architecture that were needed to analyze our results. We would also like to thank Professor Hugh Lauer for allowing us the opportunity to run the SPEC benchmarks, as well as his advice in understanding benchmarking concepts.
    [Show full text]
  • Chapter 13 Educational Technology at BBN Wallace Feurzeig
    Feurzeig, W. (2011). Educational technology at BBN. In D. Walden & R. Nickerson (Eds.), A culture of innovation. East Sandwich, MA: Waterside Publishing. Chapter 13 Educational Technology at BBN Wallace Feurzeig Since the early 1960s, BBN mathematicians, scientists, and engineershave explored ways tousecomputer and communications technologies to improve teaching and learning. BBN staff members have conducted basic research in human cognition and learning, developed innovativesoftware tools toextend and enrich the traditional curriculum, and provided professional development tohelpeducatorsmakeeffectiveuseofthe new technologies.They have helped schools employ networking facilities to connectteachers and students with each other and with national and global resources.1 13.1 From drill-and-practice to “intelligent” CAI No one,in the early sixties, saw the enormous potential of computers for education moreclearly than J. C. R.Licklider. Atthattime,the prevailing modelforthe use oftech- nologyin education was drill-and-practice.The computer, like earlier electromechanical teaching devices, directed the interaction;itposed questions (typically multiplechoice) and assessed the correctness ofthe student’sanswers.The student’s rolewaspurely responsive. Paired-associate drill Anearly exampleofthiskind of computer-aided instruction (CAI) was the paired- associatedrill tutor developed byLickliderin 1960(Coulson,1962). the program was used toprovide practice in learning German language vocabulary. However, it could be used toprovide practice in learning any kind of paired-associatematerial, thatis, materialthatisorganized in pairs,the firstitem of which is treated as a question, the second as an answer. The program worked roughly as follows. Oneachtrial, the program would type the first item of a pair (i.e., the question) and wait for the student to type an answer. If the studenttyped the correct answer(i.e., the second item of the pair), the program would indicate thatthe response was correct, and moveonto the next question.
    [Show full text]
  • Scripting User's Guide 12C Release 1 (12.2.1.4.0) E93588-02
    Oracle® Fusion Middleware Oracle WebCenter Forms Recognition Scripting User's Guide 12c Release 1 (12.2.1.4.0) E93588-02 September 2019 Documentation for WebCenter Forms Recognition project developers that describes how to develop scripts for creating and customizing projects. Oracle Fusion Middleware Oracle WebCenter Forms Recognition Scripting User's Guide, 12c Release 1 (12.2.1.4.0) E93588-02 Copyright © 2009, 2019, Oracle and/or its affiliates. All rights reserved. This software and related documentation are provided under a license agreement containing restrictions on use and disclosure and are protected by intellectual property laws. Except as expressly permitted in your license agreement or allowed by law, you may not use, copy, reproduce, translate, broadcast, modify, license, transmit, distribute, exhibit, perform, publish, or display any part, in any form, or by any means. Reverse engineering, disassembly, or decompilation of this software, unless required by law for interoperability, is prohibited. The information contained herein is subject to change without notice and is not warranted to be error-free. If you find any errors, please report them to us in writing. If this is software or related documentation that is delivered to the U.S. Government or anyone licensing it on behalf of the U.S. Government, then the following notice is applicable: U.S. GOVERNMENT END USERS: Oracle programs, including any operating system, integrated software, any programs installed on the hardware, and/or documentation, delivered to U.S. Government end users are "commercial computer software" pursuant to the applicable Federal Acquisition Regulation and agency-specific supplemental regulations. As such, use, duplication, disclosure, modification, and adaptation of the programs, including any operating system, integrated software, any programs installed on the hardware, and/or documentation, shall be subject to license terms and license restrictions applicable to the programs.
    [Show full text]
  • Characterization and Compensation of Stray Light Effects in Time of Flight Based Range Sensors
    Characterization and compensation of Stray light effects in Time of flight based range sensors Jonas Holmlund Master’s Thesis in Engineering Physics, Department of Physics, Umeå University, 2013 Department of physics Linnaeus väg 20 901 87 Umeå Sweden www.physics.umu.se Characterization and compensation of Stray light effects in Time of flight based range sensors Jonas Holmlund [email protected] MAY 2013 Supervisors: Emil Jonze Jonas Sjöberg Examiner: Ove Axner Abstract Recently much work has been done with the development of 3D real-time imagers, including the Time-of-flight (ToF) camera. This type of camera uses the principle of time of flight, in order to perform a distance measurement to every point in the field of view of the camera. This is done by sending a light signal towards the objects of the observed scene of the camera, where the light is reflected and returns to the camera. The signal is detected at the camera sensor, usually a CCD- or CMOS-chip with an array of pixels, where a distance measurement is made at every pixel, creating a 3D image of the whole scene. The problem is that some of the signal light travels through the optical system of the camera in a way that was not meant in the design. This light is called stray light. The measurement of the distance to different points within the field of view of the camera depends on the amount of light and the distance traveled by the light that reaches each and every one of the sensor pixels. This means that the effects of stray light will directly affect the accuracy of the depth data for the images when stray light spreads to different parts of the sensor.
    [Show full text]
  • Njit-Etd2006-063
    Copyright Warning & Restrictions The copyright law of the United States (Title 17, United States Code) governs the making of photocopies or other reproductions of copyrighted material. Under certain conditions specified in the law, libraries and archives are authorized to furnish a photocopy or other reproduction. One of these specified conditions is that the photocopy or reproduction is not to be “used for any purpose other than private study, scholarship, or research.” If a, user makes a request for, or later uses, a photocopy or reproduction for purposes in excess of “fair use” that user may be liable for copyright infringement, This institution reserves the right to refuse to accept a copying order if, in its judgment, fulfillment of the order would involve violation of copyright law. Please Note: The author retains the copyright while the New Jersey Institute of Technology reserves the right to distribute this thesis or dissertation Printing note: If you do not wish to print this page, then select “Pages from: first page # to: last page #” on the print dialog screen The Van Houten library has removed some of the personal information and all signatures from the approval page and biographical sketches of theses and dissertations in order to protect the identity of NJIT graduates and faculty. ABSTRACT FINDING ROLE ERRORS OF THE NCIT GENE HIERARCHY USING THE NCBI by Marc Oren Due to the knowledge discovery process of gene information, details such as organism and chromosomal location should be known. Furthermore, the extensive biomedical research in genomics led to discovery of processes and diseases in which a gene plays a role.
    [Show full text]
  • Oracle Forms Recognition Scripting Guide 10G Release 3 (10.1.3.5.0) Copyright © 2009, Oracle And/Or Its Affiliates
    Oracle® Forms Recognition Scripting Guide 10g Release 3 (10.1.3.5.0) October 2009 Oracle Forms Recognition Scripting Guide 10g Release 3 (10.1.3.5.0) Copyright © 2009, Oracle and/or its affiliates. All rights reserved. This software and related documentation are provided under a license agreement containing restrictions on use and disclosure and are protected by intellectual property laws. Except as expressly permitted in your license agreement or allowed by law, you may not use, copy, reproduce, translate, broadcast, modify, license, transmit, distribute, exhibit, perform, publish, or display any part, in any form, or by any means. Reverse engineering, disassembly, or decompilation of this software, unless required by law for interoperability, is prohibited. The information contained herein is subject to change without notice and is not warranted to be error-free. If you find any errors, please report them to us in writing. If this software or related documentation is delivered to the U.S. Government or anyone licensing it on behalf of the U.S. Government, the following notice is applicable: U.S. GOVERNMENT RIGHTS Programs, software, databases, and related documentation and technical data delivered to U.S. Government customers are "commercial computer software" or "commercial technical data" pursuant to the applicable Federal Acquisition Regulation and agency-specific supplemental regulations. As such, the use, duplication, disclosure, modification, and adaptation shall be subject to the restrictions and license terms set forth in the applicable Government contract, and, to the extent applicable by the terms of the Government contract, the additional rights set forth in FAR 52.227-19, Commercial Computer Software License (December 2007).
    [Show full text]
  • Tierless Web Programming in ML
    Thèse de doctorat de l’Université Sorbonne Paris Cité Préparée à l’Université Paris Diderot au Laboratoire IRIF Ecole Doctorale 386 - Science Mathématiques De Paris Centre Tierless Web programming in ML par Gabriel Radanne Dirigée par Roberto Di Cosmo et Jérôme Vouillon Thèse soutenue publiquement le 14 Novembre 2017 devant le jury constitué de Roberto Di Cosmo Directeur de thèse Jérôme Vouillon Co-Directeur de thèse Koen Claessen Rapporteur Jacques Garrigue Rapporteur Coen De Roover Examinateur Xavier Leroy Examinateur Manuel Serrano Examinateur Jeremy Yallop Examinateur Abstract Eliom is a dialect of OCaml for Web programming in which server and client pieces of code can be mixed in the same file using syntactic annotations. This allows to build a whole application as a single distributed program, in which it is possible to define in a composable way reusable widgets with both server and client behaviors. Eliom is type-safe, as it ensures that communications are well-behaved through novel language constructs that match the specificity of Web pro- gramming. Eliom is also efficient, it provides static slicing which sepa- rates client and server parts at compile time and avoids back-and-forth communications between the client and the server. Finally, Eliom sup- ports modularity and encapsulation thanks to an extension of the OCaml module system featuring tierless annotations that specify whether some definitions should be on the server, on the client, or both. This thesis presents the design, the formalization and the implementa- tion of the Eliom language. Résumé Eliom est un dialecte d’OCaml pour la programmation Web qui permet, à l’aide d’annotations syntaxiques, de déclarer code client et code serveur dans un même fichier.
    [Show full text]
  • Content Delivery Network API Documentation
    Content Delivery Network Content Delivery Network API Documentation Product Documentation ©2013-2019 Tencent Cloud. All rights reserved. Page 1 of 376 Content Delivery Network Copyright Notice ©2013-2019 Tencent Cloud. All rights reserved. Copyright in this document is exclusively owned by Tencent Cloud. You must not reproduce, modify, copy or distribute in any way, in whole or in part, the contents of this document without Tencent Cloud's the prior written consent. Trademark Notice All trademarks associated with Tencent Cloud and its services are owned by Tencent Cloud Computing (Beijing) Company Limited and its affiliated companies. Trademarks of third parties referred to in this document are owned by their respective proprietors. Service Statement This document is intended to provide users with general information about Tencent Cloud's products and services only and does not form part of Tencent Cloud's terms and conditions. Tencent Cloud's products or services are subject to change. Specific products and services and the standards applicable to them are exclusively provided for in Tencent Cloud's applicable terms and conditions. ©2013-2019 Tencent Cloud. All rights reserved. Page 2 of 376 Content Delivery Network Contents API Documentation History Introduction API Category Making API Requests Request Structure Common Params Signature v3 Signature Responses Data Query APIs ListTopData DescribeOriginData DescribeIpVisit DescribeCdnData DescribeBillingData DescribeReportData Service Query APIs DescribePayType DescribeMapInfo DescribeCdnIp
    [Show full text]
  • Representing String Computations As Graphs for Classifying Malware Justin Del Vecchio Steven Y
    Representing String Computations as Graphs for Classifying Malware Justin Del Vecchio Steven Y. Ko Lukasz Ziarek [email protected] [email protected] [email protected] University at Buffalo University at Buffalo University at Buffalo Buffalo, New York Buffalo, New York Buffalo, New York ABSTRACT 1 INTRODUCTION Android applications rely heavily on strings for sensitive operations Android is one of the most popular platforms for mobile computing like reflection, access to system resources, URL connections, data- and Android’s official app store, Google Play, contains more than2.9 base access, among others. Thus, insight into application behavior million unique applications (apps) as of December 2018. However, can be gained through not only an analysis of what strings an ap- this popularity has also resulted in a dramatic increase in malicious plication creates but also the structure of the computation used to apps targeting Android devices. As of 2019, security experts [1] have create theses strings, and in what manner are these strings used. In identified over 31 million unique, malicious mobile apps. To combat this paper we introduce a static analysis of Android applications to this increase in malware the security community has developed discover strings, how they are created, and their usage. The output many static analysis tools for identifying malicious Android apps. of our static analysis contains all of this information in the form of By identifying malware statically, these tools can offer enhanced a graph which we call a string computation. We leverage the results security for end users who download and use Android apps. Many to classify individual application behavior with respect to malicious different types of analyses have proven to be useful such as data and or benign intent.
    [Show full text]