Skip to main content

Posts

C# OOPs Concepts

Encapsulation : Encapsulation is a process of binding the data members and member functions into a single unit. Example for encapsulation is class . A class can contain data structures and methods. Consider the following class public class Aperture { public Aperture () { } protected double height; protected double width; protected double thickness; public double get volume() { Double volume=height * width * thickness; if (volume return 0; return volume; } } In this example we encapsulate some data such as height, width, thickness and method Get Volume. Other methods or objects can interact with this object through methods that have public access modifier Abstraction: Abstraction is a process of hiding the implementation details and displaying the essential features. Example1 : A Laptop consists of many things such as processor, motherboard, RAM, keyboard, LCD screen, wireless antenna, web camera, usb ports, batt...

SQL -Server - In case of multiple transaction in a procedure, what will happen if error will occur after inner transaction commit statement?

Committing inner transactions is ignored by the SQL Server Database Engine. The transaction is either committed or rolled back based on the action taken at the end of the outermost transaction. If the outer transaction is committed, the inner nested transactions are also committed. If the outer transaction is rolled back, then all inner transactions are also rolled back, regardless of whether or not the inner transactions were individually committed.

Dotnet Interview Question

1. What is Property? A property is a member that provides a flexible mechanism to read, write, or compute the value of a private field. Properties can be used as if they are public data members, but they are actually special methods called accessors . This enables data to be accessed easily and still helps promote the safety and flexibility of methods. Example: class TimePeriod { private   double seconds; public   double Hours { get { return seconds / 3600; } set { seconds = value * 3600; } } }   2. What is the difference between abstraction and encapsulation? Abstraction: Abstraction lets you focus on what the object does instead of how it does it That means we use the object without knowing the source code of the class. Encapsulation: Encapsulation means hiding the internal details or mechanics of how an object does something. Encapsulation is warping data into single unit. 3. What is the difference between c...

AMAZON - Create SSL Certificate for a Load Balancer

AMAZON - Create SSL Certificate for a Load Balancer This section describes the process of generating a server certificate and preparing it to use with AWS products through IAM. To create a certificate, you perform a series of tasks as described by the following topics. Note: If you want to create user signing certificate that you can use to sign SOAP requests in EC2, see Creating and Uploading a User Signing Certificate Topics Install and Configure OpenSSL Create a Private Key Create a Certificate Signing Request Submit the CSR to a Certificate Authority Install and Configure OpenSSL Creating and uploading a certificate requires a tool that supports the SSL and TLS protocols. OpenSSL is an open-source tool that provides the basic cryptographic functions necessary to create an RSA token and sign it with your private key. If you don't already have OpenSSL installed, follow the instructions in this section. To install OpenSSL on Wi...

Steps to update SSL Certificate on Amazon Elastic Load Balancer

Sign in to the AWS Management Console and open the Amazon EC2 console at https://console.aws.amazon.com/ec2/. On the Amazon EC2 Getting Started page, in the EC2 Dashboard pane, under NETWORK & SECURITY, click Load Balancers. On the Load Balancers page, select your load balancer. The bottom pane displays the details of your load balancer. Click the Listeners tab. Click Change in the SSL Certificate column of the certificate you want to update. On the Configure SSL Certificate page, select Choose from your existing SSL Certificates to use previously uploaded SSL certificate and select the certificate from the drop-down box. Or, select Upload a new SSL Certificate if you have a SSL certificate and want to uploaded it. Before you upload, ensure that your certificate meets the following citeria: Certificates must follow the X.509 PEM format. The current date...

Steps to Create SSL Certificate for Amazon Elastic Load Balancer and Update SSL Certificate on Elastic Load Balancer

his section describes the process of generating a server certificate and preparing it to use with AWS products through IAM. To create a certificate, you perform a series of tasks as described by the following topics. Note: If you want to create user signing certificate that you can use to sign SOAP requests in EC2, see Creating and Uploading a User Signing Certificate Topics Install and Configure OpenSSL Create a Private Key Create a Certificate Signing Request Submit the CSR to a Certificate Authority To update an SSL certificate for an HTTPS load balancer Sample server certificate Install and Configure OpenSSL Creating and uploading a certificate requires a tool that supports the SSL and TLS protocols. OpenSSL is an open-source tool that provides the basic cryptographic functions necessary to create an RSA token and sign it with your private key. If you don't already have OpenSSL installed, follow the instructions in this section. ...

Configure VPC with scenario 1 "VPC with a Public Subnet Only"

Set up the VPC, subnet, and Internet gateway: Open the Amazon VPC console at https://console.aws.amazon.com/vpc/ . Click VPC Dashboard in the navigation pane. Locate the Your Virtual Private Cloud area of the dashboard and clicks get started creating a VPC, if you have no VPC resources, or click Start VPC Wizard. Select the first option, VPC with a Single Public Subnet Only, and then click Continue. The confirmation page shows the CIDR ranges and settings that you've chosen. Make any changes that you need, and then click Create VPC to create your VPC, subnet, Internet gateway, and route table. Create WebServerSG and Adding Rules to the Security Group The WebServerSG security group is the security group that you'll specify when you launch your web servers into your public subnet. The following table describes the recommended rules for th...