IT SOLUTIONS
Your full service technology partner! 
-Collapse +Expand
Coder
Search Coder Group:

Advanced
-Collapse +Expand Coder Study Test
PRESTWOODCERTIFIED
-Collapse +Expand Coder Store
PRESTWOODSTORE

Prestwood eMagazine

January Edition
Subscribe now! It's Free!
Enter your email:

   ► KBCoder Knowledge Base  Print This    All Groups  

Coder Flashcards Library

These FlashCards are contributed by you (our online community members). They are organized by our knowledge base topics. Specifically, by the Coder sub-topics.

Contribute a Flashcard

41 Coding & OO FlashCards

Group: Coding & OO


Topic: General Info, Installation, etc.

Q&A: Managed Code versus Native Code
Question: What are the benefits of managed code over native code?

Answer:

In general terms, managed .Net code is a little more portable (will run on any platform with the correct CLR installed) and is easier to write. However, managed code may run slower and require more system resources.

Posted By Mike Prestwood, Post #101243, KB Topic: General Info, Installation, etc.



Topic: Borland Database Engine

Definition

BDE Alias

Definition:

A BDE Alias or alias refers to a database location. For Paradox, dBASE, and other local tables, the location of the database is the location of the data files. You manage your aliases using the Borland Database Engine (BDE) located in your Control Panel.

Posted By Mike Prestwood, Post #100618, KB Topic: Borland Database Engine



Topic: General .Net Concepts

Definition

Class

Definition:

The class is the basis of OO programming. It is a body of code that is used as a blueprint.  When loaded into memory it is refered to as an instance or object. 

Posted By Daniel Fought, Post #100866, KB Topic: General .Net Concepts
Definition

Namespace

Definition: A namespace concept is very similar to the folder concept.  Namespaces are used extensively in the .Net framework to group related code.  A namespace can contain both namespaces and classes.  Take for example the two namespaces A and B which contain a class named "something" which has a method named "move".  The calls A.something.move() and B.something.move() could execute  entirely differnt code
Posted By Daniel Fought, Post #100865, KB Topic: General .Net Concepts
Send Email Using C#

This code snippet will send a very quick email. Note that this code will not work as-is. You need to have valid email accounts and a valid email server to send a real email.

You need to add: using System.Net.Mail;

 

MailMessage myMessage = new MailMessage(
"fromaddress@somewhere.com", "toaddress@somewhere.com",
"Subject", "Message Body.");
 
SmtpClient mySMTPClient = new SmtpClient("mailserver.somewhere.com"); 
mySMTPClient.Send(myMessage);
Posted By Bryan Valencia, Post #101323, KB Topic: General .Net Concepts



Topic: General Coding Concepts

Definition

API

Definition:

API is an acronym for application programming interface. The Windows API is the set of DLLs that makes up Windows. It comprises all the functions, messages, data structures, data types, statements, and files that a programmer needs for developing Windows applications.

Posted By Mike Prestwood, Post #100180, KB Topic: General Coding Concepts
Definition

Array

Definition:

A data type that is a collection of variables (much like a table is a collection of fields). There are two types: fixed and resizable. A fixed array has a predetermined--by the programmer--number of elements. A resizable does not; therefore you need to set its size before using it.

Posted By Mike Prestwood, Post #100181, KB Topic: General Coding Concepts
Definition

Associative Array

Definition:

A set of unique keys linked to a set of values. Each unique key is associated with a value. A two column table is an example of an associative array.

Example:

MyArray['CA'] = 'California'
MyArray['AR'] = 'Arizona'

Posted By Mike Prestwood, Post #101197, KB Topic: General Coding Concepts
Definition

Black Box

Definition: The term black box refers to not being able to see what is within the box. For example, in coding, you do not need to concern yourself with the details of what happens when you call a method, you simply use the method, the black box, to do the thing you wanted it to do. This is also called encapsulation.
Posted By Mike Prestwood, Post #100612, KB Topic: General Coding Concepts
Tip: Branching: Frequent Conditions First

Most languages support a branching mechanism like if a..elseif b..elseif c. If a evaluates to true, b and c will not execute. The tip is to sort your branching conditions by most to lease used for faster code.

Posted By Mike Prestwood, Post #101764, KB Topic: General Coding Concepts
Definition

Computer Language Constants

Definition:

A constant is just like a variable (it holds a value) but, unlike a variable, you cannot change the value of a constant.

Posted By Mike Prestwood, Post #101710, KB Topic: General Coding Concepts
Definition

Computer Language Operator

Definition:

A language symbol used for assignment, comparison, computational, or as a logical.

Posted By Mike Prestwood, Post #101330, KB Topic: General Coding Concepts
Definition

Computer Language Statement

Definition:

An elementary instruction or other elementary component in a high-level programming language. When documenting a programming language, tech writers usually separate statements from operators, functions, procedures, and objects.

Posted By Mike Prestwood, Post #101329, KB Topic: General Coding Concepts
Definition

Event Handler

Definition

Inline Routines

Definition:

Instead of calling a routine, you move the code from the routine itself and expand it in place of the call. In addition to manual inlining, some languages support automatic inlining where the compiler or some other pre-compiler decides when to inline a code routine. Also, some languages allow for developer defined inlining where the developer can suggest and/or force the inlining of a code routine. Inlining can optimize your code for speed by saving a call and return, and parameter management.

Posted By Mike Prestwood, Post #101858, KB Topic: General Coding Concepts
Definition

Overloading

Definition:

Types of overloading include method overloading and operator overloading.

Method Overloading is where different functions with the same name are invoked based on the data types of the parameters passed or the number of parameters. Method overloading is a type of polymorphism and is also known as Parametric Polymorphism.

Operater Overloading allows an operator to behave differently based on the types of values used. For example, in some languages the + operator is used both to add numbers and to concatenate strings. Custom operator overloading is sometimes referred to as ad-hoc polymorphism.

Posted By Mike Prestwood, Post #101457, KB Topic: General Coding Concepts
Definition

Pointers / References

Definition:

A pointer is a variable type that allows you to refer indirectly to another object. Instead of holding data, a pointer holds the address to data -- the address of another variable or object. You can change the address value a pointer points to thus changing the variable or object the pointer is pointing to.

A reference is a type of pointer that cannot change and it must always point to a valid storage (no nulls).

Posted By Mike Prestwood, Post #101915, KB Topic: General Coding Concepts
Definition

Programming Literals

Definition:

A value directly written into the source code of a computer program (as opposed to an identifier like a variable or constant). Literals cannot be changed. Common types of literals include string literals, floating point literals, integer literals, and hexidemal literals. Literal strings are usually either quoted (") or use an apostrophe (') which is often referred to as a single quote. Sometimes quotes are inaccurately referred to as double quotes.

Posted By Mike Prestwood, Post #101817, KB Topic: General Coding Concepts
Tip: Round Floating Point Numbers

When comparing floating point numbers, make sure you round to an acceptable level of rounding for the type of application you are using.

Posted By Mike Prestwood, Post #101911, KB Topic: General Coding Concepts
Definition

Stack

Definition:

A data structure that supports adding (a push) and removing (a pop) elements based on last in, first out ordering. Data that is pushed into a stack will be popped out in reverse order. For example, if a b c and d are pushed into a stack. d c b and then a will be popped out.

Other supported operations include:
empty(): tests if the stack is empty.
peek(): returns the object on the top of the stack without removing it.

Posted By Stephen Berry, Post #101257, KB Topic: General Coding Concepts
Definition

Unary Operator

Definition:

Examples:

-a
+b
-(a + b)

Bitwise Not

bitwise not (usually either Not or !). Some operators can function as both unary and binary operators. For example, + and - operators can serve as either.

Not(a + b) ...some languages use !(a + b)

 

Posted By Mike Prestwood, Post #101331, KB Topic: General Coding Concepts



Topic: General Tasks

Q&A: Enable ASP.Net (ASPX)
Question: How do you enable ASP.Net (ASPX) in IIS 6?

Answer:

You turn on ASPX in your control panel. Depending on what O/S and version of IIS there are slightly different steps required but essentially you go to the Add/Remove Programs, Alter Windows Components, and make sure ASPX is checked in the Application Server or Application Development Services.

More Info / Details - http://support.microsoft.com/default.aspx?scid=kb;en-us;332124&Product=winsvr2003

Posted By Mike Prestwood, Post #100945, KB Topic: General Tasks
Tip: Using Paradox Tables with .NET

Although the .NET Framework is well "tuned" for MS SQL Server, it can also be pressed into service with other databases.

A somewhat unusual case is using ASP .NET to access and modify data in Paradox tables.  If you're going to do that, the most important thing to know is which ODBC driver to use - because you will be using an ODBC Driver.

The driver to use was created by Intersolv and bundled with Paradox v9. That driver has a version designation of v3.11

Posted By Wes Peterson, Post #102076, KB Topic: General Tasks



Topic: Object Orientation (OO)

Definition

Abstract Class / Abstract Member

Definition:

An abstract class member is a member that is specified in a class but not implemented. Classes that inherit from the class will have to implement the abstract member. Abstract members are a technique for ensuring a common interface with descendant classes. An abstract class is a class you cannot instantiate. A pure abstract class is a class with only abstract members.

Posted By Mike Prestwood, Post #100811, KB Topic: Object Orientation (OO)
Definition

Aggregation

Definition:

Aggregations indicate a whole-part relationship, and are known as "has-a" or "is part of" relationships. An Aggregation relationship is indicated by a line with a hollow diamond.

Posted By Mike Prestwood, Post #101263, KB Topic: Object Orientation (OO)
Definition

Class Constructor

Definition

Class Destructor

Definition:

A special class method called when an object instance of a class is destroyed. With some languages they are called when the object instance goes out of scope, with some languages you specifically have to call the destructor in code to destroy the object, and others use a garbage collector to dispose of object instances at specific times.

Desctructors are commonly used to free the object instance but with languages that have a garbage collector object instances are disposed of when appropriate. Either way, destructors or their equivalent are commonly used to free up resources allocated in the class constructor.

Posted By Mike Prestwood, Post #101843, KB Topic: Object Orientation (OO)
Definition

Class Helper

Definition:

A. In Dephi, class helpers allow you to extend a class without using inheritance. With a class helper, you do not have to create and use a new class descending from a class but instead you enhance the class directly and continue using it as you always have (even just with the DCU).

B. In general terms, developers sometimes use the term to refer to any class that helps out another class.

Posted By Mike Prestwood, Post #101868, KB Topic: Object Orientation (OO)
Definition

Class Visibility Specifiers

Definition: In OOP languages, members of a class have a specific scope that indicates visibility. Standard visibility includes private, protected, and public. Private members are usable by the defining class only (fully encapsulated). They are invisible outside of the class except by friendly classes. Protected members are usable by the defining class and descendant classes only (plus friendly classes). Public members are usable wherever its class can be referenced.
Posted By Mike Prestwood, Post #101489, KB Topic: Object Orientation (OO)
Definition

Code Contract

Definition:

A.k.a. Class Contract and Design by Contracts.

A contract with a method that must be true upon calling (pre) or exiting (post). A pre-condition contract must be true when the method is called. A post-condition contract must be true when exiting. If either are not true, an error is raised. For example, you can use code contracts to check for the validity of input parameters, and results

An invariant is also a code contract which validates the state of the object required by the method.

Posted By Mike Prestwood, Post #101927, KB Topic: Object Orientation (OO)
Definition

Composition

Definition: A composite relationship means that a class cannot exist by itself. It must exist as a member of another class. A composite relationship is indicated by a solid line with a solid diamond head pointing to the part class. Alternatively, you can show this relationship graphically with the part class nested in the whole class.
Posted By Mike Prestwood, Post #101261, KB Topic: Object Orientation (OO)
Definition

Encapsulation

Definition: Hidden data and methods. Encapsulation is the hiding of data and code and is often called the "black box" approach, since users of a class can't see inside the class (they can only see the class' public interface).
Posted By Mike Prestwood, Post #100812, KB Topic: Object Orientation (OO)
Definition

Inheritance

Definition:

The concept of a class makes it possible to define subclasses that share some or all of the main class characteristics. This is called inheritance. Inheritance also allows you to reuse code more efficiently. In a class tree, inheritance is used to design classes vertically. (You can use Interfaces to design classes horizontally within a class tree.) With inheritance, you are defining an "is-a" relationship (i.e. a chow is-a dog). Analysts using UML call this generalization where you generalize specific classes into general parent classes.

Posted By Mike Prestwood, Post #100813, KB Topic: Object Orientation (OO)
Definition

Interface

Definition:

An element of coding where you define a common set of properties and methods for use with the design of two or more classes.

Both interfaces and abstract classes are types of abstraction. With interfaces, like abstract classes, you cannot provide any implementation. However, unlike abstract classes, interfaces are not based on inheritance. You can apply an Interface to any class in your class tree. In a real sense, interfaces are a technique for designing horizontally in a class hierarchy (as opposed to inheritance where you design vertically). Using interfaces in your class design allows your system to evolve without breaking existing code.

Posted By Mike Prestwood, Post #101333, KB Topic: Object Orientation (OO)
Definition

Member Event

Definition

Member Field

Definition:

Also known as a Class Field.

A class variable defined with a specific class visibility, usually private visibility. A member property is different than a member field. A member property uses a member field to store values through accessor methods (getters and setters). For example, it is common to use a private member field to store the current value of a property. The current values of all the class member fields is the current state of the object.

Posted By Mike Prestwood, Post #101754, KB Topic: Object Orientation (OO)
Definition

Member Method

Definition:

Also known as a Class Method.

A code routine that belongs to the class or an object instance (an instance of the class). Methods that belong to the class are called class methods or static methods. Methods that belong to an object instance are called instance methods, or simply methods.

When a method returns a value, it is a function method. When no value is returned (or void), it is a procedure method.

Methods frequently use method parameters to transfer data. When one object instance calls another object instance using a method with parameters, you call that messaging.

Posted By Mike Prestwood, Post #101844, KB Topic: Object Orientation (OO)
Definition

Method Overriding

Definition

Partial Class

Definition:

A partial class, or partial type, is a class that can be split into two or more source code files and/or two or more locations within the same source file. Each partial class is known as a class part or just a part. Logically, partial classes do not make any difference to the compiler. The compiler puts the class together at compile time and treats the final class or type as a single entity exactly the same as if all the source code was in a single location.

Posted By Mike Prestwood, Post #101791, KB Topic: Object Orientation (OO)
Definition

Polymorphism

Definition:

A coding technique where the same named function, operator, or object behaves differently depending on outside input or influences. Usually implemented as parameter overloading where the same named function is overloaded with other versions that are called either with a different type or number of parameters. Polymorphism is a general coding technique and other specific implementations are common such as inheritance, operator overloading, and interfaces.

Posted By Mike Prestwood, Post #100142, KB Topic: Object Orientation (OO)
Definition

Static Class / Static Member

Definition:

A static member is a member you can have access to without instantiating the class into an object. For example, you can read and write static properties and call static methods without ever creating the class. Static members are also called class members (class methods, class properties, etc.) since they belong to the class and not to a specific object. A static class is a class that contains only static members. In the UML, these classes are described as utility classes.

Posted By Mike Prestwood, Post #101477, KB Topic: Object Orientation (OO)
-
   Contact Us!
 
Have a question? Need our services? Contact us now.
--Mike Prestwood

Call: 916-726-5675

email: info@prestwood.com


Go ahead!   Use Us! Call: 916-726-5675 


©1995-2018 Prestwood IT Solutions.   [Security & Privacy]