Java stream fusion: Adapting FP mechanisms for an OO setting
| Main Author: | |
|---|---|
| Publication Date: | 2019 |
| Other Authors: | , |
| Language: | eng |
| Source: | Repositórios Científicos de Acesso Aberto de Portugal (RCAAP) |
| Download full: | http://hdl.handle.net/1822/68620 |
Summary: | In this paper, we show how stream fusion, a program transformation technique used in functional programming, can be adapted for an Object-Oriented setting. This makes it possible to have more Stream operators than the ones currently provided by the Java Stream API. The addition of more operators allows for a greater deal of expressiveness. To this extent, we show how these operators are incorporated in the stream setting. Furthermore, we also demonstrate how a specific set of optimizations eliminates overheads and produces equivalent code in the form of for loops. In this way, programmers are relieved from the burden of writing code in such a cumbersome style, thus allowing for a more declarative and intuitive programming approach. |
| id |
RCAP_f8082f82224fb3b86ede314f7dc72d30 |
|---|---|
| oai_identifier_str |
oai:repositorium.sdum.uminho.pt:1822/68620 |
| network_acronym_str |
RCAP |
| network_name_str |
Repositórios Científicos de Acesso Aberto de Portugal (RCAAP) |
| repository_id_str |
https://opendoar.ac.uk/repository/7160 |
| spelling |
Java stream fusion: Adapting FP mechanisms for an OO settingFunctional ProgrammingObject-Oriented ProgrammingProgram FusionEngenharia e Tecnologia::Engenharia Eletrotécnica, Eletrónica e InformáticaScience & TechnologyIn this paper, we show how stream fusion, a program transformation technique used in functional programming, can be adapted for an Object-Oriented setting. This makes it possible to have more Stream operators than the ones currently provided by the Java Stream API. The addition of more operators allows for a greater deal of expressiveness. To this extent, we show how these operators are incorporated in the stream setting. Furthermore, we also demonstrate how a specific set of optimizations eliminates overheads and produces equivalent code in the form of for loops. In this way, programmers are relieved from the burden of writing code in such a cumbersome style, thus allowing for a more declarative and intuitive programming approach.This work is financed by the ERDF European Regional Development Fund through the Operational Programme for Competitiveness and Internationalisation - COMPETE 2020 Programme and by National Funds through the Portuguese funding agency, FCT - Fundação para a Ciência e a Tecnologia within project POCI-01-0145-FEDER016718.Association for Computing Machinery (ACM)Universidade do MinhoRibeiro, FranciscoSaraiva, JoãoPardo, Alberto20192019-01-01T00:00:00Zconference paperinfo:eu-repo/semantics/publishedVersionapplication/pdfhttp://hdl.handle.net/1822/68620eng978145037638910.1145/3355378.3355386https://dl.acm.org/doi/10.1145/3355378.3355386info:eu-repo/semantics/openAccessreponame:Repositórios Científicos de Acesso Aberto de Portugal (RCAAP)instname:FCCN, serviços digitais da FCT – Fundação para a Ciência e a Tecnologiainstacron:RCAAP2024-05-11T06:15:36Zoai:repositorium.sdum.uminho.pt:1822/68620Portal AgregadorONGhttps://www.rcaap.pt/oai/openaireinfo@rcaap.ptopendoar:https://opendoar.ac.uk/repository/71602025-05-28T15:46:54.884003Repositórios Científicos de Acesso Aberto de Portugal (RCAAP) - FCCN, serviços digitais da FCT – Fundação para a Ciência e a Tecnologiafalse |
| dc.title.none.fl_str_mv |
Java stream fusion: Adapting FP mechanisms for an OO setting |
| title |
Java stream fusion: Adapting FP mechanisms for an OO setting |
| spellingShingle |
Java stream fusion: Adapting FP mechanisms for an OO setting Ribeiro, Francisco Functional Programming Object-Oriented Programming Program Fusion Engenharia e Tecnologia::Engenharia Eletrotécnica, Eletrónica e Informática Science & Technology |
| title_short |
Java stream fusion: Adapting FP mechanisms for an OO setting |
| title_full |
Java stream fusion: Adapting FP mechanisms for an OO setting |
| title_fullStr |
Java stream fusion: Adapting FP mechanisms for an OO setting |
| title_full_unstemmed |
Java stream fusion: Adapting FP mechanisms for an OO setting |
| title_sort |
Java stream fusion: Adapting FP mechanisms for an OO setting |
| author |
Ribeiro, Francisco |
| author_facet |
Ribeiro, Francisco Saraiva, João Pardo, Alberto |
| author_role |
author |
| author2 |
Saraiva, João Pardo, Alberto |
| author2_role |
author author |
| dc.contributor.none.fl_str_mv |
Universidade do Minho |
| dc.contributor.author.fl_str_mv |
Ribeiro, Francisco Saraiva, João Pardo, Alberto |
| dc.subject.por.fl_str_mv |
Functional Programming Object-Oriented Programming Program Fusion Engenharia e Tecnologia::Engenharia Eletrotécnica, Eletrónica e Informática Science & Technology |
| topic |
Functional Programming Object-Oriented Programming Program Fusion Engenharia e Tecnologia::Engenharia Eletrotécnica, Eletrónica e Informática Science & Technology |
| description |
In this paper, we show how stream fusion, a program transformation technique used in functional programming, can be adapted for an Object-Oriented setting. This makes it possible to have more Stream operators than the ones currently provided by the Java Stream API. The addition of more operators allows for a greater deal of expressiveness. To this extent, we show how these operators are incorporated in the stream setting. Furthermore, we also demonstrate how a specific set of optimizations eliminates overheads and produces equivalent code in the form of for loops. In this way, programmers are relieved from the burden of writing code in such a cumbersome style, thus allowing for a more declarative and intuitive programming approach. |
| publishDate |
2019 |
| dc.date.none.fl_str_mv |
2019 2019-01-01T00:00:00Z |
| dc.type.driver.fl_str_mv |
conference paper |
| dc.type.status.fl_str_mv |
info:eu-repo/semantics/publishedVersion |
| status_str |
publishedVersion |
| dc.identifier.uri.fl_str_mv |
http://hdl.handle.net/1822/68620 |
| url |
http://hdl.handle.net/1822/68620 |
| dc.language.iso.fl_str_mv |
eng |
| language |
eng |
| dc.relation.none.fl_str_mv |
9781450376389 10.1145/3355378.3355386 https://dl.acm.org/doi/10.1145/3355378.3355386 |
| dc.rights.driver.fl_str_mv |
info:eu-repo/semantics/openAccess |
| eu_rights_str_mv |
openAccess |
| dc.format.none.fl_str_mv |
application/pdf |
| dc.publisher.none.fl_str_mv |
Association for Computing Machinery (ACM) |
| publisher.none.fl_str_mv |
Association for Computing Machinery (ACM) |
| dc.source.none.fl_str_mv |
reponame:Repositórios Científicos de Acesso Aberto de Portugal (RCAAP) instname:FCCN, serviços digitais da FCT – Fundação para a Ciência e a Tecnologia instacron:RCAAP |
| instname_str |
FCCN, serviços digitais da FCT – Fundação para a Ciência e a Tecnologia |
| instacron_str |
RCAAP |
| institution |
RCAAP |
| reponame_str |
Repositórios Científicos de Acesso Aberto de Portugal (RCAAP) |
| collection |
Repositórios Científicos de Acesso Aberto de Portugal (RCAAP) |
| repository.name.fl_str_mv |
Repositórios Científicos de Acesso Aberto de Portugal (RCAAP) - FCCN, serviços digitais da FCT – Fundação para a Ciência e a Tecnologia |
| repository.mail.fl_str_mv |
info@rcaap.pt |
| _version_ |
1833595532996509696 |