Exemple #1
0
 public Profile(
     ProfileExtrinsic extrinsicState,
     ProfileIntrinsic intrinsicState)
 {
     ExtrinsicState = extrinsicState;
     IntrinsicState = intrinsicState;
 }
        public Profile Create(string userName, int imageId)
        {
            ProfileExtrinsic pe = new ProfileExtrinsic(userName);
            ProfileIntrinsic pi = null;

            if (_intrinsicStateData.ContainsKey(imageId))
            {
                pi = _intrinsicStateData[imageId];
            }
            else
            {
                pi = new ProfileIntrinsic(ImageDB.Read(imageId));
                _intrinsicStateData[imageId] = pi;
            }

            return(new Profile(pe, pi));
        }
Exemple #3
0
 public void Display(ProfileExtrinsic extrinsicState)
 {
     // Uses both extrinsic and intrinsic state data,
     // but extrinsic state is now a parameter!
 }