refs-common.c: move head_ref_namespaced to the common file

Signed-off-by: Ronnie Sahlberg <sahlberg@google.com>
refs.c: add a backend method structure with transaction functions

Add a ref structure for backend methods. Start by adding method pointers
for the transaction functions.

Rename the existing transaction functions to files_* and make them static.
Add new transaction functions that just pass through to the appropriate
methods for the backend.

Signed-off-by: Ronnie Sahlberg <sahlberg@google.com>
refs.c: add reflog backend methods

Add methods for the reflog functions.

Signed-off-by: Ronnie Sahlberg <sahlberg@google.com>
refs.c: add methods for misc ref operations

Add ref backend methods for
	resolve_ref_unsafe_fn resolve_ref_unsafe;
	is_refname_available_fn is_refname_available;
	pack_refs_fn pack_refs;
	peel_ref_fn peel_ref;
	create_symref_fn create_symref;
	resolve_gitlink_ref_fn resolve_gitlink_ref;

Signed-off-by: Ronnie Sahlberg <sahlberg@google.com>
refs.c: add methods for head_ref*

Add methods for the head_ref* functions.

Signed-off-by: Ronnie Sahlberg <sahlberg@google.com>
refs.c: add methods for the ref iterators

Signed-off-by: Ronnie Sahlberg <sahlberg@google.com>
refs-be-files.c: rename refs.c to refs-be-files.c

Signed-off-by: Ronnie Sahlberg <sahlberg@google.com>