User Tools

Site Tools


study_questions_lucky_dip_creation

This is an old revision of the document!


Study Questions - Lucy Dip Creation

1. Copy the source of the questions and paste into Notepad++.

2. Remove the tag bit at the bottom.

3. In regular expression mode, replace

^====+.+====$

with nothing.

4. In extended mode, replace

/* --== Answer Question separator ==-- */

with

<html>\n      </td>\n    </tr>\n    <tr>\n      <td width="50%">\n</html>\n

5. In extended mode, replace

/* --== Question Answer separator ==-- */

with

\n<html>\n      </td>\n      <td width="50%">\n</html>

6. Replace the first html element with

<html>
  <table border="1" width="100%">
    <tr>
      <td width="50%">
</html>

7. Add this to end

<html>
      </td>
    </tr>
</html>

8. Select all and copy to the clipboard.

9. Goto http://tallguyracing.com/wiki/doku.php?id=playground:playground and edit.

10. Paste from the clipboard and save it.

11. Select it (including the RSS XML Feed etc buttons).

12. Open a new document in OpenOffice and paste the contents into it.

13. Set the Zoom to 73% (so that there are two pages per screen).

14. Delete all the crap at the top.

15. Load styles → Lucky Dip, Text + Pages + Overwrite.

16. Right click table → Table… → Text Flow tab → Untick Allow row to break…

17. For each page,

17.1. Put the cursor in the last row of the page.

17.2. Click the Insert Row button lots.

17.3. Copy and paste the all the cells on the first page to the second. Note that this will overwrite the cells, so if there are not some blanks leftover, undo and go back to 17.2.

17.4. Delete the blank cells.

18. Highlight the right columns of odd pages and the left columns of the even pages (inside ones if two pages are displayed at once), change the background colour to black. Also, look for numbered bullet lists in the right column of the even pages and reset the numbering.

19. Select everything and paste into the master StudyQuestions file.

Questions To Be Lucky Dipped

Chapter 3: The Basic Tools

PragC3Q1: What are the three benefits of plain text?

Answer:

  • Insurance against obsolescence
  • Leverage
  • Easier testing

PragC3Q2: What are three situations that make tracing statements invaluable?

Answer:

  • Concurrent processes
  • Real-time systems
  • Event-based applications

C13L1Q11: How are COM types that are defined in an assembly used differently from other managed types?

Answer: They aren't used differently (tricky).

C13L1Q12: How is compiling an interop project different from compiling a managed project?

Answer: It isn't different (tricky).

C13L1Q13: What three things does an interop application contain?

Answer:

  • A .NET client assembly.
  • One or more interop assemblies.
  • One or more registered COM components.

C13L1Q14: Where should private assemblies be installed?

Answer: The same directory as the application.

C13L1Q15: What must a shared assembly have and where is it installed?

Answer: It must have a strong name and be installed in the Global Assembly Cache (GAC).

C13L1Q16: What is a primary interop assembly?

Answer: A unique, vendor-supplied, strong named, interop assembly that contains type definitions (as metadata) of types implemented with COM.

C13L2Q4: What are the five guidelines for qualifying .NET types for interoperation?

Answer:

  • Classes should implement interfaces explicitly.
  • Managed types must be public.
  • Methods, properties, fields and events must be public.
  • Types must have a public default constructor to be activated from COM.
  • Types can not be abstract.

C13L2Q5: What public parts of a class are not exposed to COM clients?

Answer: Parameterised constructors, static methods and constant fields.

C13L2Q6: What does the Assembly Registration tool do and what .NET class provides the equivalent functionality?

Answer: The Assembly Registration tool generates a type library and then registers it so that COM clients can use the .NET class transparently, or it can unregister an assembly. The equivalent class is RegistrationServices.

C13L2Q7: What is the difference between the Type Library Exporter and the Assembly Registration tool?

Answer: The Type Library Exporter generates a type library but does not register it. The Assembly Registration tool does both.

C13L2Q8: How do you use the Type Library Exporter to generate a subset of the types defined in an assembly?

Answer: You can't - the entire assembly is converted at once (tricky).

study_questions_lucky_dip_creation.1252461663.txt.gz · Last modified: 2017/01/01 19:54 (external edit)

Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki