On Tue, Aug 23, 2011 at 11:47:42PM +0300, Zeeshan Ali (Khattak) wrote: > From: "Zeeshan Ali (Khattak)" <[email protected]> > > Renaming osinfo_media_new_from_location() to > osinfo_media_create_from_location() to emphasize the factory nature > of this function. > > Also the convention in g* world is to keep _new() as only thin wrappers > around g_object_new() calls. > --- > docs/reference/Libosinfo-sections.txt | 2 +- > osinfo/libosinfo.syms | 2 +- > osinfo/osinfo_media.c | 8 ++++---- > osinfo/osinfo_media.h | 6 +++--- > 4 files changed, 9 insertions(+), 9 deletions(-) > > diff --git a/docs/reference/Libosinfo-sections.txt > b/docs/reference/Libosinfo-sections.txt > index e44b5ae..e2454da 100644 > --- a/docs/reference/Libosinfo-sections.txt > +++ b/docs/reference/Libosinfo-sections.txt > @@ -403,7 +403,7 @@ OsinfoMedia > OsinfMediaoClass > OsinfMediaoPrivate > osinfo_media_new > -osinfo_media_new_from_location > +osinfo_media_create_from_location > osinfo_media_get_architecture > osinfo_media_get_url > osinfo_media_get_volume_id > diff --git a/osinfo/libosinfo.syms b/osinfo/libosinfo.syms > index 0e9751d..6541a90 100644 > --- a/osinfo/libosinfo.syms > +++ b/osinfo/libosinfo.syms > @@ -143,7 +143,7 @@ LIBOSINFO_0.0.1 { > osinfo_media_get_type; > osinfo_media_error_quark; > osinfo_media_new; > - osinfo_media_new_from_location; > + osinfo_media_create_from_location; > osinfo_media_get_architecture; > osinfo_media_get_url; > osinfo_media_get_volume_id; > diff --git a/osinfo/osinfo_media.c b/osinfo/osinfo_media.c > index 449f45a..431ae72 100644 > --- a/osinfo/osinfo_media.c > +++ b/osinfo/osinfo_media.c > @@ -127,7 +127,7 @@ OsinfoMedia *osinfo_media_new(const gchar *id, > } > > /** > - * osinfo_media_new_from_location: > + * osinfo_media_create_from_location: > * @location: the location of an installation media > * @cancellable (allow-none): a #GCancellable, or %NULL > * @error: The location where to store any error, or %NULL > @@ -139,9 +139,9 @@ OsinfoMedia *osinfo_media_new(const gchar *id, > * > * Returns: (transfer full): a new #OsinfoMedia , or NULL on error > */ > -OsinfoMedia *osinfo_media_new_from_location(const gchar *location, > - GCancellable *cancellable, > - GError **error) > +OsinfoMedia *osinfo_media_create_from_location(const gchar *location, > + GCancellable *cancellable, > + GError **error) > { > OsinfoMedia *ret = NULL; > PrimaryVolumeDescriptor pvd; > diff --git a/osinfo/osinfo_media.h b/osinfo/osinfo_media.h > index 9d68c6e..89eb1f6 100644 > --- a/osinfo/osinfo_media.h > +++ b/osinfo/osinfo_media.h > @@ -98,9 +98,9 @@ struct _OsinfoMediaClass > GType osinfo_media_get_type(void); > > OsinfoMedia *osinfo_media_new(const gchar *id, const gchar *architecture); > -OsinfoMedia *osinfo_media_new_from_location(const gchar *location, > - GCancellable *cancellable, > - GError **error); > +OsinfoMedia *osinfo_media_create_from_location(const gchar *location, > + GCancellable *cancellable, > + GError **error); > > const gchar *osinfo_media_get_architecture(OsinfoMedia *media); > const gchar *osinfo_media_get_url(OsinfoMedia *media);
ACK Daniel -- |: http://berrange.com -o- http://www.flickr.com/photos/dberrange/ :| |: http://libvirt.org -o- http://virt-manager.org :| |: http://autobuild.org -o- http://search.cpan.org/~danberr/ :| |: http://entangle-photo.org -o- http://live.gnome.org/gtk-vnc :| _______________________________________________ virt-tools-list mailing list [email protected] https://www.redhat.com/mailman/listinfo/virt-tools-list
