Monday 12 July 2021

Basic Terminologies in AWS Cloud | Regions | Availability Zones | Edge Locations | Amazon Web Services - AWS Interview Questions

Region à A region is basically a geographical area. This is actually a physical location around the world where they cluster data centers. Each of these group of logical data centers are called as an Availability Zone. Each region consists of 2 (or more) availability zones.

Availability Zone à It is simply a data center. These AZs is one or more discrete (separate and distinct) data centers with redundant power, networking, and connectivity in an AWS Region. Each AWS Region consists of multiple, isolated, and physically separate AZs within a geographic area. AZs configured across multiple data center allows or provides customers the potential to operate production applications and databases that are more highly available, fault tolerant, and scalable than would be possible from a single data center.

Saturday 10 July 2021

What is Amazon Web Services (AWS)? | AWS Cloud Computing Summary

AWS (Amazon Web Services) is a comprehensive, evolving and secure cloud computing platform provided by Amazon that includes a mixture of infrastructure as a service (IaaS), platform as a service (PaaS) and software as a service (SaaS) offering. AWS offers compute power, database storage, content delivery and other functionality to help businesses scale and grow. Amazon Web Services (AWS) is a subsidiary of Amazon providing on-demand cloud computing platforms and APIs to individuals, companies and governments on a pay-as-you-go basis. 


Monday 5 July 2021

Difference between Abstract Class and Interface in C# | Abstract Class Vs Interface | OOPS concept| Abstraction and Inheritance

 

Abstract Class

Interface

An abstract class is a way to achieve the abstraction in C#.

The Abstract classes are typically used to define a base class in the class hierarchy.

An Abstract class is never intended to be instantiated directly.

This class must contain at least one abstract method, which is marked by the keyword or modifier abstract in the class definition.

Interface can have methods, properties, events, and indexers as its members. Interfaces will contain only the declaration of the members.

The implementation of interface’s members will be given by the class who implements the interface implicitly or explicitly.

Interface cannot be instantiated

The abstract keyword is used to declare abstract class.

The interface keyword is used to declare interface

Abstract class doesn't support multiple inheritance. A subclass can at most use only one abstract class

Interface supports multiple inheritance. A class can implement any number of interfaces

Abstract class can have abstract and non-abstract methods.

Interface can have only abstract methods.

An abstract class can declare or use any variables

Interfaces cannot contain fields.

An abstract class can have constructor declaration

Interfaces cannot contain constructors

It can contain static members.

It does not contain static members.

An abstract Class is allowed to have all access modifiers for all of its member declaration 

 In interface we can’t declare any access modifier (including public) as all the members of interface are implicitly public.

The performance of an abstract class is fast.

The performance of interface is slow because it requires time to search actual method in the corresponding class.

It is used to implement the core identity of class.

It is used to implement peripheral abilities of class.

If many implementations are of the same kind and use common behaviour, then it is superior to use abstract class.

If many implementations only share methods, then it is superior to use Interface.

Abstract class can contain methods, fields, constants, etc.

Interface can only contain methods.

It can be fully, partially or not implemented.

It should be fully implemented.

It contains both declaration and definition part

It contains only a declaration part.

Example:

public interface SampleInterface

    {

        void FirstMethod();

        string SecondName();

    }

Example:

abstract class SampleAbstractClass

    {

        int variable1 = 0;

        int variable2 = 1;

        public abstract void FirstMethod();

    }


Difference between abstract class and interface in C#




Related Posts Plugin for WordPress, Blogger...

ShareThis