Recuperar altura de célula de protótipo personalizado do storyboard?

Ao usar "Protótipos dinâmicos" para especificarUITableView conteúdo no storyboard, existe uma propriedade "Row Height" que pode ser definida como Custom.

Ao instanciar células, essa altura de linha personalizada não é levada em conta. Isso faz sentido, já que o protótipo de célula que uso é decidido pelo código do meu aplicativo no momento em que a célula será instanciada. Instanciar todas as células ao calcular o layout introduziria uma penalidade de desempenho, então eu entendo porque isso não pode ser feito.

A questão então, posso de alguma forma recuperar a altura dada a um identificador de reutilização de células, por ex.

[myTableView heightForCellWithReuseIdentifier:@"MyCellPrototype"];

ou algo ao longo dessa linha? Ou eu tenho que duplicar as alturas de linha explícitas no código do meu aplicativo, com a carga de manutenção que se segue?

Resolvido, com a ajuda de @TimothyMoose:

As alturas são armazenadas nas próprias células, o que significa que a única maneira de obter as alturas é instanciar os protótipos. Uma maneira de fazer isso é pré-desenfileirar as células fora do método de retorno de chamada de célula normal. Aqui está o meu pequeno POC, que funciona:

#import "ViewController.h"

@interface ViewController () {
    NSDictionary* heights;
}
@end

@implementation ViewController

- (NSString*) _reusableIdentifierForIndexPath:(NSIndexPath *)indexPath
{
    return [NSString stringWithFormat:@"C%d", indexPath.row];
}

- (CGFloat) tableView:(UITableView *)tableView heightForRowAtIndexPath:(NSIndexPath *)indexPath
{
    if(!heights) {
        NSMutableDictionary* hts = [NSMutableDictionary dictionary];
        for(NSString* reusableIdentifier in [NSArray arrayWithObjects:@"C0", @"C1", @"C2", nil]) {
            CGFloat height = [[tableView dequeueReusableCellWithIdentifier:reusableIdentifier] bounds].size.height;
            hts[reusableIdentifier] = [NSNumber numberWithFloat:height];
        }
        heights = [hts copy];
    }
    NSString* prototype = [self _reusableIdentifierForIndexPath:indexPath];
    return [heights[prototype] floatValue];
}

- (NSInteger) tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section
{
    return 3;
}

- (NSInteger)numberOfSectionsInTableView:(UITableView *)tableView
{
    return 1;
}

- (UITableViewCell*) tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath
{
    NSString* prototype = [self _reusableIdentifierForIndexPath:indexPath];
    UITableViewCell* cell = [tableView dequeueReusableCellWithIdentifier:prototype];
    return cell;
}

@end

questionAnswers(2)

yourAnswerToTheQuestion