Exemplo n.º 1
0
        public string ToString(bool Simple)
        {
            try
            {
                StringBuilder result = new StringBuilder();
                if (Simple)
                {
                    result.Append(TitreSerie.RawTitle);
                }
                else
                {
                    result.Append(TitreSerie.ToString());
                }

                StringBuilder dummy = new StringBuilder();
                StringUtils.AjoutString(dummy, EditeurSerie.NomEditeur.ToString(), " ");
                StringUtils.AjoutString(dummy, CollectionSerie.NomCollection.ToString(), " - ");
                StringUtils.AjoutString(result, dummy, " ", "(", ")");
                return(result.ToString());
            }
            catch (Exception Ex)
            {
                return(string.Format("Erreur dans {0}.ToString(): {1}", Ex.GetType().Name, Ex.Message));
            }
        }
Exemplo n.º 2
0
        public string ToString(bool simple)
        {
            StringBuilder result = new StringBuilder();

            if (simple)
            {
                result.Append(Titre.RawTitle);
            }
            else
            {
                result.Append(Titre.ToString());
            }

            StringBuilder dummy = new StringBuilder();

            StringUtils.AjoutString(dummy, Série.ToString(), " - ");
            if (Integrale)
            {
                StringBuilder dummy2 = new StringBuilder(StringUtils.NotZero(TomeDebut.ToString()));
                StringUtils.AjoutString(dummy2, StringUtils.NotZero(TomeFin.ToString()), " à ");
                StringUtils.AjoutString(dummy, "INT.", " - ", string.Empty, (" " + StringUtils.NotZero(Tome.ToString())).Trim());
                StringUtils.AjoutString(dummy, dummy2, " ", "[", "]");
            }
            else if (HorsSérie)
            {
                StringUtils.AjoutString(dummy, "HS", " - ", String.Empty, (" " + StringUtils.NotZero(Tome.ToString())).Trim());
            }
            else
            {
                StringUtils.AjoutString(dummy, StringUtils.NotZero(Tome.ToString()), " - ", "T. ");
            }
            StringUtils.AjoutString(result, dummy, " ", "(", ")");
            return(result.ToString());
        }
Exemplo n.º 3
0
        public override System.String ToString()
        {
            StringBuilder result = new StringBuilder("");

            StringUtils.AjoutString(result, fEditeurEdition.NomEditeur.ToString(), " ");
            StringUtils.AjoutString(result, fCollectionEdition.NomCollection.ToString(), " ", "(", ")");
            StringUtils.AjoutString(result, StringUtils.NotZero(fAnnéeEdition.ToString()), " ", "[", "]");
            StringUtils.AjoutString(result, StringUtils.FormatISBN(fISBN), " - ", "ISBN ");
            return(result.ToString());
        }
Exemplo n.º 4
0
        public override string ToString()
        {
            StringBuilder result = new StringBuilder();

            StringUtils.AjoutString(result, Editeur.NomEditeur.ToString(), " ");
            StringUtils.AjoutString(result, Collection.NomCollection.ToString(), " ", "(", ")");
            StringUtils.AjoutString(result, StringUtils.NotZero(AnnéeEdition.ToString()), " ", "[", "]");
            StringUtils.AjoutString(result, ISBN, " - ", "ISBN ");

            return(result.ToString());
        }
Exemplo n.º 5
0
        public string ToString(bool simple)
        {
            StringBuilder result = new StringBuilder();

            if (simple)
            {
                result.Append(fTitre.RawTitle);
            }
            else
            {
                result.Append(fTitre.ToString());
            }

            StringBuilder dummy = new StringBuilder();

            StringUtils.AjoutString(dummy, fSérie.ToString(), " - ");
            if (fIntegrale)
            {
                StringBuilder dummy2 = new StringBuilder(StringUtils.NotZero(fTomeDebut.ToString()));
                StringUtils.AjoutString(dummy2, StringUtils.NotZero(fTomeFin.ToString()), " - ");
                StringUtils.AjoutString(dummy, (result.Length > 0 ? Properties.Resources.IntégraleAbrégé : Properties.Resources.Intégrale), " - ", string.Empty, (" " + StringUtils.NotZero(fTome.ToString())).Trim());
                StringUtils.AjoutString(dummy, dummy2, " ", "[", "]");
            }
            else if (fHorsSérie)
            {
                StringUtils.AjoutString(dummy, (result.Length > 0 ? Properties.Resources.HorsSérieAbrégé : Properties.Resources.HorsSérie), " - ", String.Empty, (" " + StringUtils.NotZero(fTome.ToString())).Trim());
            }
            else
            {
                StringUtils.AjoutString(dummy, StringUtils.NotZero(fTome.ToString()), " - ", (result.Length > 0 ? Properties.Resources.TomeAbrégé : Properties.Resources.Tome) + " ");
            }
            if (result.Length > 0)
            {
                StringUtils.AjoutString(result, dummy, " ", "(", ")");
            }
            else
            {
                result = dummy;
            }
            if (result.Length > 0)
            {
                return(result.ToString());
            }
            else
            {
                return(Properties.Resources.SansTitre);
            }
        }