Open in app

Sign In

Write

Sign In

Maryam Ziyad
Maryam Ziyad

90 Followers

Home

About

Published in

Ballerina-Techblog

·9 hours ago

Errors and Error Handling in Ballerina — Part II — Error Subtypes

This post is based on Ballerina Swan Lake Update 5. In a previous article we looked into the basics of errors and error handling in Ballerina, including the error type, creating error values, panic, trap, check, checkpanic, on fail, etc. In this post we will be looking at defining custom…

Ballerinalang

12 min read

Errors and Error Handling in Ballerina — Part II — Error Subtypes
Errors and Error Handling in Ballerina — Part II — Error Subtypes
Ballerinalang

12 min read


Published in

Ballerina-Techblog

·May 3

Errors and Error Handling in Ballerina — Part I

This post is based on Ballerina Swan Lake Update 5 Ballerina does not have exceptions. It has a separate error basic type which is used to indicate errors in a program. With the separate error type, errors in Ballerina are explicit and pretty much impossible to ignore by design. …

Ballerinalang

15 min read

Errors and Error Handling in Ballerina — Part I
Errors and Error Handling in Ballerina — Part I
Ballerinalang

15 min read


Published in

Ballerina-Techblog

·Sep 26, 2021

Immutability in Ballerina — Part I

Ballerina provides first-class support for immutability. Immutability in Ballerina is deep; a value that is immutable is guaranteed to hold/refer to only immutable values. In other words, a value accessed via an immutable value is also guaranteed to be immutable. Immutability in the type system can be leveraged to provide…

Ballerinalang

6 min read

Immutability in Ballerina — Part I
Immutability in Ballerina — Part I
Ballerinalang

6 min read


Published in

Ballerina-Techblog

·Jan 27, 2021

[Ballerina] Working with JSON — JSON to record conversion

Among Ballerina’s many features that make working with network interactions and data easy, a key highlight is its native support for JSON, with the json type being a built-in type. JSON in Ballerina The json type represents the union of ()|boolean|int|float|decimal|string|json[]|map<json>. map<json> specifically represents a JSON object, which is basically a collection of…

Ballerina

5 min read

[Ballerina] Working with JSON — Part I — JSON to record conversion
[Ballerina] Working with JSON — Part I — JSON to record conversion
Ballerina

5 min read


Published in

Ballerina-Techblog

·Dec 31, 2019

[Ballerina] Error Handling — Part III — Error Binding Patterns

In the previous posts we looked into the concept of errors in Ballerina and related actions. Part I — introduction to the error type and check, panic, checkpanic and trap. Part II — user-defined errors, immutability, type test, etc. In this post we will be looking at error binding patterns. Error Binding Patterns …

Ballerina

3 min read

[Ballerina] Error Handling — Part III — Error Binding Patterns
[Ballerina] Error Handling — Part III — Error Binding Patterns
Ballerina

3 min read


Published in

Ballerina-Techblog

·Dec 24, 2019

[Ballerina] Error Handling — Part II

In the previous post we looked into the basics of errors and error handling in Ballerina, including the error type, creating error values, panic, trap, check, checkpanic, etc. In this post we will be looking at a bit more advanced concepts, including defining and using custom error types immutability of…

Programming

2 min read

[Ballerina] Error Handling — Part II
[Ballerina] Error Handling — Part II
Programming

2 min read


Published in

Ballerina-Techblog

·Sep 28, 2019

[Ballerina] Error Handling — Part I

NOTE: This blog is based on an older version of Ballerina and is therefore, incompatible with newer/current versions of Ballerina. An updated version of this blog is now available as a Stack Overflow article and a Medium blog. Errors in Ballerina are quite explicit and pretty much impossible to ignore…

Programming

5 min read

[Ballerina] Error Handling — Part I
[Ballerina] Error Handling — Part I
Programming

5 min read


Published in

Ballerina-Techblog

·Sep 25, 2019

[Ballerina] Converting CSV to JSON

Today we came across a use case where it was required to convert data in a CSV file to JSON format. Say I have the following CSV file (data modified a bit from a BBE):

Ballerinalang

3 min read

[Ballerina] Converting CSV to JSON
[Ballerina] Converting CSV to JSON
Ballerinalang

3 min read


Published in

Ballerina-Techblog

·Sep 13, 2019

Ballerina’s JSON type and lax static typing

Ballerina, a programming language primarily targeting network-distributed applications, just hit 1.0! Among the numerous features that make Ballerina attractive, ranked high up there are arguably its native support for JSON and its type-safety. …

Ballerina

4 min read

Ballerina’s JSON type and lax static typing
Ballerina’s JSON type and lax static typing
Ballerina

4 min read


Published in

Ballerina-Techblog

·Dec 13, 2018

Immutable Values in Ballerina

The latest release of Ballerina, Ballerina 0.990.0, introduced immutable/read-only values. The main motivation behind introducing immutable values, was to allow safe sharing of values between concurrently executing segments of code. Ballerina 0.990.0 was a major release that introduced a significant number of new features and changes to the language. Do…

Programming

4 min read

Immutable Values in Ballerina
Immutable Values in Ballerina
Programming

4 min read

Maryam Ziyad

Maryam Ziyad

90 Followers
Following
  • Chintana Wilamuna

    Chintana Wilamuna

  • Anupama Pathirage

    Anupama Pathirage

  • Chanaka Fernando

    Chanaka Fernando

  • KRV PERERA

    KRV PERERA

  • Rasika Perera

    Rasika Perera

See all (52)

Help

Status

Writers

Blog

Careers

Privacy

Terms

About

Text to speech

Teams