func (ec EventContextV1) GetExtensions() map[string]interface{} {
	if len(ec.Extensions) == 0 {
		return nil
	}
	ext := make(map[string]interface{}, len(ec.Extensions))
	for k, v := range ec.Extensions {
		ext[k] = v
	}
	return ext
}
GetExtensions implements EventContextReader.GetExtensions
package event
import (
	"fmt"
	"strings"
	"time"
)
func (ec EventContextV1) GetSpecVersion() string {
	return CloudEventsVersionV1
}
func (ec EventContextV1) GetDataContentType() string {
	if ec.DataContentType != nil {
		return *ec.DataContentType
	}
	return ""
}
func (ec EventContextV1) GetDataMediaType() (string, error) {
	if ec.DataContentType != nil {
		dct := *ec.DataContentType
		i := strings.IndexRune(dct, ';')
		if i == -1 {
			return dct, nil
		}
		return strings.TrimSpace(dct[0:i]), nil
	}
	return "", nil
}
func (ec EventContextV1) GetType() string {
	return ec.Type
}
func (ec EventContextV1) GetSource() string {
	return ec.Source.String()
}
func (ec EventContextV1) GetSubject() string {
	if ec.Subject != nil {
		return *ec.Subject
	}
	return ""
}
func (ec EventContextV1) GetTime() time.Time {
	if ec.Time != nil {
		return ec.Time.Time
	}
	return time.Time{}
}
func (ec EventContextV1) GetID() string {
	return ec.ID
}
func (ec EventContextV1) GetDataSchema() string {
	if ec.DataSchema != nil {
		return ec.DataSchema.String()
	}
	return ""
}
func (ec EventContextV1) DeprecatedGetDataContentEncoding() string {
	return ""
}