Chapter 8. Embedding Subversion

Table of Contents

Layered Library Design
Repository Layer
Repository Access Layer
Client Layer
Inside the Working Copy Administration Area
The Entries File
Pristine Copies and Property Files
Using the APIs
The Apache Portable Runtime Library
URL and Path Requirements
Using Languages Other Than C and C++
Code Samples
Summary

Subversion has a modular design: it's implemented as a collection of libraries written in C. Each library has a well-defined purpose and application programming interface (API), and that interface is available not only for Subversion itself to use, but for any software that wishes to embed or otherwise programmatically control Subversion. Additionally, Subversion's API is available not only to other C programs, but also to programs written in higher-level languages such as Python, Perl, Java, and Ruby.

This chapter is for those who wish to interact with Subversion through its public API or its various language bindings. If you wish to write robust wrapper scripts around Subversion functionality to simplify your own life, are trying to develop more complex integrations between Subversion and other pieces of software, or just have an interest in Subversion's various library modules and what they offer, this chapter is for you. If, however, you don't foresee yourself participating with Subversion at such a level, feel free to skip this chapter with the confidence that your experience as a Subversion user will not be affected.