In this blog, we will discuss about few methods that are used in JavaScript for partial string extraction. You can also see my blog specific on Arrays which are used in JavaScript. The following methods are :- slice() substring() substr() All these methods extracts parts of a string and returns the extracted parts in a...
1. The splice() method returns the removed item(s) in an array and slice() method returns the selected element(s) in an array, as a new array object. 2. The splice() method changes the original array and slice() method doesn't change the original array. 3. The splice() method can take n number of arguments: Argument 1: Index,...
Many times we need to track whether the email is open/deliver/read by users, sent from our application. After analyzing, I concluded that MailGun provides email tracking services that i used with my grails application and thought it worth sharing. There are two ways to send messages using MailGun: #1. HTTP API #2. SMTP I have...
In my current grails project, i needed to integrate Tumblr with the application using Tumblr API. I searched a lot about it and find the Java wrapper of Tumblr to use it with my grails application and thought it worth sharing. Tumblr uses OAuth1.0 protocol for authorization when our application tries to access the data. The steps...
Compared to Java we have a lot of ways to represent strings : GString, single quote, double quotes, slashy and dollar slashy. 1.GString: A GString is just like a normal String, except that it evaluates expression that are embedded with in string in the form ${..}. [java] String...
In the Wild West of text manipulation, Groovy offers two gunslingers for splitting strings: tokenize() and split(). They might seem like two sides of the same coin, but choosing the right one can make your code smoother than a well-oiled six-shooter. Below are some of the significant differences between both tokenize() and split() ...