diff.h #1

  • //
  • guest/
  • samwise/
  • p4hl/
  • src/
  • dlls/
  • diff.h
  • View
  • Commits
  • Open Download .zip Download (1 KB)
/*
 * Copyright 1997 Perforce Software.  All rights reserved.
 *
 * This file is part of Perforce - the FAST SCM System.
 *
 * Diff code written by James Strickland, May 1997.
 */

/*
 * Diff walkers: produce output according to diff style by walking
 * the diff results.
 *
 *	Diff::Diff - set up for diff output
 *	Diff::DiffWithFlags - produces diff output according to flags
 *	Diff::DiffContext - produces diff -c output to a file
 *	Diff::DiffUnified - produces diff -u output to a file
 *	Diff::DiffNorm - produces normal diff output to a file
 *	Diff::DiffRcs - produces diff -n output to a file
 *	Diff::DiffHTML - produces html markup
 *	Diff::DiffSummary - produces a single summary line
 *
 *	Diff::CloseOutput - finish write and collect error status
 */

class DiffAnalyze;
class Sequence;
struct Snake;
typedef signed int LineNo;

class Diff {

    public:

			Diff();
			~Diff();

	void		SetInput( const char *fx, const char *fy, 
				const char *flags, Error *e );
	void		SetOutput( const char *fout, Error *e );
	void		SetOutput( FILE *fout );
	void		CloseOutput( Error *e );

	void		DiffWithFlags( const char *flags );

	void		DiffContext( int c = 0 );
	void		DiffUnified( int c = 0 );
	void		DiffNorm();
	void		DiffRcs();
	void		DiffHTML();
	void		DiffSummary();

    private:

	void		Walker( const char *flags, Sequence *s, 
				LineNo sx, LineNo sy );

	Sequence	*spx;
	Sequence	*spy;
	FILE		*out;
	DiffAnalyze	*diff;
	int		closeOut;
	LineType	lineType;
	const char	*newLines;

} ;

# Change User Description Committed
#2 937 Sam Stafford Renaming my guest directory to the more conventional
sam_stafford.
#1 936 Sam Stafford Adding P4HL to the public depot.
 See relnotes.txt for
installation instructions; all relevant files are under
p4hl/dist.

Source code is under p4hl/src in the form of a VC++ project.