Program Question
Results 1 to 10 of 10

Thread: Program Question

  1. #1
    Registered User
    Join Date
    Oct 2000
    Location
    US
    Posts
    87

    Post Program Question

    Can someone tell me what the difference is between: Object Program and Source Program.

    Thanks!

  2. #2
    Registered User
    Join Date
    Sep 2000
    Posts
    1,965

    Post

    The object is the compiled version *PGM or on a PC it would be the .exe

    The source is the actual file containing the source code.

    I'm just using references from the AS/400, so correct me if I'm wrong.

  3. #3
    Registered User dead's Avatar
    Join Date
    Feb 2001
    Location
    St. Cloud MN
    Posts
    45

    Post

    I would agree with QSECOFR.

  4. #4
    Registered User
    Join Date
    Jan 2001
    Location
    Aurora, IL
    Posts
    340

    Post

    Isn't Object Oriented programming the use of pre-built libraries? Like Visual Basic or Visual C++?

  5. #5
    Registered User
    Join Date
    Sep 2000
    Posts
    1,965

    Post

    (OOP) The use of a class of programming languages and techniques based on the concept of an "object" which is a data structure (abstract data type) encapsulated with a set of routines, called "methods", which operate on the data.

  6. #6
    Intel Mod Platypus's Avatar
    Join Date
    Jan 2001
    Location
    Australia
    Posts
    5,783

    Post

    This may or may not help, from my DOS programming days. Are you referring to Source Code and Object Code? If so, as said before the Program Source Code is the instruction sequence written in the programming language, which is then compiled with a Compiler.

    The compiler may produce an executable file directly, if all the instructions used can be translated directly to machine code. If any instructions use calls to an external library, the compiler cannot resolve those, and will produce a file containing Object Code. This is not directly executable, since it refers to machine code contained in a library file. The Object File must then be processed by a Linker, which will assemble an executable which either contains the code drawn from the library file, or looks for the library when run (the Dynamic Link Library - DLL - principle).

    If this is not what you are asking about, ignore this ramble. I just miss programming.

  7. #7
    Mach5
    Guest

    Post

    This example you gave is useful for languages as DOS Pascal and Clipper, where the compiling (translate to machine language) and linkediting (link of the external sources of code (libraries) to the object code) processes were separated. (in Pascal compilers, maybe the programming environment could do both processes in one command, but they were 2 separated procedures.

    So, you (cheetah) have (at least) three answers:

    - for DOS languages, the source code is the code you typed; and the object code is the compiled (machine-language translated) version of a program, but not ready to run.
    - for AS/400 environment, the source code is still the code you typed, and the object code is the compiled version, too. On this, usually is not necessary the linkediting process, because all the libraries used for programming are available (as a mainframe system) for all programs.
    - for Visual languages (as VB or Delphi) object code could be the code "tied" with the objects you use for creating a program, and the source code could be the code you store in "modules". In these environments, the concept of code in objects and code in modules is some confused to understand.

    Excuse me for the long message!

    Greetings,

  8. #8
    ~torn~
    Guest

    Thumbs up

    QSECOFR is correct. I write RPG on the AS/400 but am a newbie. You first must create the source, debug & compile, when the compile completes you have your object.

  9. #9
    Registered User
    Join Date
    Sep 2000
    Posts
    1,965

    Post

    I'm just glad to see that I'm not the only AS/400 guy here! Where I work, we run over 1000 COBOL, and about 12 RPG progs.

    Originally posted by ~torn~:
    QSECOFR is correct. I write RPG on the AS/400 but am a newbie. You first must create the source, debug & compile, when the compile completes you have your object.

  10. #10
    Registered User
    Join Date
    Oct 2000
    Location
    Kansas City, MO
    Posts
    1,162

    Post

    Object Programming is mostly coded with C++ or VB.

    Object Programming is an Object

    Think of a Coffey Machine.

    The Coffey Machine contains Properties and Methods.

    Properties are the whay it looks, the size, the color, the name, the way it operates for methods like, temprature, water level, type of coffey, etc etc...

    Methods are operations that the Coffey Machine can do. monitor temp, set the alarm, monitor water level, turn on, turn off, etc etc...

    Source Code is just code: Meaning the lanuage you use to program your app or what ever. Every program has source code. The source code is what is compiled making an .exe, .dll, .ocx, etc etc...

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •