Showing posts with label Software. Show all posts
Showing posts with label Software. Show all posts

Difference between Line Termination or Endings in Windows '/r/n' and UNIX '/n'. Different types of Line systems.

Hi Everyone in todays post, I will explore the Line Endings or End of Line (EOL) in different system and how to identify them -

First thing to note is -
0d stands for Carriage Return - CR
0a stands for Line Feed - LF

In Windows System when we press ENTER KEY a new line is represented with Hex control character of 0d and 0a.

In UNIX system, when we press ENTER KEY a new line is represented with Hex control character of 0a.

OS X also uses a single LF character, and classic Mac operating system used a single CR character for line breaks

Here (in Windows) we will use the below Text to create a file
First Line then Enter Key pressed
Second Line then Enter Key pressed


HEXADECIMAL View of Text File Created in WINDOWS system 

HEXADECIMAL View of Text File Created in WINDOWS system
 As we can see, for the file created in Windows system new line is represented by the characters 0d and 0a which is Carriage return and Line Feed

The Story of JavaScript - How did JavaScript originate and evolve

Hi Guys, in this post I will explore how JavaScript came into existence, as we all know, JavaScript is the world's most popular programming language, its good to know its history and it goes as below -

JavaScript is a client side scripting language developed by Brendan Eich of Netscape Corporations under the name Mocha.

Mocha was later renamed to LiveScript, and then finally to JavaScript mainly as was it was influenced by the Java programming language. 

LiveScript was the official name when it first shipped in beta releases of Netscape Navigator 2.0 in September 1995, it was renamed JavaScript in a joint announcement with Sun Microsystems on December 4, 1995 when it was deployed in the Netscape browser version 2.0 .

The change of name from LiveScript to JavaScript coincided with Netscape adding support for Java technology in its Netscape Navigator web browser. 

When to use Xml and when to use JSON

 

XML

JSON

You need message validation

You don't need Messages to be validated

XML transfer is slower then JSON since the file size is relatively compared to JSON.

JSON is a good if you want to transmit data faster from client to server, due to reduced file size

You need to transform the XML i.e. if  using XSLT

You're not transforming messages, or transforming their de serialization is simple

Your messages include a lot of marked-up text

Your messages are mostly data, not marked-up text

You need to interoperate with environments that don't support JSON

The messaging endpoints have good JSON tools

Used when objective is to carry or store data

Used when objective is to display the Data

When there is no concern for reduced file/transfer size.

When there is a requirement for reduced file/transfer size.

Processing is slower since XML has to be parsed with XML parser.

Processing is faster since JSON can be parsed by a standard JavaScript function.

 

Difference between XML and JSON

XML

JSON

XML is more verbose than JSON

JSON is less verbose than XML

XML is tree based

JSON’s data structure is a map

Xml was designed to carry or store data.

JSON was designed to carry and display data.

Xml is based on SGML

JSON is text based following Java Script Object Notation.

Xml supports namespace

JSON doesn’t support any namespace

Xml supports comments

JSON doesn’t supports comments.

Xml supports Start and End Tags

JSON doesn’t support End tags

Xml doesn’t support array

JSON supports array

XML has to be parsed with XML parser.

JSON can be parsed by a standard JavaScript function.

Parsing process -

Fetch an XML document

Use the XML DOM to loop through the document

Extract values and store in variables

Parsing process -

Fetch a JSON string

Parse the JSON string

 

Xml parsing is slower since DOM parsing is slower.

JSON Parsing is faster since its based on format of Javascript object.

Xml message validation is supported using XML schemas

JSON validation is supported using JSON Schema, but it is not comprehensive compared to XSD

Xml can be easily transformed using XSLT

No Transformation is available.

Configure or View SharePoint Diagnostic Logging Location in SharePoint Server 2010 2013 2016

As we all know that the Default SharePoint log files are saved at
C:\Program files\Common Files\Microsoft Shared\Web Server Extensions\14\LOGS

The Sharepoint LOGS folder contains
log files (.log),
data files (.txt), and
usage files (.usage)

This post explores how to view and modify the Default SharePoint Log Location -

Step 1) Open SharePoint Central Administration for the SharePoint farm, browse to Monitoring in the Central Administration

Configure or View SharePoint Diagnostic Logging Location